Skip to content

model load error #4

Description

@siennachen45

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'.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions