forked from pytorch/tnt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
encapsulate snapshot restoration params in a struct (pytorch#598)
Summary: Pull Request resolved: pytorch#598 # Context Users may want to opt out of restoring certain parts of the app state (for example, like optimizer and lr scheduler states when finetuning). This is currently not supported in torchsnapshot saver # This Diff * Adds `RestoreOptions` dataclass to encapsulate all restoration params * moves `restore_train_progress`, `restore_eval_progress` to the struct * Replaces all `restore` apis to take `RestoreOptions` struct, replacing the `restore_train_progress`, `restore_eval_progress` * Adds optimizer and lr_scheduler to `RestoreOptions` Reviewed By: galrotem, balakv504 Differential Revision: D50757494 fbshipit-source-id: 853a8f85c1511dddbaecb243455b48560d02a42d
- Loading branch information
1 parent
26cee43
commit d3fdc28
Showing
2 changed files
with
72 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters