When I run the below code to import the fashion_mnist
data:
fashion_mnist = keras.datasets.fashion_mnist
(train_images, train_labels), (test_images, test_labels) = fashion_mnist.load_data()
I get:
ValueError Traceback (most recent call last) in () 1 fashion_mnist = keras.datasets.fashion_mnist 2 ----> 3 (train_images, train_labels), (test_images, test_labels) = fashion_mnist.load_data()
~/Asha/machineLearningAsha/anaconda3/lib/python3.6/site-packages/tensorflow/python/keras/datasets/fashion_mnist.py
in load_data() 64 with gzip.open(paths[3], 'rb') as imgpath: 65 x_test = np.frombuffer( ---> 66 imgpath.read(), np.uint8, offset=16).reshape(len(y_test), 28, 28) 67 68 return (x_train, y_train), (x_test, y_test)
ValueError: offset must be non-negative and no greater than buffer length (0)
Can someone please help me import the `fashion_mnist' data?
conda list
orconda list -n <myenv>
(in case you use conda environment). – Mikhail Stepanov