What is Weights & Biases (wandb)?
Weights & Biases (wandb) is an open-source Python client library for tracking machine learning experiments. It sits in the Experiment Tracking category of the Training & Fine-Tuning tools and is open-source, written in Python and licensed MIT. To get started: install the wandb library.
Overview
Weights & Biases (wandb) is an open-source Python client library for tracking machine learning experiments. You add a few lines of code to your training script, and it records your hyperparameters, metrics, and other run details so you can review and compare them later in the W&B web app.
It's built for ML engineers and researchers who want a record of every run instead of scattered logs and spreadsheets. As an experiment tracking tool, it sits alongside your existing training code and integrates with common ML frameworks, so you can add it to projects without rewriting them.
Beyond plain metric logging, wandb supports hyperparameter sweeps and versioning of models and datasets. The library is free and open source; the backend runs on W&B's hosted cloud or on infrastructure you manage yourself.
What it does
- Log metrics, hyperparameters, and run metadata from a Python script or notebook with wandb.init() and run.log()
- Visualize and compare runs in the W&B web app, including how metrics change across training steps
- Run hyperparameter sweeps to search over configurations
- Version models and datasets as artifacts
- Integrates with popular ML frameworks and libraries for quick setup in existing projects
- Choose hosted multi-tenant cloud, dedicated cloud, or self-managed deployment on your own infrastructure
Getting started
Install the library, create an API key, then log a run from your training code.
Install the wandb library
Install wandb from PyPI with pip.
pip install wandbSign up and create an API key
Sign up for a W&B account and create an API key at wandb.ai/settings. Optionally run wandb login to store it on your machine; otherwise W&B prompts you the first time you use it.
wandb loginTrack a training experiment
In your Python script or notebook, initialize a run with wandb.init(), pass your hyperparameters as config, and log metrics with run.log().
import wandb
project = "my-awesome-project"
config = {"epochs": 1337, "lr": 3e-4}
with wandb.init(project=project, config=config) as run:
# Training code here
run.log({"accuracy": 0.9, "loss": 0.1})Commands and code are distilled from the project's own documentation — always check the official repo for the latest.
When to use it
- Keep a searchable record of every training run's hyperparameters and metrics instead of manual logs or spreadsheets
- Compare accuracy and loss curves across many runs to pick the best configuration
- Run hyperparameter sweeps to find good settings for a model
- Version datasets and trained models so results stay reproducible over time
How Weights & Biases (wandb) compares
Weights & Biases (wandb) alongside other open-source experiment tracking tools AI/TLDR tracks, ranked by GitHub stars.
| Tool | Stars | What it does |
|---|---|---|
| MLflow | ★ 28.9k | An open-source ML and GenAI platform that, alongside experiment tracking, provides evaluation and monitoring tools for scoring and comparing LLM and agent outputs. |
| DVC | ★ 16k | A Git-like version control tool for datasets, models, and experiments that makes ML projects reproducible. |
| Weights & Biases (wandb) | ★ 11.3k | Track, visualize, and version your machine learning experiments |
| ClearML | ★ 6.9k | An open-source MLOps suite whose experiment manager auto-logs runs, metrics, and artifacts and ties them into data management and orchestration. |
| Aim | ★ 6.3k | A self-hosted, open-source experiment tracker that logs and compares thousands of training runs through a fast web UI. |
| Sacred | ★ 4.4k | A Python tool for configuring, organizing, logging, and reproducing computational research experiments. |
| Polyaxon | ★ 3.7k | An open-source platform for tracking, scheduling, and managing large-scale deep learning experiments on Kubernetes. |
| Trackio | ★ 1.8k | A lightweight open-source experiment tracker from Hugging Face that stores runs locally in SQLite as a drop-in alternative to wandb. |

