本文介绍了Tensorflow 错误:DLL 加载失败:找不到指定的程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试在我的 windows8.1 64 位 python3.6.0 中使用 pip 安装 tensorflow cpu使用 pip install tensorflow但它给了我这个错误:

I tried to install tensorflow cpu using pip in my windows8.1 64bit python3.6.0using pip install tensorflowbut it gives me this error:

Traceback (most recent call last):   File "C:\Users\Laitooo
San\Desktop\tf.py", line 1, in <module>
     import tensorflow as tf   File "C:\Users\Laitooo San\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\__init__.py",
 line 24, in <module>
     from tensorflow.python import *   File "C:\Users\Laitooo San\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\__init__.py",
 line 52, in <module>
     from tensorflow.core.framework.graph_pb2 import *   File "C:\Users\Laitooo
 San\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\core\framework\graph_pb2.py",
 line 6, in <module>
     from google.protobuf import descriptor as _descriptor   File "C:\Users\Laitooo
 San\AppData\Local\Programs\Python\Python36\lib\site-packages\google\protobuf\descriptor.py",
 line 47, in <module>
     from google.protobuf.pyext import _message ImportError: DLL load failed: The specified procedure could not be found.

我下载了 python36.dll 并确保所有其他 .dll 都在那里并安装 Microsoft Visual c++ 2015

I downloaded python36.dll and made sure all other .dll is there and install Microsoft visual c++ 2015

我也卸载了 tensorflow 并安装了几次另一个版本,但没有任何结果.

I also uninstalled tensorflow and installed another version several times but without any result.

推荐答案

我也遇到了这个错误,并且能够通过将 protobuf 从 3.6.1 降级到 3.6.0 来解决它:

I had this error as well, and was able to resolve it by downgrading protobuf from 3.6.1 to 3.6.0:

pip install protobuf==3.6.0

这篇关于Tensorflow 错误:DLL 加载失败:找不到指定的程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-25 19:59