我不得不終止 Fashion_MNIST 下載,因為它下載速度非常慢。當我嘗試再次下載它時,出現以下錯誤。我想我需要先刪除較早的部分下載。我無法在我的Macbook中找到保存部分下載的文件夾。你能建議我在哪里可以找到 Mac OS 中的部分下載嗎?代碼import tensorflow as tffrom tensorflow import kerasfashion_mnist = keras.datasets.fashion_mnist(X_train_full, y_train_full), (X_test, y_test) = fashion_mnist.load_data()錯誤Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/tensorflow_core/python/keras/datasets/fashion_mnist.py", line 59, in load_data imgpath.read(), np.uint8, offset=16).reshape(len(y_train), 28, 28) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/gzip.py", line 276, in read return self._buffer.read(size) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/gzip.py", line 482, in read raise EOFError("Compressed file ended before the "EOFError: Compressed file ended before the end-of-stream marker was reached
1 回答

SMILET
TA貢獻1796條經驗 獲得超4個贊
我認為 tensorflow 正在嘗試讀取已經下載的數據集,為了再次下載而不是從磁盤讀取,您可以從磁盤中刪除損壞的文件
它們通常位于 ~/.keras/datasets/{name}
rm -rf ~/.keras/datasets/fashion-mnist/
添加回答
舉報
0/150
提交
取消