AutosavePolicy

AutosavePolicy#

class AutosavePolicy#

Policy controlling rolling draft checkpoints after a Run closes.

Construct a policy with one of the static methods, then pass it to Experiment.set_autosave_policy(...). The policy applies only to the current unsealed session and is not stored in committed Experiments or checkpoints.

__repr__() → str#
disabled() → AutosavePolicy#

Disable rolling draft checkpoints after Run close.

every_n_runs(runs: int) → AutosavePolicy#

Checkpoint after runs additional Runs close.

every_run_close() → AutosavePolicy#

Checkpoint after every Run closes. This is the default.

min_interval(seconds: float) → AutosavePolicy#

Attempt to checkpoint the first subsequently closed Run immediately, then at most once per seconds interval. Failed attempts also wait for the interval before retrying.