When Ray tune finish hyperparameter optimization

How severe does this issue affect your experience of using Ray?

  • Low: It annoys or frustrates me for a moment.

Hello, Thank you for your fantastic tools! I do not understand one thing in ray tune.
I see that there are ways to define when the trial should end earlier or later …
But I do not see where it is written when the whole hyperparameter tuning process will end - for example, can I set the minimum and the maximum number of trials?
Secondly, Is the hyperparameter optimization results saved somewhere or they can be only printed?

Hey @Jakub_Mitura!

By default (with no search algorithm or scheduler), there is no min or max trials. They are both the same. The total number of trials you want to run can be configured via the num_samples argument passed to tune.run. The experiment will end when num_samples trials have finished.

However, each search algorithm and scheduler has a different mechanisms for determining how many trials to run and when to stop trials. You can read about the different options here: Trial Schedulers (tune.schedulers) — Ray 2.0.0

If you want more customization on stopping the entire experiment, you can do this via the Stopper API. There are some built in Stoppers here: Stopping mechanisms (tune.stopper) — Ray 2.0.0, or you can implement a custom Stopper and override the stop_all method like in this example: Stopping and Resuming Tune Trials — Ray 2.0.0

1 Like

@Jakub_Mitura for the second question, yes the results are all saved to an experiment directory.

You can read more about analyzing the results after the experiment has finished here: Analysis (tune.analysis) — Ray 1.13.0

1 Like