Weights & Biases (W&B) is an MLOps platform, equipped with tools to help you visualize machine learning experiments, organize model training, and collaborate with others. It’s like having a devoted, uber-organized lab assistant who also happens to be a wizard at graphs.
W&B is a serious upgrade from TensorBoard in TensorFlow – think of it as TensorBoard on a hearty dose of vitamins. It deals with everything from dataset curation to hyperparameter tuning, setting up automation, and a whole lot more.
I’ve been dabbling with some of its features for my latest projects, but you’ve gotta take a dive into their documentation to truly appreciate the gamut of what it offers. Check it out here: https://docs.wandb.ai/guides
W&B Artifacts
Think of Artifacts as your experiment’s digital museum. It’s where you store the precious outputs of your runs – things like trained models, datasets, and even those pesky preprocessed blobs of data that you never want to compute again.
Here’s a quick bite of how to log an artifact:
run = wandb.init(project="artifacts-example", job_type="add-dataset")
artifact = wandb.Artifact(name="my_data", type="dataset")
artifact.add_dir(local_path="./dataset.h5") # Add dataset directory to artifact
run.log_artifact(artifact) # Logs the artifact version "my_data:v0"
W&B Tables
W&B Tables help you showcase data frames, images, and even audio samples associated with your experiments. This is a killer feature for drilling down into your data and predictions.
import wandb
run = wandb.init(project="table-test")
my_table = wandb.Table(columns=["a", "b"], data=[["a1", "b1"], ["a2", "b2"]])
run.log({"Table Name": my_table})
W&B Reports
W&B Reports are storytelling tools that let you create living documents of your experiments. These reports allow you to organize your visualizations, findings, and musing thoughts all in one place.