BestCheckpointSchedule

class BestCheckpointSchedule(result_tracker: ResultTracker, metric_selection: MetricSelection)[source]

Bases: CheckpointSchedule

Create a checkpoint whenever a metric improves.

Attributes Summary

metric_selection

the metric selection

result_tracker

the result tracker which receives updates on metrics since the same tracker instance needs to receive results from the training loop, we do require a pre-instantiated one rather than offering to provide hints, too

Methods Summary

__call__(step)

Decide whether to create a checkpoint at the specified epoch.

Attributes Documentation

Parameters:
metric_selection: MetricSelection = <dataclasses._MISSING_TYPE object>

the metric selection

result_tracker: ResultTracker = <dataclasses._MISSING_TYPE object>

the result tracker which receives updates on metrics since the same tracker instance needs to receive results from the training loop, we do require a pre-instantiated one rather than offering to provide hints, too

Methods Documentation

__call__(step: int) bool[source]

Decide whether to create a checkpoint at the specified epoch.

Parameters:

step (int)

Return type:

bool