Skip to content
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

fasterRCNN代码运行报错RuntimeError: unexpected EOF, expected 2193276 more bytes. The file might be corrupted. #752

Open
theRain0450 opened this issue Sep 15, 2023 · 1 comment

Comments

@theRain0450
Copy link

代码报错详情

Traceback (most recent call last):
  File "D:/PythonProjects/deep-learning-for-image-processing-master/pytorch_object_detection/faster_rcnn/train_res50_fpn.py", line 231, in <module>
    main(args)
  File "D:/PythonProjects/deep-learning-for-image-processing-master/pytorch_object_detection/faster_rcnn/train_res50_fpn.py", line 106, in main
    model = create_model(num_classes=args.num_classes + 1)
  File "D:/PythonProjects/deep-learning-for-image-processing-master/pytorch_object_detection/faster_rcnn/train_res50_fpn.py", line 30, in create_model
    weights_dict = torch.load("./backbone/fasterrcnn_resnet50_fpn_coco.pth", map_location='cpu')
  File "D:\MyLearnSoft\Miniconda\envs\pytorch\lib\site-packages\torch\serialization.py", line 608, in load
    return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
  File "D:\MyLearnSoft\Miniconda\envs\pytorch\lib\site-packages\torch\serialization.py", line 794, in _legacy_load
    deserialized_objects[key]._set_from_file(f, offset, f_should_read_directly)
RuntimeError: unexpected EOF, expected 2193276 more bytes. The file might be corrupted.
@theRain0450
Copy link
Author

上网查了一下普遍说是pth与训练权重文件的问题,但这两个文件在maskrcnn上运行的很好,不知道为什么在fasterrcnn上就报错了QAQ,求大神指点

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant