greydanus / mnist1d

A 1D analogue of the MNIST dataset for measuring spatial biases and answering Science of Deep Learning questions.
Apache License 2.0
199 stars 33 forks source link

Can not load default dataset #1

Closed DanielHesslow closed 3 years ago

DanielHesslow commented 3 years ago

The default dataset seems to be broken. Not a big deal since it just automatically rebuilds it, but I though I should bring it to your attention.

from mnist1d.data import get_dataset_args, get_dataset
args = get_dataset_args()
data = get_dataset(args,  path='./mnist1d_data.pkl', download=True)
-> 
Downloading MNIST1D dataset from https://github.com/greydanus/mnist1d/raw/master/mnist1d_data.pkl   
Saving to ./mnist1d_data.pkl
Did or could not load data from ./mnist1d_data.pkl. Rebuilding dataset...

minimal repo: https://colab.research.google.com/drive/16RBVCMLXegLZ6xidI3ZBe_visT_gR5EA?usp=sharing

greydanus commented 3 years ago

Daniel, I really appreciate you bringing this up and including the easy-to-reproduce failure case. The error was due to me using version 4 of the pickle protocol instead of version 3 (which is what I just switched to). My local version of pickle supports v4 but the Colab version does not. I downgraded to version 3 and now the default dataset loads in Colab. Cheers, Sam