Yolov5环境安装
Yolov5环境安装
Yolov5环境安装
视频教程
https://www.bilibili.com/video/BV1bg4y1R7cs/?spm_id_from=333.337.search-card.all.click&vd_source=36039d2edcc53e136d5864352f8ac9f2
miniconda
下载地址:https://mirrors.tuna.tsinghua.edu.cn/anaconda/miniconda/
找到:Miniconda3-py38_22.11.1-1-Windows-x86_64.exe点击下载
如果C盘有控件,最好安装在C盘,且安装目录中不要有中文
勾选将其添加到PATH中
# python版本过高会有写包装不上
conda create -n yolov5 python=3.8
pypi配置国内源,加速下载 https://mirrors.tuna.tsinghua.edu.cn/help/pypi/
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
安装Pytorch
官方地址:https://pytorch.org/get-started/previous-versions/
找到 1.8.2版本
# CUDA 10.2
pip3 install torch==1.8.2 torchvision==0.9.2 torchaudio==0.8.2 --extra-index-url https://download.pytorch.org/whl/lts/1.8/cu102
# CUDA 11.1
pip3 install torch==1.8.2 torchvision==0.9.2 torchaudio==0.8.2 --extra-index-url https://download.pytorch.org/whl/lts/1.8/cu111
# CPU Only
pip3 install torch==1.8.2 torchvision==0.9.2 torchaudio==0.8.2 --extra-index-url https://download.pytorch.org/whl/lts/1.8/cpu
# ROCM5.x
Not supported in LTS.