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

OSError: work_dirs/epoch_12.pth is not a checkpoint file #131

Open
rohansig opened this issue Mar 24, 2022 · 3 comments
Open

OSError: work_dirs/epoch_12.pth is not a checkpoint file #131

rohansig opened this issue Mar 24, 2022 · 3 comments

Comments

@rohansig
Copy link

I trained the model on dota, but when I try to test it it throws this error.

Traceback (most recent call last):
File "tools/test.py", line 236, in
main()
File "tools/test.py", line 181, in main
checkpoint = load_checkpoint(model, args.checkpoint, map_location='cpu')
File "/usr/local/lib/python3.7/site-packages/mmcv/runner/checkpoint.py", line 171, in load_checkpoint
raise IOError('{} is not a checkpoint file'.format(filename))
OSError: work_dirs/epoch_12.pth is not a checkpoint file

@csuhan
Copy link
Owner

csuhan commented Mar 24, 2022

Please check if work_dirs/epoch_12.pth exists.

@rohansig
Copy link
Author

yes it exists triple checked :P

I myself trained the model, training was done successfully. I am not sure why its getting stuck while testing.

@csuhan
Copy link
Owner

csuhan commented Mar 26, 2022

You can download and try our pretrained one.
I guess there is something wrong with your trained model.

You can try to load it mamally model = torch.load('your_model_path') to see if it works.

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

2 participants