a96123155 / UTR-LM

GNU General Public License v3.0
72 stars 14 forks source link

model load error #4

Open Bulabula45 opened 5 months ago

Bulabula45 commented 5 months ago

Hi, I encountered this probelem when loading model. I changed the version of torch, but it did not work.

File d:\software\miniconda3\envs\py39\lib\site-packages\torch\serialization.py:777, in _legacy_load(f, map_location, pickle_module, pickle_load_args) 771 if not hasattr(f, 'readinto') and (3, 8, 0) <= sys.version_info < (3, 8, 2): 772 raise RuntimeError( 773 "torch.load does not work with file-like objects that do not implement readinto on Python 3.8.0 and 3.8.1. " 774 f"Received object of type \"{type(f)}\". Please update to Python 3.8.2 or newer to restore this " 775 "functionality.") --> 777 magic_number = pickle_module.load(f, pickle_load_args) 778 if magic_number != MAGIC_NUMBER: 779 raise RuntimeError("Invalid magic number; corrupt file?")

UnpicklingError: invalid load key, '\x00'.