1、安装cuda版本后,相应的图形显卡的驱动也要更新到相应的版本,cuDnn版本也要对应,tensorflow也要对应,官网对应表:
https://tensorflow.google.cn/install/source_windows
2、
Traceback (most recent call last):
File "D:\anaconda3\Lib\site.py", line 439, in register_readline
readline.read_history_file(history)
File "D:\anaconda3\Lib\site-packages\pyreadline\rlmain.py", line 165, in read_history_file
self.mode._history.read_history_file(filename)
File "D:\anaconda3\Lib\site-packages\pyreadline\lineeditor\history.py", line 82, in read_history_file
for line in open(filename, 'r'):UnicodeDecodeError: 'gbk' codec can't decode byte 0x90 in position 683: illegal multibyte sequence
这是anaconda的bug,可以 进入到该目录:Anaconda3\Lib\site-packages\pyreadline\lineeditor ,history.py文件的第82行,修改如下:for line in open(filename, 'r',encoding='utf-8'):在原有的open函数里 新增了一个参数选项encoding='utf-8';就可以解决了。
3、
Warning! ***HDF5 library version mismatched error***
The HDF5 header files used to compile this application do not match
the version used by the HDF5 library to which this application is linked.
Data corruption or segmentation faults may occur if the application continues.
This can happen when an application was compiled by one version of HDF5 but
linked with a different version of static or shared HDF5 library.
一个比较简单的办法:
pip uninstall h5py
pip install h5py
链接:https://blog.csdn.net/dreamscape9999/article/details/80701743
4、在anaconda中建立环境时,记得指定python版本,新装一个,否则在该环境下输入python后使用的是conda的python,import tensorflow as tf 会出现找不到模块'tensorflow'的问题。
5、下载出现访问失败,选择国内镜像。
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --set show_channel_urls yes
https://blog.csdn.net/JessieLiu_/article/details/80112278
用pip命令可以用另一种方式
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple/ --upgrade tensorflow-gpu # for Python 2.* and GPU
链接:https://blog.csdn.net/jorg_zhao/article/details/80075293
6/参考教程
https://www.cnblogs.com/wanyu416/p/9536853.html
https://post.smzdm.com/p/748998/