Skip to content

Missing and Unexpected key(s) in state_dict #64

@ssy248

Description

@ssy248

When I run the command from the homepage
python main.py --input ./input --video_root ./videos --output ./output.json --model wideresnet-50-kinetics.pth --mode score

after I saved the wideresnet-50-kinetics.pth model to the same folder as main.py, I still have the errors of

Missing key(s) in state_dict: "conv1.weight", "bn1.weight", "bn1.bias", "bn1.running_mean", "bn1.running_var", "layer1.0.conv1.weight", "layer1.0.bn1.weight", "layer1.0.bn1.bias", "layer1.0.bn1.running_mean", "layer1.0.bn1.running_var", "layer1.0.conv2.weight", ....
and
Unexpected key(s) in state_dict: "module.conv1.weight", "module.bn1.weight", "module.bn1.bias", "module.bn1.running_mean", "module.bn1.running_var", "module.layer1.0.conv1.weight", "module.layer1.0.bn1.weight", "module.layer1.0.bn1.bias", "module.layer1.0.bn1.running_mean", ...

Why do the keys from the correct model not match ?

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