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

'TypeError: the first argument must be callable' while trying to test the model. #3

Open
ajxv opened this issue Jun 13, 2023 · 0 comments

Comments

@ajxv
Copy link

ajxv commented Jun 13, 2023

I am getting the following error while trying to test the model using pre-trained model. Any idea how to resolve this?

Link to Google colab: https://colab.research.google.com/drive/1-NapNL5Xl9pXIBcF9q5JQtaGvnkS2eOp?usp=sharing

=> loading checkpoint './model/ShanghaiA/model_best.pth'
Traceback (most recent call last):
  File "/content/AutoScale/val.py", line 248, in <module>
    main()
  File "/content/AutoScale/val.py", line 57, in main
    checkpoint = torch.load(args.pre)
  File "/usr/local/lib/python3.10/dist-packages/torch/serialization.py", line 815, in load
    return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
  File "/usr/local/lib/python3.10/dist-packages/torch/serialization.py", line 840, in _legacy_load
    class UnpicklerWrapper(pickle_module.Unpickler):  # type: ignore[name-defined]
TypeError: the first argument must be callable
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