Skip to content

ImportError: No module named '_pywrap_tensorflow' Failed to load the native TensorFlow runtime. #8385

Description

@WahabZia

Apologies for the inappropriate description i am actually very new to Machine learning my

TF version is 1.0.1
Python version is 3.5.2
OS windows 8 64bit and
Native pip
as recommended on tensor flow.org
https://www.python.org/downloads/release/python-352/

The problem ocured at this simple import command

import tensorflow as tf

What other attempted solutions have you tried?

None

Logs or other output that would be helpful

(If logs are large, please upload as attachment or provide link).

C:\Users\test\Desktop>>python firstp.py
Traceback (most recent call last):
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 18, in swig_import_helper
return importlib.import_module(mname)
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\importlib_ini
t
_.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 986, in _gcd_import
File "", line 969, in _find_and_load
File "", line 958, in _find_and_load_unlocked
File "", line 666, in _load_unlocked
File "", line 577, in module_from_spec
File "", line 906, in create_module
File "", line 222, in _call_with_frames_removed
ImportError: DLL load failed: The specified module could not be found.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python_init_.py", line 66, in
from tensorflow.python import pywrap_tensorflow
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 21, in
_pywrap_tensorflow = swig_import_helper()
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 20, in swig_import_helper
return importlib.import_module('pywrap_tensorflow')
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\importlib_ini
t
.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: No module named '_pywrap_tensorflow'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\test\Desktop\firstp.py", line 1, in
import tensorflow as tf
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow_init_.py", line 24, in
from tensorflow.python import *
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python_init_.py", line 72, in
raise ImportError(msg)
ImportError: Traceback (most recent call last):
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 18, in swig_import_helper
return importlib.import_module(mname)
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\importlib_ini
t
_.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 986, in _gcd_import
File "", line 969, in _find_and_load
File "", line 958, in _find_and_load_unlocked
File "", line 666, in _load_unlocked
File "", line 577, in module_from_spec
File "", line 906, in create_module
File "", line 222, in _call_with_frames_removed
ImportError: DLL load failed: The specified module could not be found.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python_init_.py", line 66, in
from tensorflow.python import pywrap_tensorflow
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 21, in
_pywrap_tensorflow = swig_import_helper()
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\site-packages\t
ensorflow\python\pywrap_tensorflow.py", line 20, in swig_import_helper
return importlib.import_module('pywrap_tensorflow')
File "C:\Users\test\AppData\Local\Programs\Python\Python35\lib\importlib_ini
t
.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: No module named '_pywrap_tensorflow'

Failed to load the native TensorFlow runtime.

See https://github.com/tensorflow/tensorflow/blob/master/tensorflow/g3doc/get_st
arted/os_setup.md#import_error

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

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions