tensorflow-gpu安装遇到的坑
tensorflow-gpu安装好导入,一直出现以下错误
折腾了好久。
错误之前也按照中国官网安装及配置各环境变量:https://tensorflow.google.cn/install/gpu

其次基于anaconda+Python3.7安装tensorflow_gpu-2.2.0-cp37也安装成功。
但import tensorflow as tf总出现以下错误。

ImportError Traceback (most recent call last)
D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py in <module>
57
---> 58 from tensorflow.python.pywrap_tensorflow_internal import *
59 D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py in <module>
27 return _mod
---> 28 _pywrap_tensorflow_internal = swig_import_helper()
29 del swig_import_helper D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py in swig_import_helper()
23 try:
---> 24 _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)
25 finally: D:\soft\anaconda3\lib\imp.py in load_module(name, file, filename, details)
241 else:
--> 242 return load_dynamic(name, filename, file)
243 elif type_ == PKG_DIRECTORY: D:\soft\anaconda3\lib\imp.py in load_dynamic(name, path, file)
341 name=name, loader=loader, origin=path)
--> 342 return _load(spec)
343 ImportError: DLL load failed: 找不到指定的模块。 During handling of the above exception, another exception occurred: ImportError Traceback (most recent call last)
<ipython-input-1-64156d691fe5> in <module>
----> 1 import tensorflow as tf D:\soft\anaconda3\lib\site-packages\tensorflow\__init__.py in <module>
39 import sys as _sys
40
---> 41 from tensorflow.python.tools import module_util as _module_util
42 from tensorflow.python.util.lazy_loader import LazyLoader as _LazyLoader
43 D:\soft\anaconda3\lib\site-packages\tensorflow\python\__init__.py in <module>
48 import numpy as np
49
---> 50 from tensorflow.python import pywrap_tensorflow
51
52 # Protocol buffers D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py in <module>
67 for some common reasons and solutions. Include the entire stack trace
68 above this error message when asking for help.""" % traceback.format_exc()
---> 69 raise ImportError(msg)
70
71 # pylint: enable=wildcard-import,g-import-not-at-top,unused-import,line-too-long ImportError: Traceback (most recent call last):
File "D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 58, in <module>
from tensorflow.python.pywrap_tensorflow_internal import *
File "D:\soft\anaconda3\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 28, in <module>
_pywrap_tensorflow_internal = swig_import_helper()
File "D:\soft\anaconda3\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 "D:\soft\anaconda3\lib\imp.py", line 242, in load_module
return load_dynamic(name, filename, file)
File "D:\soft\anaconda3\lib\imp.py", line 342, in load_dynamic
return _load(spec)
ImportError: DLL load failed: 找不到指定的模块。 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.
解决方法:
卸载。换版本,pip install tensorflow-gpu==1.15.0
成功:


tensorflow-gpu安装遇到的坑的更多相关文章
- TensorFlow DeepLab教程初稿-tensorflow gpu安装教程
TensorFlow DeepLab教程初稿-tensorflow gpu安装教程 商务合作,科技咨询,版权转让:向日葵,135-4855__4328,xiexiaokui#qq.com Summar ...
- tensorflow -gpu安装,史上最新最简单的途径(不用自己装cuda,cdnn)
tensorflow -gpu安装首先,安装Anoconda1. 官网下载点我: 2.安装 点击 python 3.6 version自动下载x64版,下载好之后,然后安装. 如图,打上勾之后,一路n ...
- 【转】Ubuntu 16.04安装配置TensorFlow GPU版本
之前摸爬滚打总是各种坑,今天参考这篇文章终于解决了,甚是鸡冻\(≧▽≦)/,电脑不知道怎么的,安装不了16.04,就安装15.10再升级到16.04 requirements: Ubuntu 16.0 ...
- Ubuntu 16.04 + CUDA 8.0 + cuDNN v5.1 + TensorFlow(GPU support)安装配置详解
随着图像识别和深度学习领域的迅猛发展,GPU时代即将来临.由于GPU处理深度学习算法的高效性,使得配置一台搭载有GPU的服务器变得尤为必要. 本文主要介绍在Ubuntu 16.04环境下如何配置Ten ...
- Win10上安装Keras 和 TensorFlow(GPU版本)
一. 安装环境 Windows 10 64bit 家庭版 GPU: GeForce GTX1070 Python: 3.5 CUDA: CUDA Toolkit 8.0 GA1 (Sept 2016 ...
- ubuntu16.04下安装TensorFlow(GPU加速)----详细图文教程【转】
本文转载自:https://blog.csdn.net/zhaoyu106/article/details/52793183 le/details/52793183 写在前面 一些废话 接触深度学习已 ...
- Google TensorFlow for GPU安装、配置大坑
Google TensorFlow for GPU安装.配置大坑 从本周一开始(12.05),共4天半的时间,终于折腾好Google TensorFlow for GPU版本,其间跳坑无数,摔得遍体鳞 ...
- 备注: ubt 16.04 安装 gtx 1060 --- 成功运行 tensorflow - gpu
---------------------------------------------------------------------------------------------------- ...
- win10系统下安装TensorFlow GPU版本
首先要说,官网上的指南是最好的指南. https://www.tensorflow.org/install/install_windows 需要FQ看. 想要安装gpu版本的TensorFlow.我们 ...
- 通过Anaconda在Ubuntu16.04上安装 TensorFlow(GPU版本)
一. 安装环境 Ubuntu16.04.3 LST GPU: GeForce GTX1070 Python: 3.5 CUDA Toolkit 8.0 GA1 (Sept 2016) cuDNN v6 ...
随机推荐
- JZOJ 3992.Christmas
题目大意 给定一个数列,支持区间加一个数和区间取 \(max\),询问单点询问数值和它被更改的次数 思路 模板的吉司机线段树 维护区间最小值和严格次小值以及最小值的个数 针对询问维护区间和以及区间修改 ...
- @Transactional千万不要这样用!!踩坑了你都可能发现不了!!!
前阵子接手了一段同事之前的代码,里面用到了@Transactional注解,了解Spring的小伙伴肯定知道,@Transactional是Spring提供的一种控制事务管理的快捷手段.但是我这段程序 ...
- Os-hackNos
Os-hackNos 目录 Os-hackNos 1 环境配置 1.1 靶场环境 1.2 靶机未获取到IP时配置 2 信息收集 2.1 端口扫描 2.2 目录扫描 3 对Drupal 7.57版本安全 ...
- 多个module的verilog文件分割为多个文件
python 分割含有多个module的verilog文件,按照module名来命名文件 import re # 读取 Verilog 文件 with open('test.v', 'r') as f ...
- navicat无法识别登录秘钥
前因 公司数据库未开放外网访问端口,只允许内网登录,这对开发人员查看数据很不友好,所以一般情况下都会让开发人员通过navicat的ssh隧道功能来查看数据. 但在测试ssh隧道过程中,私钥1验证通过, ...
- WebForm发布IIS后,报错无谓词错误
需要在Config文件中添加默认页面 <system.webServer> <defaultDocument> <files> <add value=&quo ...
- react 02 组件state click
一,组件 import React from 'react'; import ReactDOM from 'react-dom'; import './index.css'; // 函数式组件 ret ...
- vue移动端禁止弹层穿透、点击元素滚动到视图中心杂文日志
一,需求是在无限列card加载页面,点击任何一个card的显示图表按钮,图表自适应居中显示,显示遮罩层,页面可以滑动,但不能穿透点击 一个无限列表加载页面设置遮罩层一般需求是页面不能滑动的,但这比较特 ...
- VUE学习-自定义指令
自定义指令 有的情况下,你仍然需要对普通 DOM 元素进行底层操作,这时候就会用到自定义指令. <div id="directive-demo"> <input ...
- Junit单元测试简单使用
第一步:pom文件引入相关文件 <dependency> <groupId>org.springframework.boot</groupId> <artif ...