Win10安装Tensorflow2.0.0遇到的坑

我的电脑没装NVIDIA的显卡,显卡是AMD的低端配置AMD Radeon R5 M430 (2G显存),所以安装的Tensorflow-CPU版本的

  • 首先是安装命令
pip install tensorflow==2.0.0 -i https://mirrors.aliyun.com/pypi/simple/
  • 然后安装结束,尝试导入tensorflow,输入 import tensorflow 以后会出现 ImportError: DLL load failed这样的的错误,以下是转载的某博主的解决办法如下

“ 注:本人猜测,Tensorflow 2.1.0 运行需要安装 VS 2019 的环境,因为,单独安装了 VS 2015 或 VS 2017
的安装环境,均提示导入 Dll 错误,所以,需要下载同时包含,VS 2015、VS2017以及 VS2019 运行环境的安装包 ”


下载地址1:https://support.microsoft.com/zh-cn/help/2977003/the-latest-supported-visual-c-downloads


博主原文的链接:https://blog.csdn.net/lingtianyulong/article/details/104207960/


上面的是官网下载地址,我放在了**腾讯微云**里一份:
下载地址2:https://share.weiyun.com/GfKPnXYt

  • 解决完以上报错后,再次尝试导入 tensorflow,还会出现Warning! ***HDF5 library version mismatched error*** The HDF5 header files u....这个报错,解决方法是直接重装 h5py这个模块:
pip uninstall h5py
pip install h5py

猜你喜欢

转载自blog.csdn.net/weixin_44449518/article/details/106367901