错误:无法加载本机Tensorflow运行时

时间:2019-04-24 15:53:41

标签: tensorflow

我在tensorflow中遇到了这个错误,我找不到解决它的方法。 我有 : 的Python 3.6.8 Tensorflow-GPU 1.13.1 CUDA 10.1 库登7.5.1

错误如下:

Python 3.6.8 (tags/v3.6.8:3c6b436a57, Dec 24 2018, 00:16:47) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow
Traceback (most recent call last):
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 58, in <module>
    from tensorflow.python.pywrap_tensorflow_internal import *
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 28, in <module>
    _pywrap_tensorflow_internal = swig_import_helper()
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 24, in swig_import_helper
    _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)
  File "E:\projects\venv\lib\imp.py", line 243, in load_module
    return load_dynamic(name, filename, file)
  File "E:\projects\venv\lib\imp.py", line 343, in load_dynamic
    return _load(spec)
ImportError: DLL load failed: Le module spécifié est introuvable.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "E:\projects\venv\lib\site-packages\tensorflow\__init__.py", line 24, in <module>
    from tensorflow.python import pywrap_tensorflow  # pylint: disable=unused-import
  File "E:\projects\venv\lib\site-packages\tensorflow\python\__init__.py", line 49, in <module>
    from tensorflow.python import pywrap_tensorflow
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 74, in <module>
    raise ImportError(msg)
ImportError: Traceback (most recent call last):
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 58, in <module>
    from tensorflow.python.pywrap_tensorflow_internal import *
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 28, in <module>
    _pywrap_tensorflow_internal = swig_import_helper()
  File "E:\projects\venv\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 24, in swig_import_helper
    _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)
  File "E:\projects\venv\lib\imp.py", line 243, in load_module
    return load_dynamic(name, filename, file)
  File "E:\projects\venv\lib\imp.py", line 343, in load_dynamic
    return _load(spec)
ImportError: DLL load failed: Le module spécifié est introuvable.


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.

我已遵循此安装指南:https://www.tensorflow.org/install/gpu 我已经按照说明正确编辑了所有路径。

我不太了解如何解决此错误。 谢谢。

1 个答案:

答案 0 :(得分:0)

TF 1.13带有cuda 10.0预先构建的二进制文件。请下载cuda 10.0工具包并更新cuda,cudnn路径。 https://www.tensorflow.org/install/gpu#software_requirements 默认情况下,Nvidia托管最新的cuda版本(当前版本为10.1),而最新的稳定TF二进制文件中可能没有该版本。您可以从此链接https://developer.nvidia.com/cuda-toolkit-archive中选择cuda 10.0。