Skip to main content

Can I run wandb offline?

Yes, set WANDB_MODE=offline to log locally, then use wandb sync to upload results later.

Do environment variables overwrite the parameters passed to wandb.init()?

No, arguments passed to wandb.init() override environment variables.

How can I define the local location for `wandb` files?

Use environment variables like WANDB_DIR, WANDB_ARTIFACT_DIR, and others to control where W&B stores local files.

How do I handle the 'Failed to query for notebook' error?

Set the WANDB_NOTEBOOK_NAME environment variable to resolve the ‘Failed to query for notebook name’ error.

How do I silence W&B info messages?

Set the wandb logger level to logging.ERROR to suppress info-level log messages.

How do I stop wandb from writing to my terminal or my Jupyter notebook output?

Set the WANDB_SILENT environment variable to true to suppress terminal and notebook output.

How do I switch between accounts on the same machine?

Store multiple API keys in a file and set WANDB_API_KEY to switch between W&B accounts.

How does wandb stream logs and writes to disk?

W&B queues events in memory and writes them asynchronously to a local .wandb datastore file.

Is it possible to save metrics offline and sync them to W&B later?

Set WANDB_MODE=offline to log metrics locally, then use wandb sync to upload them later.

What does wandb.init do to my training process?

wandb.init creates a run on the server and starts a background process to stream metrics.

What happens if internet connection is lost while I'm training a model?

W&B retries syncing until the network is restored. Use offline mode and wandb sync for no-internet machines.

Where are artifacts downloaded, and how can I control that?

Artifacts download to the artifacts/ folder by default. Change it with a parameter or environment variable.