Skip to main content
GitHub source

Usage

wandb restore [OPTIONS] RUN

Description

Restore the code, config, and Docker state from a previous run. Recreate the environment of a previous W&B run so you can reproduce it. Run this command from the same git repository as the original run, unless you pass the --no-git flag. Restore in three steps:
  1. Git — Check out the original commit on a new branch (wandb/run_id), fetch and apply any saved diff patch, and fall back to an upstream commit if the original commit cannot be found.
  2. Config — Write the run config to wandb/config.yaml.
  3. Docker — If the run used Docker, start the same image with the original command.
Accept run in any of these formats:
  • run_id
  • project:run_id
  • entity/project:run_id
  • entity/project/run_id

Examples

Restore a run with run ID “abcd1234” in the default project and entity
wandb restore abcd1234
Restore a run from the “foobar” project and “team-awesome” entity with run ID “abcd1234”
wandb restore team-awesome/foobar-project:abcd1234
Restore run “abcd1234” without restoring git state. Only restore config and Docker state.
wandb restore --no-git abcd1234
Restore run “abcd1234” in detached HEAD mode instead of creating a branch
wandb restore --no-branch abcd1234

Arguments

NameDefaultType
runNoneSTR

Options

FlagTypeDescription
--no-gitBOOL FlagSkip git restoration. Only restore config and Docker state. Default: False
--branch / --no-branchBOOL FlagCreate a wandb/run_id branch or check out the commit in detached HEAD mode. Default: True
--project, -pSTRSpecify the project to look up the run in. Default: None
--entity, -eSTRSpecify the entity to scope the run lookup to. Default: None