-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
size mismatch during load_sate_dict() #4
Comments
font{
line-height: 1.6;
}
ul,ol{
padding-left: 20px;
list-style-position: inside;
}
Hi, I understand what you have done to the code.
When you train the network you should load the pretrained model which termed as resnet101-imagenet.pth.The aformethioned pretrained model is from the training on imagenet dataset for image classification.Usually, when you train the network for segmentation, we can first load the pretrained classification model to improve the performance, this is a common practice.The final trained model for segmentation on LIP is LIP_epoch_149.pth.All in all, resnet101-imagenet.pth is the pretrained model for training the network, LIP_epoch_149.pthis our final trained model to evaluate.
On 8/17/2022 ***@***.***> wrote:
Thanks for your reply!
I downloaded the pretrained model from Google Drive and put it on the folder as below:
is there any chance that the model on Google Drive is different from the one on Baidu Drive?
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: ***@***.***>
|
when i do evaluation,I have a similar problem. Here is my code.
return “ runtimeError OrderedDict mutated during iteration” so,i modify the code
return RuntimeError: Error(s) in loading state_dict for ResNet: |
Same problem for me. |
@tjpulkl I am facing the same problem. What could be the reason? Please advice! |
Hello, I appreciate your awesome work.
I want to try evaluation, but there's an error while calling load_state_dict() in evaluate.py
the error message is as below:
size mismatch for layer6.conv2.0.weight: copying a param with shape torch.Size([48, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([48, 256, 3, 3]).
It seems that the dimensions in the pretrained model 'LIP_epoch_149.pth' and the constructed model from LIPDataSet() are different in some layers. Could you check this issue?
Thank you!
The text was updated successfully, but these errors were encountered: