济南免费网站建设优化,长春市房产交易中心官网,新手建设网站的步骤,专门做衬衣的网站1、安装anaconda
1.1镜像源下载对应anaconda版本后传到服务器上
1.2进入对应文件夹
首先赋权再执行安装程序 chmod x Anaconda3-2022.10-Linux-x86_64.sh ./Anaconda3-2022.10-Linux-x86_64.sh chmod x Anaconda3-2022.10-Linux-x86_64.sh 1.3交互确认
确认许可协议…1、安装anaconda
1.1镜像源下载对应anaconda版本后传到服务器上
1.2进入对应文件夹
首先赋权再执行安装程序 chmod x Anaconda3-2022.10-Linux-x86_64.sh ./Anaconda3-2022.10-Linux-x86_64.sh chmod x Anaconda3-2022.10-Linux-x86_64.sh 1.3交互确认
确认许可协议一路enter然后yes 更改安装路径/mnt/data/anaconda3 确认.bashrc文件中初始化Anaconda3的相关内容。yes 添加内容如下 安装完成后直接输入conda应该会提示说没找到该命令这时候执行source ~/.bashrc之后就可以正常使用了。
1.4配置其他用户可用
修改文件vim /etc/profile在最后一行添加 export PATH$PATH:/mnt/data/anaconda3/bin 重启生效 source /etc/profile 共享环境 groupadd anaconda # 创建anaconda组 chgrp -R anaconda /mnt/data/anaconda3# 组内共享这个目录下的文件 chmod 770 -R /mnt/data/anaconda3# 设置权限 usermod -a -G anaconda username# 添加用户进组 source /etc/profile # 进组的用户可能需要自己刷新一下 1.5更新默认pip源 # pip安装 python -m pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --upgrade pip pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple 1.6更新conda源
修改文件/root/.condarc channels: - https://mirrors.ustc.edu.cn/anaconda/pkgs/free/ - https://mirrors.ustc.edu.cn/anaconda/pkgs/main/ - https://mirrors.ustc.edu.cn/anaconda/cloud/conda-forge/ - https://mirrors.ustc.edu.cn/anaconda/cloud/bioconda/ show_channel_urls: true 2、pytorch安装
查询版本 目前的驱动和cuda版本最多支持到pytorch1.10.0版本Previous PyTorch Versions | PyTorch
创建环境 conda create -n pytorch python3.8 更新源 python -m pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --upgrade pip pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple 安装pytorch pip install torch1.10.0cu111 torchvision0.11.0cu111 torchaudio0.10.0 -f https://download.pytorch.org/whl/torch_stable.html 服务器下载太慢从本地下好后传上去 cd /mnt/data/anaconda3/envs/pytorch pip install torch #先别回车按一下键盘上的Tab键会自动补全成下面的命令 回车再次输入 pip install torch1.10.0cu111 torchvision0.11.0cu111 torchaudio0.10.0 安装成功 python import torch torch.__version__ 返回 3、tensorflow安装
安装2.4版本 tensorflow · PyPI下载后传输到服务器文件夹。进入文件夹 pip install tensorflow-2.4.0-cp38-cp38-manylinux2010_x86_64.whl 安装cudatoolkit11.0 conda install cudatoolkit11.0 -c http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main 安装cudnn8.0
去nvidia官网下载cuDNN Archive | NVIDIA Developer
上传到对应文件夹解压压缩包 tar zxvf cudnn-11.0-linux-x64-v8.0.5.39.tgz 将解压出的两个文件夹中的文件复制到tf2下的对应文件夹中 python import tensorflow as tf print(tf.__version__) tf.test.is_gpu_available() 返回True安装成功