Skip to content

RuntimeError: Error(s) in loading state_dict for DummyModule: #1

@ldepn

Description

@ldepn

你好,我用的python3.7,pytorch 1.4.0 ,在跑demo的时候提示下面这个错误。

RuntimeError: Error(s) in loading state_dict for DummyModule:
size mismatch for module.tl_heats.0.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.tl_heats.0.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).
size mismatch for module.tl_heats.1.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.tl_heats.1.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).
size mismatch for module.tl_heats.2.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.tl_heats.2.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).
size mismatch for module.br_heats.0.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.br_heats.0.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).
size mismatch for module.br_heats.1.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.br_heats.1.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).
size mismatch for module.br_heats.2.1.weight: copying a param with shape torch.Size([80, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([21, 256, 1, 1]).
size mismatch for module.br_heats.2.1.bias: copying a param with shape torch.Size([80]) from checkpoint, the shape in current model is torch.Size([21]).

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