_pickle.UnpicklingError: pickle data was truncated for loading CIFAR100
See original GitHub issueHello Guys,
I am trying to load CIFAR100 using cifar100.load_data() using keras. But I am encountering an error which says:
Using TensorFlow backend.
Traceback (most recent call last):
File "resnet_cifar_new100.py", line 52, in <module>
(x_train, y_train), (x_test, y_test) = cifar100.load_data()
File "/home/bansa01/anaconda3/envs/keras/lib/python3.6/site-packages/keras/datasets/cifar100.py", line 34, in load_data
x_train, y_train = load_batch(fpath, label_key=label_mode + '_labels')
File "/home/bansa01/anaconda3/envs/keras/lib/python3.6/site-packages/keras/datasets/cifar.py", line 27, in load_batch
d = cPickle.load(f, encoding='bytes')
_pickle.UnpicklingError: pickle data was truncated
I have made no changes whatsoever in the respective file. And the version of Keras and Tensorflow I am using are:
(keras) bansa01@vita2:/ssd2/home/bansa01/resnet_final/tmp_spectral_new$ python -c 'import keras; print(keras.__version__)'
Using TensorFlow backend.
2.2.4
(keras) bansa01@vita2:/ssd2/home/bansa01/resnet_final/tmp_spectral_new$ python -c 'import tensorflow; print(tensorflow.__version__)'
1.11.0
Please suggest what should be done.
Regards Nitin
Issue Analytics
- State:
- Created 5 years ago
- Comments:6
Top Results From Across the Web
Python 3 keras: UnpicklingError: pickle data was truncated for ...
I need some help to fix my errors. I tried to load the cifar10 dataset and it wasn't able ...
Read more >Loading big Doc2Vec model with error UnpicklingError
I ran into Error of UnpicklingError: pickle data was truncated when loading the model. Do you know what the issue here is and...
Read more >_pickle.UnpicklingError: pickle data was truncated? - PyTorch ...
Could you redownload or recreate the data as it seems the file is not complete (truncated). Is there any other possible cause of...
Read more >Python 3 Keras: Unpicklingerror: Pickle Data Was Truncated ...
I tested the "UnpicklingError: pickle data was truncated" error solution. Python reported an error when using pickle deserialization: data It is truncated ...
Read more >TensorFlow KR | 안녕하세요, 혹시 동일한 문제가 있으셨던
UnpicklingError : pickle data was truncated ... packages\tensorflow\python\keras\datasets\cifar100. ... d = cPickle.load(f, encoding='bytes')
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I had the same error, try with this https://stackoverflow.com/a/52496786 it worked for me.
Thank you for your reply, it helped me.
| | wxxd | | 17806259143@163.com | 签名由网易邮箱大师定制 On 10/8/2020 21:55,AminJunnotifications@github.com wrote:
For me the @xscharlie did work. The issue was that the downloaded files were broken, so it couldn’t load it. Erased them and downloaded them again and it worked. But I guess since it didn’t work for @AayushTyagi1 , the issue still remains open.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.