Documentation Index
Fetch the complete documentation index at: https://wb-21fd5541-weave-caching.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
GitHub source
function bar
bar(
table: 'wandb.Table',
label: 'str',
value: 'str',
title: 'str' = '',
split_table: 'bool' = False
) → CustomChart
wandb.Table 데이터를 사용하여 막대형 차트(bar chart)를 생성합니다.
Args:
table: 막대형 차트에 사용할 데이터가 포함된 테이블입니다.
label: 각 막대의 레이블로 사용할 컬럼의 이름입니다.
value: 각 막대의 값으로 사용할 컬럼의 이름입니다.
title: 막대형 차트의 제목입니다.
split_table: W&B UI에서 테이블을 별도의 섹션으로 분리할지 여부입니다. True인 경우, 테이블은 “Custom Chart Tables”라는 이름의 섹션에 표시됩니다. 기본값은 False입니다.
Returns:
CustomChart: W&B에 로그를 남길 수 있는 커스텀 차트 오브젝트입니다. 차트를 로그하려면 wandb.log()에 전달하세요.
Example:
import random
import wandb
# 테이블을 위한 랜덤 데이터 생성
data = [
["car", random.uniform(0, 1)],
["bus", random.uniform(0, 1)],
["road", random.uniform(0, 1)],
["person", random.uniform(0, 1)],
]
# 데이터와 함께 테이블 생성
table = wandb.Table(data=data, columns=["class", "accuracy"])
# W&B run을 초기화하고 막대형 차트를 로그합니다
with wandb.init(project="bar_chart") as run:
# 테이블로부터 막대형 차트 생성
bar_plot = wandb.plot.bar(
table=table,
label="class",
value="accuracy",
title="Object Classification Accuracy",
)
# W&B에 막대형 차트 로그
run.log({"bar_plot": bar_plot})