xinntao / ESRGAN

ECCV18 Workshops - Enhanced SRGAN. Champion PIRM Challenge on Perceptual Super-Resolution. The training codes are in BasicSR.
https://github.com/xinntao/BasicSR
Apache License 2.0
5.97k stars 1.06k forks source link

_pickle.UnpicklingError: invalid load key, '<'. run in google colab #122

Open kirdik opened 3 years ago

kirdik commented 3 years ago

I'm trying to run in google colab. Basic startup throws this error. All models are downloaded and placed in the model folder. python test.py Traceback (most recent call last): File "test.py", line 15, in <module> model.load_state_dict(torch.load(model_path), strict=True) File "/usr/local/lib/python3.7/dist-packages/torch/serialization.py", line 593, in load return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args) File "/usr/local/lib/python3.7/dist-packages/torch/serialization.py", line 762, in _legacy_load magic_number = pickle_module.load(f, **pickle_load_args) _pickle.UnpicklingError: invalid load key, '<'.

Jeejo-Joy commented 2 years ago

Getting this same error with google collab, however it works locally.

In I tried loading directly from pickle still same error.

image
Jeromedebruyn commented 2 years ago

@kirdik I have the same error, did you every manage to solve it?

DuyguSerbes commented 2 years ago

Hello, did you solve the problem? I am getting the same error.

Haadia-a commented 2 years ago

@kirdik @Jeejo-Joy did you guys manage to find a solution? Please share