How to load checkpoint for a sharded model? #14159
Unanswered
ver217
asked this question in
Lightning Trainer API: Trainer, LightningModule, LightningDataModule
Replies: 2 comments 2 replies
-
Beta Was this translation helpful? Give feedback.
0 replies
-
trainer_cfg = {
'accelerator': 'cuda',
'strategy': 'ddp',
} is it really sharded? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I tried to load checkpoint for a sharded model, but I got unexpected keys error. It seems that the sharded model is not initialized when loading checkpoint.
Here is my code:
Beta Was this translation helpful? Give feedback.
All reactions