- class ray.tune.stopper.TrialPlateauStopper(metric: str, std: float = 0.01, num_results: int = 4, grace_period: int = 4, metric_threshold: float | None = None, mode: str | None = None)#
Early stop single trials when they reached a plateau.
When the standard deviation of the
metricresult of a trial is below a threshold
std, the trial plateaued and will be stopped early.
metric – Metric to check for convergence.
std – Maximum metric standard deviation to decide if a trial plateaued. Defaults to 0.01.
num_results – Number of results to consider for stdev calculation.
grace_period – Minimum number of timesteps before a trial can be early stopped
metric_threshold (Optional[float]) – Minimum or maximum value the result has to exceed before it can be stopped early.
mode – If a
metric_thresholdargument has been passed, this must be one of [min, max]. Specifies if we optimize for a large metric (max) or a small metric (min). If max, the
metric_thresholdhas to be exceeded, if min the value has to be lower than
metric_thresholdin order to early stop.