tensorflow/tensorflow/models/image/imagenet/python classify_image.py
I went to the python code bundled along the tensorflow installation on python 3.4, tried runing it the following error messages shown:
[DEBUG ON]
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/tensorflow/models/image/imagenet/classify_image.py", line 212, in
tf.app.run()
File "/usr/local/lib/python3.4/dist-packages/tensorflow/python/platform/app.py", line 30, in run
sys.exit(main(sys.argv[:1] + flags_passthrough))
File "/usr/local/lib/python3.4/dist-packages/tensorflow/models/image/imagenet/classify_image.py", line 205, in main
maybe_download_and_extract()
File "/usr/local/lib/python3.4/dist-packages/tensorflow/models/image/imagenet/classify_image.py", line 201, in maybe_download_and_extract
tarfile.open(filepath, 'r:gz').extractall(dest_directory)
File "/usr/lib/python3.4/tarfile.py", line 1980, in extractall
self.extract(tarinfo, path, set_attrs=not tarinfo.isdir())
File "/usr/lib/python3.4/tarfile.py", line 2019, in extract
set_attrs=set_attrs)
File "/usr/lib/python3.4/tarfile.py", line 2088, in _extract_member
self.makefile(tarinfo, targetpath)
File "/usr/lib/python3.4/tarfile.py", line 2134, in makefile
copyfileobj(source, target, tarinfo.size)
File "/usr/lib/python3.4/tarfile.py", line 239, in copyfileobj
buf = src.read(BUFSIZE)
File "/usr/lib/python3.4/gzip.py", line 365, in read
if not self._read(readsize):
File "/usr/lib/python3.4/gzip.py", line 449, in _read
self._read_eof()
File "/usr/lib/python3.4/gzip.py", line 482, in _read_eof
crc32, isize = struct.unpack("File "/usr/lib/python3.4/gzip.py", line 286, in _read_exact
raise EOFError("Compressed file ended before the "
EOFError: Compressed file ended before the end-of-stream marker was reached
Can you do me a favor and run:
curl -I --noproxy '*' http://download.tensorflow.org/models/image/imagenet/inception-2015-12-05.tgz
And paste the output into this issue?
To work around this issue, try downloading manually as follows:
wget -O /tmp/imagenet/inception-2015-12-05.tgz http://download.tensorflow.org/models/image/imagenet/inception-2015-12-05.tgz
See also: tensorflow/tensorflow#4970
I am on Ubuntu
On Sat, 15 Oct 2016, 12:46 PM Justine Tunney [email protected]
wrote:
Are you on RedHat / CentOS?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/tensorflow/models/issues/541#issuecomment-253962687,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AJyMP8pYlkvztj7cHgvBrSup0Lg4BGiZks5q0Fq3gaJpZM4KWwwo
.
The solution is most likely to download the file manually, so I'm going to close this issue. If you provide me with new information, I'll reopen it.
run: curl -I --noproxy '*' http://download.tensorflow.org/models/image/imagenet/inception-2015-12-05.tgz
HTTP/1.1 200 OK
X-GUploader-UploadID: AEnB2Uon8jaHYR29akGkeLjlNkAkHh1KlqT9NtQvMllj7b2aWfAwJ3TeZca4AgCB80YmolzhKl0wXeO8A7OXxOaGI44z286GWQ
Expires: Tue, 18 Oct 2016 09:42:18 GMT
Date: Tue, 18 Oct 2016 08:42:18 GMT
Cache-Control: public, max-age=3600
Last-Modified: Sat, 05 Dec 2015 02:23:10 GMT
ETag: "28395d1479e87ee86da70419d1ba2c3c"
x-goog-generation: 1449282190011000
x-goog-metageneration: 2
x-goog-stored-content-encoding: identity
x-goog-stored-content-length: 88931400
Content-Type: application/x-compressed-tar
x-goog-hash: crc32c=ef9Stw==
x-goog-hash: md5=KDldFHnofuhtpwQZ0bosPA==
x-goog-storage-class: STANDARD
Accept-Ranges: bytes
Content-Length: 88931400
Server: UploadServer
That response seems correct. Did manually downloading fix the problem?
Automatically closing due to lack of recent activity. Please let us know when further information is available and we will reopen. Thanks!
The problem appears when the file download was interrupted. Please delete the incomplete file from the tmp directory and restart the download. Hope this helps
The problem appears on my Windows10, Anaconda3 ,python3.6.3,but on mac os 10.13, Anaconda3,python3.6.3 run succeed.
If the download gets interrupted, delete the /tmp/imagenet folder and restart the download.
Also, run the file via the command line instead of using IDLE.
Most helpful comment
The problem appears when the file download was interrupted. Please delete the incomplete file from the tmp directory and restart the download. Hope this helps