Commit c9382ca
committed
fix: Add weights_only=False for PyTorch 2.6 checkpoint loading
PyTorch 2.6 changed the default value of weights_only parameter in
torch.load() from False to True. Since Lightning checkpoints contain
optimizer and scheduler state (not just tensors), loading now requires
weights_only=False.
This is safe as the checkpoint is self-generated during training.1 parent 808f749 commit c9382ca
2 files changed
Lines changed: 1731 additions & 1214 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
201 | 207 | | |
202 | 208 | | |
203 | 209 | | |
| |||
361 | 367 | | |
362 | 368 | | |
363 | 369 | | |
| 370 | + | |
364 | 371 | | |
365 | 372 | | |
366 | 373 | | |
| |||
0 commit comments