Skip to main content
GitHub source

Usage

wandb docker-run [OPTIONS] [DOCKER_RUN_ARGS]...

Description

Wrap docker run and inject W&B environment variables automatically. Pass all arguments through to docker run while injecting:
  • WANDB_API_KEY — Use the current API key so the container can authenticate with W&B without manual configuration.
  • WANDB_DOCKER — Record the resolved image ID so W&B can track which Docker image produced the run.
If nvidia-docker is detected on the host and --runtime is not already set, add --runtime nvidia to the command to enable GPU support by default.

Examples

Run python train.py inside the “my-image” container. W&B automatically injects your API key and the resolved image ID.
wandb docker-run my-image python train.py

Arguments

NameDefaultType
docker_run_argsNoneSTR

Options

FlagTypeDescription
--helpBOOLShow this message and exit. Default: False