Skip to content

Cannot load the weights after training with custom data #131

@PhucPhamSy

Description

@PhucPhamSy

Hi, after train model with distributed training method. I cannot load the weight name "last_model_state.pth". I trained with model name "fasterrcnn_resnet50_fpn"

Traceback (most recent call last):
File "/raid/data/phuc/detection/fastercnn-pytorch-training-pipeline/test_load_weight.py", line 37, in
model.load_state_dict(checkpoint['model_state_dict'])
File "/home/ubuntu/anaconda3/envs/fastercnn/lib/python3.9/site-packages/torch/nn/modules/module.py", line 2153, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for FasterRCNN:
Missing key(s) in state_dict:

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