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

DLL load fail _pywrap_tensorflow_internal during CPU-only installation #43052

Closed
sRassmann opened this issue Sep 8, 2020 · 5 comments
Closed
Assignees
Labels
subtype:windows Windows Build/Installation Issues TF 2.3 Issues related to TF 2.3 type:build/install Build and install issues

Comments

@sRassmann
Copy link

I am trying to install the CPU-only version of tf.

System information

I tried to install tensorflow to an existing environment, which already didn't work. Trying to the fix the issue, I uninstalled anaconda (incl. caches, pip, and conda) and installed miniconda. Running the following commands:

$ conda create --name tf_test
$ activate tf_test
$ pip install tensorflow
$ python
>>>import tensorflow

I am getting the same error as before, which stays the same also without activating the conda environment:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\__init__.py", line 41, in <module>
    from tensorflow.python.tools import module_util as _module_util
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\python\__init__.py", line 40, in <module>
    from tensorflow.python.eager import context
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\python\eager\context.py", line 35, in <module>
    from tensorflow.python import pywrap_tfe
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\python\pywrap_tfe.py", line 28, in <module>
    from tensorflow.python import pywrap_tensorflow
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 83, in <module>
    raise ImportError(msg)
ImportError: Traceback (most recent call last):
  File "C:\Users\sebas\miniconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 64, in <module>
    from tensorflow.python._pywrap_tensorflow_internal import *
ImportError: DLL load failed while importing _pywrap_tensorflow_internal: Das angegebene Modul wurde nicht gefunden. 
(*The specified module could not be found.*) 


Failed to load the native TensorFlow runtime.

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

for some common reasons and solutions.  Include the entire stack trace
above this error message when asking for help.

Thanks for your help!

@sRassmann sRassmann added the type:build/install Build and install issues label Sep 8, 2020
@bhack
Copy link
Contributor

bhack commented Sep 8, 2020

Tensorflow doesn't directly support conda setup but you can follow https://docs.anaconda.com/anaconda/user-guide/tasks/tensorflow/

@Saduf2019 Saduf2019 added TF 2.3 Issues related to TF 2.3 subtype:windows Windows Build/Installation Issues labels Sep 9, 2020
@Saduf2019
Copy link
Contributor

@sRassmann
You could be facing this issue because of the following reasons

You you running 32-bit Python or 32-bit OS
Please take a look at the system requirements and check if you have the correct dependencies installed.

Also, check these similar duplicate issues: #42058 #41596 #40459 #39007 #38916 #36167 #36151 #36138 #36054 #36045 #36020 #36003 #35988 #35903 #35880 #35865 #35805 #35789 #35773 #35772 #35767 .

In case you still face issues after verifying the above, please create a issue on Anaconda repo., and move this to closed status.
Thanks!

@Saduf2019 Saduf2019 added the stat:awaiting response Status - Awaiting response from author label Sep 9, 2020
@sRassmann
Copy link
Author

@Saduf2019 & @bhack Thank you for your help!!

I performed the following steps:

  • Completely uninstalled everything (ana-/miniconda and related folders)
  • Installed vanilla python 3.7.0
  • run $ pip install tensorflow
  • Now $ python and >>> import tensorflow worked seamlessly (besides the warning for not using GPU)

Interestingly, after I reinstalled miniconda, tensorflow also worked within conda environments.

@google-ml-butler
Copy link

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

@Saduf2019
Copy link
Contributor

@sRassmann
Glad to hear we could help you resolve the issue, thanks for the update.

@Saduf2019 Saduf2019 removed the stat:awaiting response Status - Awaiting response from author label Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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

3 participants