Weights & Biases: 'define_metric' with Bayesian Optimization sweep

26 views Asked by At

Let's say, I am trying to optimize some hyperparameters on a goal metric by maximizing it. The selected sweep method is bayes. Also, that goal metric is defined by define_metric function with a summary flag, namely max. Basically, on the summary table, I am logging the max value of this goal metric, instead of the last logged value.

My question is, how does the Bayesian sweep work with define_metric method? Does the sweep optimize on the metric by maximizing the summary value (last logged/max/min etc.) ? Or does it neglect define_metric and takes a global maximum value into account ?

In the training script:

wandb.define_metric("goal_metric", summary='max')
...
wandb.log({"goal_metric": ...

In the sweep configuration:

method:   bayes
metric:
  goal:   maximize
  name:   goal_metric
0

There are 0 answers