我试图通过以下方式加载 mnist 数据集:
import keras
from keras.datasets import mnist
(x_train,y_train),(x_test,y_test)=mnist.load_data()
但我收到此错误:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "E:\anaconda\lib\site-packages\keras\datasets\mnist.py", line 15, in load_data
data = cPickle.load(f)
File "E:\anaconda\lib\gzip.py", line 252, in read
raise IOError(errno.EBADF, "read() on write-only GzipFile object")
IOError: [Errno 9] read() on write-only GzipFile object
我应该怎么办?
谢谢