Move CheckpointConnector.fault_tolerant_auto_save_path
out of CheckpointConnector.hpc_resume_path
#11092
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Item 1. in #9407 (comment)
Part of #9407 cleanup, move
CheckpointConnector.fault_tolerant_auto_save_path
out ofCheckpointConnector.hpc_resume_path
.Note that unless we change line 165 here to
if self.hpc_resume_path or self.fault_tolerant_auto_save_path is not None:
, this means fault-tolerant checkpoints will no longer runon_hpc_load
hook (deprecated but not yet removed).I think this is the correct behavior, though lmk if you think line 165 should be edited to preserve the same behavior as before.
https://github.com/PyTorchLightning/pytorch-lightning/blob/3c4d06bd42ff3282a017cd9fa879bbd68e8568df/pytorch_lightning/trainer/connectors/checkpoint_connector.py#L163-L166
Does your PR introduce any breaking changes? If yes, please list them.
Before submitting
PR review
Anyone in the community is welcome to review the PR.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:
Did you have fun?
Make sure you had fun coding 🙃