WANDBResultTracker

class WANDBResultTracker(project, offline=False, **kwargs)[source]

Bases: ResultTracker

A tracker for Weights and Biases.

Note that you have to perform wandb login beforehand.

Initialize result tracking via WANDB.

Parameters:
  • project (str) – project name your WANDB login has access to.

  • offline (bool) – whether to run in offline mode, i.e, without syncing with the wandb server.

  • kwargs – additional keyword arguments passed to wandb.init().

Raises:

ValueError – If the project name is given as None

Methods Summary

end_run([success])

End a run.

log_metrics(metrics[, step, prefix])

Log metrics to result store.

log_params(params[, prefix])

Log parameters to result store.

start_run([run_name])

Start a run with an optional name.

Methods Documentation

end_run(success=True)[source]

End a run.

HAS to be called after the experiment is finished.

Parameters:

success (bool) – Can be used to signal failed runs. May be ignored.

Return type:

None

log_metrics(metrics, step=None, prefix=None)[source]

Log metrics to result store.

Parameters:
  • metrics (Mapping[str, float]) – The metrics to log.

  • step (Optional[int]) – An optional step to attach the metrics to (e.g. the epoch).

  • prefix (Optional[str]) – An optional prefix to prepend to every key in metrics.

Return type:

None

log_params(params, prefix=None)[source]

Log parameters to result store.

Return type:

None

Parameters:
start_run(run_name=None)[source]

Start a run with an optional name.

Return type:

None

Parameters:

run_name (str | None) –