1.下载 Anaconda3/Miniconda3 安装脚本
wget https://repo.anaconda.com/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh
2.安装conda3
bash Miniconda3-4.7.12.1-Linux-x86_64.sh
地址选用:~/work/*conda3#work中的数据不会抹除
3.进入conda环境
source ~/work/*conda3/bin/activate
4.1 安装tensorflow-cpu
pip install tensorflow==1.5.0
4.2 安装tensorflow-gpu-1.12.0
#下载cuda9.0
wget https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/linux-64/cudatoolkit-9.0-h13b8566_0.conda -P pypi2/
#安装cuda9.0
conda install --use-local pypi2/cudatoolkit-9.0-h13b8566_0.conda -c https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
#下载tensorflow-gpu1.2.0和keras2.1.5
python3.6 -m pip download tensorflow-gpu==1.12.0 keras==2.1.5 -i https://pypi.tuna.tsinghua.edu.cn/simple -d pypi2
#安装tensorflow和Keras2.1.5
python3.6 -m pip install tensorflow-gpu==1.12.0 keras==2.1.5 --no-index -f ./pypi2