This repository was archived by the owner on Jun 3, 2025. It is now read-only.
Commit 1271955
[BugFix][Torchvision] update optimizer state dict before transfer learning (#1358)
* Add: an `_update_checkpoint_optimizer(...)` for deleting mismatching params from saved optimizer(s) state_dict
* Remove: _update_checkpoint_optimizer in favor of loading in the optim state_dict only when `args.resume` is set
* Remove: un-needed imports
* Address review comments
* Style1 parent b1ec8a9 commit 1271955
1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
533 | 533 | | |
534 | 534 | | |
535 | 535 | | |
536 | | - | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
537 | 544 | | |
538 | 545 | | |
539 | 546 | | |
| |||
0 commit comments