Skip to content

Pickle Issues #1

Description

@ljlamarche

Seem to be having more issues with pickle objects. I noticed that the b_e load seems to be the only one which requires the allow_pickle=True keyword because it contains object data. Is this pickle file different than the others in some way?

Traceback (most recent call last):
  File "/Users/e30737/venvs/py314/lib/python3.14/site-packages/numpy/lib/_npyio_impl.py", line 494, in load
    return pickle.load(fid, **pickle_kwargs)
           ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
_pickle.UnpicklingError: invalid load key, 'v'.

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/e30737/Desktop/Research/GNEISS/GNEISS_stackplot/scripts/stackplot_app.py", line 692, in <module>
    PANEL_DEFS = load_panels()
  File "/Users/e30737/Desktop/Research/GNEISS/GNEISS_stackplot/scripts/stackplot_app.py", line 686, in load_panels
    panels.update(load_b_e_panels())
                  ~~~~~~~~~~~~~~~^^
  File "/Users/e30737/Desktop/Research/GNEISS/GNEISS_stackplot/scripts/stackplot_app.py", line 242, in load_b_e_panels
    npz = np.load(B_E_NPZ, allow_pickle=True)
  File "/Users/e30737/venvs/py314/lib/python3.14/site-packages/numpy/lib/_npyio_impl.py", line 496, in load
    raise pickle.UnpicklingError(
        f"Failed to interpret file {file!r} as a pickle") from e
_pickle.UnpicklingError: Failed to interpret file PosixPath('/Users/e30737/Desktop/Research/GNEISS/GNEISS_stackplot/data/app_data/b_e_field_components_data.npz') as a pickle

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