tensorflow 运行 python convolutional.py时

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了tensorflow 运行 python convolutional.py时相关的知识,希望对你有一定的参考价值。

Traceback (most recent call last):
File "convolutional.py", line 326, in <module>
tf.app.run()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/tensorflow/python/platform/app.py", line 30, in run
sys.exit(main(sys.argv))
File "convolutional.py", line 138, in main
train_data = extract_data(train_data_filename, 60000)
File "convolutional.py", line 85, in extract_data
buf = bytestream.read(IMAGE_SIZE * IMAGE_SIZE * num_images * NUM_CHANNELS)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/gzip.py", line 268, in read
self._read(readsize)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/gzip.py", line 315, in _read
self._read_eof()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/gzip.py", line 354, in _read_eof
hex(self.crc)))
IOError: CRC check failed 0xd87082d != 0x6f522beL

是由于数据集不完整,去官网下载 

http://yann.lecun.com/exdb/mnist/

然后复制到tensorflow minist下的data文件夹下覆盖

 
















以上是关于tensorflow 运行 python convolutional.py时的主要内容,如果未能解决你的问题,请参考以下文章

『TensorFlow』常用函数实践笔记

比较 Conv2D 与 Tensorflow 和 PyTorch 之间的填充

tensorflow中踩过的坑

TensorFlow conv2d实现卷积

TensorFlow 中 conv2d 的确切含义

在 Tensorflow 中重用层权重