Failed to download model
From couple hours ago, I tried to download a new model to make classification... but it gave me this message `
INFO:tensorflow:Using /tmp/tfhub_modules to cache modules.
INFO:tensorflow:Downloading TF-Hub Module 'https://tfhub.dev/google/imagenet/mobilenet_v2_140_224/classification/1'.
Traceback (most recent call last):
File "retrain.py", line 1333, in
I tried to download an existed model to test the problem, but it gives me the same error! Any help ?? Note :I tried the image modules links on another PC and Internet connection... The links are not responding! could anyone try to test the module download process, which have been done by Retrain.py code ?
Let us know a bit more info about the environment you are running (py, os versions, are you running on corp network that may have restricted access to some external sites), and the code in question.
I'm running on ubuntu, Python codes And this is my home network, so there is no restricted access there
And I'm using the same retrain.py code from this repo
Could you please provide an output of "wget ' https://tfhub.dev/google/nnlm-en-dim128/1?tf-hub-format=compressed' -O /tmp/module.tar.gz" command? This way we can determine whether the module can be downloaded outside of the library or not.
On Sun, May 20, 2018 at 10:50 AM mohamedaashraf [email protected] wrote:
And I'm using the same train.Py code
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/tensorflow/hub/issues/53#issuecomment-390499180, or mute the thread https://github.com/notifications/unsubscribe-auth/AbunTJE2fjVZ1aGhf1qX0Ls3OHRgAnJfks5t0azagaJpZM4UF9XD .
It's downloading tar file with size more than 400 MB
I will close this issue, since I have found the solution.. I exchanged the download link https://tfhub.dev/google/imagenet/inception_resnet_v2/classification/1 with https://storage.googleapis.com/tensorflow-hub/google/imagenet/inception_resnet_v2/classification/1.tar.gz and now, the download works!
it does not work anymore. I can not download Tf_mode from any of two directories .otherwith, I want download Inception V3 mode, does anyone know the new directory?
im having the same issue
`INFO:tensorflow:Downloading TF-Hub Module 'https://tfhub.dev/google/imagenet/inception_v3/feature_vector/1'. Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 1318, in do_open encode_chunked=req.has_header('Transfer-encoding')) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1239, in request self._send_request(method, url, body, headers, encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1285, in _send_request self.endheaders(body, encode_chunked=encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1234, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1026, in _send_output self.send(msg) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 964, in send self.connect() File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1400, in connect server_hostname=server_hostname) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ssl.py", line 401, in wrap_socket _context=self, _session=session) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ssl.py", line 808, in init self.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ssl.py", line 1061, in do_handshake self._sslobj.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ssl.py", line 683, in do_handshake self._sslobj.do_handshake() ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:748)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "retrain.py", line 1333, in
I have the same issue even after I ran Install Certificates.command. Can you please reopen this issue and have a look?
Please see discussion in #97.
It appears many have installed software that takes control over ".dev" domain. TensorFlow Hub library then fails to reach the proper server (either with an SSL issue or other obscure error).
Users are highly recomended to switch off their ".dev" hijacking into ".test" [reserved for that purposed], since the ".dev" is nowadays a gTLD.
If you believe your issue is not due to ".dev", please create a new issue with an error output of running:
$ wget 'https://tfhub.dev/google/nnlm-en-dim128/1?tf-hub-format=compressed' -O /tmp/module.tar.gz
Avoid fallback to links such as "https://storage.googleapis.com/...", as those may break at anytime with no warning. The only stable url for modules hosted in tfhub.dev are the "https://tfhub.dev/" ones.
You can download your the model need from url + '?tf-hub-format=compressed', such as 'https://tfhub.dev/google/imagenet/pnasnet_large/classification/2?tf-hub-format=compressed' . This file will be named 'x.tar.gz', then make two file in ‘/tmp/tfhub_modules’ named such as '67f40766542914aa2dd2ec6923c4f353f6d0663c' and '67f40766542914aa2dd2ec6923c4f353f6d0663c.descriptor.txt' ,decompression 1.tar.gz to 67f40766542914aa2dd2ec6923c4f353f6d0663c.
Same issue is observed with python 2.7 also(error mentioned by andreyc0d3r. Any working solutions?
wget 'https://tfhub.dev/google/nnlm-en-dim128/1?tf-hub-format=compressed' -O /tmp/module.tar.gz works fine without any issue
I seem have the similar issue for downloading the module. After I imported the import tensorflow_hub as hub then I tried to download a fast-RCNN Module through detector=hub.Module("https://tfhub.dev/google/faster_rcnn/openimages_v4/inception_resnet_v2/1" ) but I got this feedback:
Traceback (most recent call last):
File "
xieximing, you also filed that as https://github.com/tensorflow/hub/issues/169. I will respond there.
embed = hub.Module("https://storage.googleapis.com/tfhub-modules/google/Wiki-words-500-with-normalization")
i had read above comments and make some improvements, but my request don`t have any reponse
The module handles for use with hub.Module, hub.resolve, etc. can either be a filesystem path or the URL of a web service following tensorflow.org/hub/hosting#protocol. Please try https://tfhub.dev/google/Wiki-words-500-with-normalization/1 instead.
Please see discussion in #97.
It appears many have installed software that takes control over ".dev" domain. TensorFlow Hub library then fails to reach the proper server (either with an SSL issue or other obscure error).
Users are highly recomended to switch off their ".dev" hijacking into ".test" [reserved for that purposed], since the ".dev" is nowadays a gTLD.
@andresusanopinto Thanks for your reply. I'm also facing this issue. Could you elaborate on this hijacking issue? How could I find out what's responsible for this?
got the same error, although it worked with a wget command and with a minimal python script importing only tensorflow and the hub. It turned out to be dependency related. I fixed it by changing initial dependency order:
# not working
import csv, os, sys, time, mysql.connector
import tensorflow_hub as hub
into:
# working
import tensorflow_hub as hub # must be imported first to avoid tensorflow error: https://github.com/tensorflow/hub/issues/53
import csv, os, sys, time, mysql.connector
Solved by using this: module_handle = "https://tfhub.dev/tensorflow/faster_rcnn/resnet101_v1_640x640/1"
model = hub.load(module_handle)