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

ValueError: Cannot load file containing pickled data when allow_pickle=False #4

Open
nana1223 opened this issue Feb 29, 2024 · 1 comment

Comments

@nana1223
Copy link

nana1223 commented Feb 29, 2024

Hi,I have a question to ask.
When I run with taxibj dataset, have a bug 'ValueError: Cannot load file containing pickled data when allow_pickle=False' in the line 'cat_data = np.load(os.path.join(data_dir, dataset, category + '.npz'))',
and then I modify this line to 'cat_data = np.load(os.path.join(data_dir, dataset, category + '.npz'), allow_pickle=True)', but still have a bug 'pickle.UnpicklingError: Failed to interpret file 'data/BJTaxi/train.npz' as a pickle';
and also I replace np.load to np.loadtxt, but still unsuccessful.

Could you tell me how to load the taxibj dataset?
thank you!!!

@Echo-Ji
Copy link
Owner

Echo-Ji commented Mar 4, 2024

@nana1223 How do you download the data?

If you download from ST-SSL_Dataset, please ensure you use the lfs tool.

Specifically, you have to get these data files pulled using git-lfs.

git lfs install
git lfs pull

Otherwise, the .npy file will be corrupted, so you cannot open them.

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

No branches or pull requests

2 participants