Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: DLL load failed: The specified module could not be found. #42087

Closed
SRJaffry opened this issue Aug 6, 2020 · 3 comments
Closed
Assignees
Labels
stat:awaiting response Status - Awaiting response from author subtype:windows Windows Build/Installation Issues TF 2.3 Issues related to TF 2.3 type:build/install Build and install issues

Comments

@SRJaffry
Copy link

SRJaffry commented Aug 6, 2020

I am getting the following error when trying to import tensorflow. I have tried many solutions and non seem to work.

I have seen Issue #22794, but it does not seem to help.

Versions -- > python 3.7.4 -- > tensorflow 2.3.0

runfile('C:/Users/pshad/.spyder-py3/temp.py', wdir='C:/Users/pshad/.spyder-py3')
Traceback (most recent call last):

File "", line 1, in
runfile('C:/Users/pshad/.spyder-py3/temp.py', wdir='C:/Users/pshad/.spyder-py3')

File "C:\Users\pshad\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 827, in runfile
execfile(filename, namespace)

File "C:\Users\pshad\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 110, in execfile
exec(compile(f.read(), filename, 'exec'), namespace)

File "C:/Users/pshad/.spyder-py3/temp.py", line 9, in
import tensorflow as tf

File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow_init_.py", line 41, in
from tensorflow.python.tools import module_util as _module_util

File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow\python_init_.py", line 40, in
from tensorflow.python.eager import context

File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow\python\eager\context.py", line 35, in
from tensorflow.python import pywrap_tfe

File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow\python\pywrap_tfe.py", line 28, in
from tensorflow.python import pywrap_tensorflow

File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 83, in
raise ImportError(msg)

ImportError: Traceback (most recent call last):
File "C:\Users\pshad\Anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 64, in
from tensorflow.python._pywrap_tensorflow_internal import *
ImportError: DLL load failed: The specified module could not be found.

Failed to load the native TensorFlow runtime.

See https://www.tensorflow.org/install/errors

I tried to reinstall the tensorflow, downgrade, and upgrade as well. Nothing seem to work, unfortunately.

@ravikyram
Copy link
Contributor

ravikyram commented Aug 6, 2020

@SRJaffry

What is make/model of your cpu?
I suspect your cpu model does not support AVX instructions sets.See hardware requirements
Make sure to download the latest microsoft visual c++ redistributable from here.
.Also, please follow the instructions from to install from Tensorflow website.

Please, check Your CPU/Python is on 32 bits?Please, refer #36167 and see if it helps you.Please, refer similar issues #36167 #36151 #36138 #36054 #36045 #36020 #36003 #35988 #35903 #35880 #35865 #35805 #35789 #35773 #35772 #35767 #35766 #35749 #35721 #35618 #35204
Thanks!

@ravikyram ravikyram added subtype:windows Windows Build/Installation Issues TF 2.3 Issues related to TF 2.3 type:build/install Build and install issues stat:awaiting response Status - Awaiting response from author labels Aug 6, 2020
@SRJaffry
Copy link
Author

SRJaffry commented Aug 6, 2020

Thanks, I installed the latest distribution of Visual C++ from the link your shared and the problem seem to solve. Thank you.

@SRJaffry SRJaffry closed this as completed Aug 6, 2020
@google-ml-butler
Copy link

Are you satisfied with the resolution of your issue?
Yes
No

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stat:awaiting response Status - Awaiting response from author subtype:windows Windows Build/Installation Issues TF 2.3 Issues related to TF 2.3 type:build/install Build and install issues
Projects
None yet
Development

No branches or pull requests

2 participants