Skip to content

RuntimeError: Error(s) in loading state_dict for DataParallel: #15

Description

@Pxtri2156

Hello everyone.
I trying to run test.py. But I got an error by below:

`RuntimeError: Error(s) in loading state_dict for DataParallel:

size mismatch for module.loc.0.weight: copying a param with shape torch.Size([28, 512, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 512, 1, 1]).  
size mismatch for module.loc.1.weight: copying a param with shape torch.Size([28, 1024, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 1024, 1, 1]).  
size mismatch for module.loc.2.weight: copying a param with shape torch.Size([28, 512, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 512, 1, 1]).  
size mismatch for module.loc.3.weight: copying a param with shape torch.Size([28, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 256, 1, 1]). 
size mismatch for module.loc.4.weight: copying a param with shape torch.Size([28, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 256, 1, 1]).  
size mismatch for module.loc.5.weight: copying a param with shape torch.Size([28, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 256, 1, 1]).  
size mismatch for module.loc.6.weight: copying a param with shape torch.Size([28, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([28, 256, 1, 1]).  
size mismatch for module.conf.0.weight: copying a param with shape torch.Size([14, 512, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 512, 1, 1]).  
size mismatch for module.conf.1.weight: copying a param with shape torch.Size([14, 1024, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 1024, 1, 1]).  
size mismatch for module.conf.2.weight: copying a param with shape torch.Size([14, 512, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 512, 1, 1]).  
size mismatch for module.conf.3.weight: copying a param with shape torch.Size([14, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 256, 1, 1]).  
size mismatch for module.conf.4.weight: copying a param with shape torch.Size([14, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 256, 1, 1]).  
size mismatch for module.conf.5.weight: copying a param with shape torch.Size([14, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 256, 1, 1]).  
size mismatch for module.conf.6.weight: copying a param with shape torch.Size([14, 256, 1, 5]) from checkpoint, the shape in current model is torch.Size([14, 256, 1, 1]).  

`
I hope, everyone helps me to solve this error.
Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions