#c 环境检查
ai识别训练因为使用cuda
,和python
, 所以我们需要检查一下对应的版本
#e python
版本查看
python -V
或者
python --version
#e cuda
版本查看
nvcc -V
#e torch
版本查看
pip show torch
#c 切换torch
版本
可能有时候需要使用特定的torch
版本,
在此时需要先使用pip
卸载torch
随后在安装新的torch
版本
#e 卸载torch
pip uninstall torch
#e 安装特定torch
版本
pip install torch==1.8.1+cu111 torchvision==0.9.1+cu111 torchaudio==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html
#c 安装 cuda #c 安装 cudnn