UNet load state_dict error #3744
-
Thanks for the great job! RuntimeError: Error(s) in loading state_dict for UNet: It seems the UNet needs keys like "model.*" but load "module.model." |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @yingdiLee , Thanks for your interest here. Thanks. |
Beta Was this translation helpful? Give feedback.
Hi @yingdiLee ,
Thanks for your interest here.
I feel that because you used multiple GPUs for training and saved the model, it's common PyTorch question.
You can try to save
model.module
instead, please refer to:https://github.com/pytorch/ignite/blob/master/ignite/handlers/checkpoint.py#L581
Thanks.