ray.rllib.algorithms.algorithm.Algorithm.restore#
- Algorithm.restore(checkpoint_path: str | Checkpoint | _TrainingResult)#
Restores training state from a given model checkpoint.
These checkpoints are returned from calls to save().
Subclasses should override
load_checkpoint()
instead to restore state. This method restores additional metadata saved with the checkpoint.checkpoint_path
should match with the return fromsave()
.- Parameters:
checkpoint_path – Path to restore checkpoint from. If this path does not exist on the local node, it will be fetched from external (cloud) storage if available, or restored from a remote node.
checkpoint_node_ip – If given, try to restore checkpoint from this node if it doesn’t exist locally or on cloud storage.
fallback_to_latest – If True, will try to recover the latest available checkpoint if the given
checkpoint_path
could not be found.
DeveloperAPI: This API may change across minor Ray releases.