yolov5环境配置

目录

  • 背景
    • 1、Anaconda3安装
      • (1)安装Anaconda3后,换源遇到的问题
      • (2)处理方法
      • (3)Anaconda3环境变量配置
    • 2、显卡驱动安装
    • 3、安装CUDA
      • (1)安装CUDA
      • (2) 安装cuDNN
      • (3)CUDA环境配置
    • 4、安装pytorch,配置pytorch环境,克隆yolov5包
      • (1)安装pytorch
      • (2)检测是否安装成功
      • (3)yolov5-v3.1源码安装配置
      • (4)测试yolov5环境代码
    • 完整安装步骤

背景

Windows系统下,()括号中为我安装的版本或者对版本解释
1、安装Anaconda3(我的版本),配置好环境变量(不同版本环境变量文件可能不同)
2、安装电脑对应的显卡版本驱动(NVIDIA GeForce GTX 1050)
3、安装CUDA(10.2版本),成功安装后再安装cuDNN(一定是对应于CUDA版本)
4、安装pytorch,配置pytorch环境,克隆yolov5包

1、Anaconda3安装

史上最全最详细的Anaconda安装教程
官网个人版:https://www.anaconda.com/products/distribution
镜像网站:https://mirrors.tuna.tsinghua.edu.cn/anaconda/archive/

博主使用的版本是:

Anaconda3-5.2.0-Windows-x86_64.exe

为什么不用最新版的

Anaconda3-5.3.1-Windows-x86_64.exe

不知是版本原因还是什么原因,包括博主在内的一大堆使用这个最新版本在构建虚拟环境或者安装包时出现了这样蛋疼的错误

无法定位程序输入点 OPENSSL_sk_new_reserve 于动态链接库 E:\ProgramData\Anaconda3\Library\bin\libssl-1_1-x64.dll上

最后有博文指出回退3-5.2.0版本毛事木有

————————————————
版权声明:本文为CSDN博主「OSurer」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/wq_ocean_/article/details/103889237

(1)安装Anaconda3后,换源遇到的问题

在Anaconda Prompt终端中输入以下镜像源

#添加镜像源
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2

#显示检索路径
conda config --set show_channel_urls yes
#显示镜像通道
conda config --show channels

#安装镜像
conda config --add channels http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
conda config --add channels http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
conda config --add channels http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
conda config --add channels http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro
conda config --add channels http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2



#配置好以上的镜像源,输入如下代码安装pytorch出错
#代码解释:创建一个名称为yolov5文件名的环境配置,名称可以自己取;python=3.8建立一个3.8版本的python环境
#该环境安装成功后位置在 D:\softwave\Anaconda3\envs\yolov5
conda create -n yolov5 python=3.8

#之后再输入 CUDA 10.2安装配置,同样安装出错
conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.2 -c pytorch

yolov5环境配置_第1张图片

(2)处理方法

#删除之前的镜像源,恢复默认状态
conda config --remove-key channels

#找到下图文件位置
#如果不知道该文件位置可以打开Anaconda Prompt终端,就可以确定该文件位置

yolov5环境配置_第2张图片

yolov5环境配置_第3张图片
打开.condarc文件,默认时候如下

yolov5环境配置_第4张图片
.condarc文件内容修改成:

show_channel_urls: true
channels:
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro

yolov5环境配置_第5张图片
这便成功换源了


这里强调:在配置好pytorch环境之后再换源上面的代码,不然在
conda create -n pytorch1.8.0 python=3.8输入代码后会报错
所以在输入上面这段代码之前先不换源哦!!!!!!!!!!!

如果后续出现下载pytorch报错,说系统文件不存在,可以尝试使用这个置换.condarc文件
(删除 - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge)

show_channel_urls: true
channels:
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
  - http://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro

还有在换源之后,不要随便更新conda
conda update -n base -c defaults conda
上面这个命令,非必要不要执行,至少我执行就出问题了。因为这个更新使用的是conda默认的源,会和我们通过清华源安装的包冲突,这就会很麻烦

(3)Anaconda3环境变量配置

在系统变量path加入

C:\Windows\System32
D:\softwave\Anaconda3
D:\softwave\Anaconda3\Scripts
D:\softwave\Anaconda3\Library\mingw-w64\bin
D:\softwave\Anaconda3\Library\bin

yolov5环境配置_第6张图片
在Anaconda Prompt终端输入

conda

结果如下表示环境配置成功
yolov5环境配置_第7张图片

2、显卡驱动安装

从设备管理器找到自己的显卡型号,在驱动下载找到对应型号(NVIDIA GeForce GTX 1050)
NVIDIA 驱动下载:https://www.nvidia.cn/Download/index.aspx?lang=cn#
yolov5环境配置_第8张图片
安装顺序按照NVIDIA安装包安装即可,安装路径最好默认,之后的环境变量好配置。
安装成功后,在cmd中输入:nvidia-smi
如果有错误:
‘nvidia-smi’ 不是内部或外部命令,也不是可运行的程序 或批处理文件。
把C:\Program Files\NVIDIA Corporation\NVSMI添加到环境变量的path中,记住不是系统变量,再重新打开cmd窗口。
(若无NVSMI文件,将NVSMI.zip解压到C:\Program Files\NVIDIA Corporation\即可
链接:https://pan.baidu.com/s/11zFYKpH0rYx9KMyuQt2rpQ
提取码:yz25)

yolov5环境配置_第9张图片

红框内是显卡支持的最大CUDA版本,向下兼容,我安装的是CUDA 10.2版本。

yolov5环境配置_第10张图片

3、安装CUDA

本人安装的10.2版本https://developer.nvidia.com/cuda-10.2-download-archive
官网地址:https://developer.nvidia.com/cuda-downloads

yolov5环境配置_第11张图片
yolov5环境配置_第12张图片
下载3个文件,后得到文件:cuda_10.2.89_441.22_win10.exe和2个同样是exe后缀的文件补丁包

(1)安装CUDA

yolov5环境配置_第13张图片
yolov5环境配置_第14张图片

安装时可以勾选Visual Studio Integration

(2) 安装cuDNN

cuDNN下载地址:https://developer.nvidia.com/rdp/cudnn-download
需要有账号(在cuDNN地址注册即可)

yolov5环境配置_第15张图片

下载后得到文件:cudnn-windows-x86_64-8.7.0.84_cuda10-archive.zip
配置完CUDA环境后需要使用

(3)CUDA环境配置

计算机上点右键,打开属性->高级系统设置->环境变量,可以看到系统中多了CUDA_PATH和
CUDA_PATH_V10_2两个环境变量。(该变量是安装好CUDA自然形成的)
下面的配置都是【系统变量】
yolov5环境配置_第16张图片

接下来,还要在系统中添加以下几个环境变量: 这是默认安装位置的路径: 
CUDA_SDK_PATH = C:\ProgramData\NVIDIA Corporation\CUDA Samples\v10.2 
CUDA_LIB_PATH = %CUDA_PATH%\lib\x64 CUDA_BIN_PATH = %CUDA_PATH%\bin 
CUDA_SDK_BIN_PATH = %CUDA_SDK_PATH%\bin\win64 
CUDA_SDK_LIB_PATH = %CUDA_SDK_PATH%\common\lib\x64

在系统变量 Path 的末尾添加:
%CUDA_LIB_PATH%;%CUDA_BIN_PATH%;%CUDA_SDK_LIB_PATH%;%CUDA_SDK_BIN_PATH%;

继续添加如下5条(默认安装路径):
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\lib\x64 
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\include 
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\extras\CUPTI\lib64 
C:\ProgramData\NVIDIA Corporation\CUDA Samples\v10.2\bin\win64 
C:\ProgramData\NVIDIA Corporation\CUDA Samples\v10.2\common\lib\x64

yolov5环境配置_第17张图片

复制cudnn文件
对于cudnn直接将其解开压缩包,然后需要将bin,include,lib中的文件复制粘贴到cuda的文件夹下
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2

最后打开cmd,输入nvcc -V
如下图所示表示CUDA安装成功
yolov5环境配置_第18张图片
显卡配置就算告一段落

4、安装pytorch,配置pytorch环境,克隆yolov5包

(1)安装pytorch

打开Anaconda Prompt终端

#代码解释:创建一个名称为yolov5文件名的环境配置,名称可以自己取;python=3.8建立一个3.8版本的python环境
#该环境安装成功后位置在 D:\softwave\Anaconda3\envs\yolov5
#输入
conda create -n yolov5 python=3.8

#成功安装后继续输入如下代码
conda activate yolov5

#表示在创建的yolov5环境下执行后续程序  
#该环境地址前文所讲在Anaconda3安装路径下 D:\softwave\Anaconda3\envs\yolov5
#继续输入代码
conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.2


#注释:与conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.2 -c pytorch区别
#带-c pytorch表示默认安装,下载速度慢可能安装不成功
#不带-c pytorch表示从配置的源安装,速度快安装成功率高

#目的安装pytorch头文件,torchvision头文件,cudatoolkit等头文件,
所有安装好的文件在D:\softwave\Anaconda3\envs\yolov5\Lib\site-packages下
pytorch-1.6.0              |py3.7_cuda102_cudnn7_0
torchvision-0.7.0          |       py37_cu102
#这只是其中2个关键安装包,表示下载的安装包是基于CUDA运行的,运行的时候Using CUDA
#所有的安装包都是为了CUDA
#而如果直接运行conda install pytorch torchvision cudatoolkit=10.2 -c pytorch
#安装后的配置文件运行Using CPU,安装的pytorch可能是为了配置CPU的包

根据CUDA版本要求,你可以安装不同的pytorch版本
旧地址:https://pytorch.org/get-started/previous-versions/
新地址:https://pytorch.org/get-started/locally/
CUDA旧版本界面
yolov5环境配置_第19张图片
CUDA新版本界面
yolov5环境配置_第20张图片

(2)检测是否安装成功

import torch # 如果pytorch安装成功即可导入
print(torch.cuda.is_available()) # 查看CUDA是否可用
print(torch.cuda.device_count()) # 查看可用的CUDA数量
print(torch.version.cuda) # 查看CUDA的版本号

结果显示如下则安装成功
print(torch.cuda.is_available()) 显示 True
print(torch.cuda.device_count()) 显示 1
print(torch.version.cuda) 显示CUDA版本
yolov5环境配置_第21张图片

(3)yolov5-v3.1源码安装配置

下载yolov5-v3.1源码和权重文件,地址:https://github.com/ultralytics/yolov5/releases/tag/v3.1
如果下载失败可以直接进网盘:
链接:https://pan.baidu.com/s/16aWKDBAiZPTrQJFIS_Pc7A
提取码:yz25
yolov5环境配置_第22张图片
如需其他版本,下载地址:https://github.com/ultralytics/yolov5
yolov5环境配置_第23张图片

下载好之后,解压yolov5源码安装包(解压地址要记住)
yolov5环境配置_第24张图片

将yolov5s.pt,yolov5m.pt,yolov5l.pt,yolov5x.pt权重文件,放置在weights文件夹下(该文件在yolov5代码压缩包下)
yolov5环境配置_第25张图片

(4)测试yolov5环境代码

打开Anaconda Prompt终端转移到yolov5-v3.1压缩包位置下,转移方法如下图(conda activate yolov5)
yolov5环境配置_第26张图片

#执行代码
pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple

#代码是将yolov5代码包requirements.txt记事本下的头文件包下载到 
D:\softwave\Anaconda3\envs\yolov5\Lib\site-packages下

最后运行代码段测试

(运行环境)conda activate yolov5
(运行地址)(yolov5)D:\yolov5-v3.1>
python detect.py --source ./inference/images/ --weights weights/yolov5s.pt --conf 0.4

#代码表示处理yolov5-v3.1源码下inference文件内的2张图片,图像识别
#结果如下
Using CUDA表示为显卡运算
时间为处理的图片时间
最后表示处理的图片位置output

#表示处理成功,所有的文件配置完成,环境搭建成功!!!!!!!!!

yolov5环境配置_第27张图片
yolov5环境配置_第28张图片
yolov5环境配置_第29张图片

完整安装步骤

(base) C:\Users\asus>conda create -n yolov5 python=3.8
Solving environment: done


==> WARNING: A newer version of conda exists. <==
  current version: 4.5.4
  latest version: 23.1.0

Please update conda by running

    $ conda update -n base conda



## Package Plan ##

  environment location: D:\softwave\Anaconda3\envs\yolov5

  added / updated specs:
    - python=3.8


The following NEW packages will be INSTALLED:

    bzip2:           1.0.8-h8ffe710_4          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    ca-certificates: 2022.9.24-h5b45459_0      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libffi:          3.4.2-h8ffe710_5          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libsqlite:       3.40.0-hcfcfb64_0         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libzlib:         1.2.13-hcfcfb64_4         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    openssl:         3.0.7-hcfcfb64_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pip:             22.3.1-pyhd8ed1ab_0       http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    python:          3.8.13-hcf16a7b_0_cpython http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    setuptools:      65.5.1-pyhd8ed1ab_0       http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    sqlite:          3.40.0-hcfcfb64_0         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    tk:              8.6.12-h8ffe710_0         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    ucrt:            10.0.22621.0-h57928b3_0   http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    vc:              14.3-h3d8a991_9           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    vs2015_runtime:  14.32.31332-h1d6e394_9    http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    wheel:           0.38.4-pyhd8ed1ab_0       http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    xz:              5.2.6-h8d14728_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: failed
ERROR conda.core.link:_execute(502): An error occurred while installing package 'http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge::setuptools-65.5.1-pyhd8ed1ab_0'.
FileNotFoundError(2, '系统找不到指定的文件。', None, 2, None)
Attempting to roll back.

Rolling back transaction: done

FileNotFoundError(2, '系统找不到指定的文件。', None, 2, None)



(base) C:\Users\asus>conda activate yolov5

(yolov5) C:\Users\asus>conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.2
Solving environment: done


==> WARNING: A newer version of conda exists. <==
  current version: 4.5.4
  latest version: 23.1.0

Please update conda by running

    $ conda update -n base conda



## Package Plan ##

  environment location: D:\softwave\Anaconda3\envs\yolov5

  added / updated specs:
    - cudatoolkit=10.2
    - pytorch==1.6.0
    - torchvision==0.7.0


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    msys2-conda-epoch-20160418 |                1           2 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    xorg-libxdmcp-1.1.3        |       hcd874cb_0          66 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    python-3.7.1               |    h9460c21_1003        20.2 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    lerc-4.0.0                 |       h63175ca_0         190 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libwebp-base-1.2.4         |       h8ffe710_0         328 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-gcc-libs-5.3.0       |                7         518 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    tbb-2021.7.0               |       h91493d7_0         174 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    liblapacke-3.9.0           |     16_win64_mkl         5.6 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    intel-openmp-2022.1.0      |    h57928b3_3787         3.7 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    numpy-1.21.6               |   py37h2830a78_0         5.3 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    zstd-1.5.2                 |       h7755175_4         401 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    torchvision-0.7.0          |       py37_cu102         6.4 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
    libpng-1.6.38              |       h19919ed_0         773 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libcblas-3.9.0             |     16_win64_mkl         5.6 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    blas-devel-3.9.0           |     16_win64_mkl          13 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    blas-2.116                 |              mkl          14 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    mkl-include-2022.1.0       |     h6a75c08_874         760 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-libwinpthread-git-5.0.0.4634.697f757|                2          30 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    jpeg-9e                    |       h8ffe710_2         366 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    python_abi-3.7             |          2_cp37m           4 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-gcc-libs-core-5.3.0  |                7         213 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    mkl-devel-2022.1.0         |     h57928b3_875         7.1 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pytorch-1.6.0              |py3.7_cuda102_cudnn7_0       705.3 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
    pillow-9.2.0               |   py37h42a8222_2        45.4 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    openjpeg-2.5.0             |       hc9384bd_1         256 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    liblapack-3.9.0            |     16_win64_mkl         5.6 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libdeflate-1.14            |       hcfcfb64_0          73 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    freetype-2.12.1            |       h546665d_0         506 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-gmp-6.1.0            |                2         689 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    libxcb-1.13                |    hcd874cb_1004         1.3 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-gcc-libgfortran-5.3.0|                6         340 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    pthread-stubs-0.4          |    hcd874cb_1001           6 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    xorg-libxau-1.0.9          |       hcd874cb_0          57 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    mkl-2022.1.0               |     h6a75c08_874       182.7 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    lcms2-2.14                 |       h90d422f_0         988 KB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libblas-3.9.0              |     16_win64_mkl         5.6 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libtiff-4.4.0              |       h8e97e67_4         1.1 MB  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    ------------------------------------------------------------
                                           Total:      1007.4 MB

The following NEW packages will be INSTALLED:

    blas:                    2.116-mkl                    http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    blas-devel:              3.9.0-16_win64_mkl           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    cudatoolkit:             10.2.89-hb195166_10          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    freetype:                2.12.1-h546665d_0            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    intel-openmp:            2022.1.0-h57928b3_3787       http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    jpeg:                    9e-h8ffe710_2                http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    lcms2:                   2.14-h90d422f_0              http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    lerc:                    4.0.0-h63175ca_0             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libblas:                 3.9.0-16_win64_mkl           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libcblas:                3.9.0-16_win64_mkl           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libdeflate:              1.14-hcfcfb64_0              http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    liblapack:               3.9.0-16_win64_mkl           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    liblapacke:              3.9.0-16_win64_mkl           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libpng:                  1.6.38-h19919ed_0            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libtiff:                 4.4.0-h8e97e67_4             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libwebp-base:            1.2.4-h8ffe710_0             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libxcb:                  1.13-hcd874cb_1004           http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    libzlib:                 1.2.13-hcfcfb64_4            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    m2w64-gcc-libgfortran:   5.3.0-6                      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    m2w64-gcc-libs:          5.3.0-7                      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    m2w64-gcc-libs-core:     5.3.0-7                      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    m2w64-gmp:               6.1.0-2                      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    m2w64-libwinpthread-git: 5.0.0.4634.697f757-2         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    mkl:                     2022.1.0-h6a75c08_874        http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    mkl-devel:               2022.1.0-h57928b3_875        http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    mkl-include:             2022.1.0-h6a75c08_874        http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    msys2-conda-epoch:       20160418-1                   http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2
    ninja:                   1.11.0-h2d74725_0            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    numpy:                   1.21.6-py37h2830a78_0        http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    openjpeg:                2.5.0-hc9384bd_1             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pillow:                  9.2.0-py37h42a8222_2         http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pip:                     22.3.1-pyhd8ed1ab_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pthread-stubs:           0.4-hcd874cb_1001            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    python:                  3.7.1-h9460c21_1003          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    python_abi:              3.7-2_cp37m                  http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    pytorch:                 1.6.0-py3.7_cuda102_cudnn7_0 http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
    setuptools:              65.5.1-pyhd8ed1ab_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    tbb:                     2021.7.0-h91493d7_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    tk:                      8.6.12-h8ffe710_0            http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    torchvision:             0.7.0-py37_cu102             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch
    ucrt:                    10.0.22621.0-h57928b3_0      http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    vc:                      14.3-h3d8a991_9              http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    vs2015_runtime:          14.32.31332-h1d6e394_9       http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    wheel:                   0.38.4-pyhd8ed1ab_0          http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    xorg-libxau:             1.0.9-hcd874cb_0             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    xorg-libxdmcp:           1.1.3-hcd874cb_0             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    xz:                      5.2.6-h8d14728_0             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge
    zstd:                    1.5.2-h7755175_4             http://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge

Proceed ([y]/n)? y


Downloading and Extracting Packages
msys2-conda-epoch-20 |    2 KB | ######################################################################################################## | 100%
xorg-libxdmcp-1.1.3  |   66 KB | ######################################################################################################## | 100%
python-3.7.1         | 20.2 MB | ######################################################################################################## | 100%
lerc-4.0.0           |  190 KB | ######################################################################################################## | 100%
libwebp-base-1.2.4   |  328 KB | ######################################################################################################## | 100%
m2w64-gcc-libs-5.3.0 |  518 KB | ######################################################################################################## | 100%
tbb-2021.7.0         |  174 KB | ######################################################################################################## | 100%
liblapacke-3.9.0     |  5.6 MB | ######################################################################################################## | 100%
intel-openmp-2022.1. |  3.7 MB | ######################################################################################################## | 100%
numpy-1.21.6         |  5.3 MB | ######################################################################################################## | 100%
zstd-1.5.2           |  401 KB | ######################################################################################################## | 100%
torchvision-0.7.0    |  6.4 MB | ######################################################################################################## | 100%
libpng-1.6.38        |  773 KB | ######################################################################################################## | 100%
libcblas-3.9.0       |  5.6 MB | ######################################################################################################## | 100%
blas-devel-3.9.0     |   13 KB | ######################################################################################################## | 100%
blas-2.116           |   14 KB | ######################################################################################################## | 100%
mkl-include-2022.1.0 |  760 KB | ######################################################################################################## | 100%
m2w64-libwinpthread- |   30 KB | ######################################################################################################## | 100%
jpeg-9e              |  366 KB | ######################################################################################################## | 100%
python_abi-3.7       |    4 KB | ######################################################################################################## | 100%
m2w64-gcc-libs-core- |  213 KB | ######################################################################################################## | 100%
mkl-devel-2022.1.0   |  7.1 MB | ######################################################################################################## | 100%
pytorch-1.6.0        | 705.3 MB | ####################################################################################################### | 100%
pillow-9.2.0         | 45.4 MB | ######################################################################################################## | 100%
openjpeg-2.5.0       |  256 KB | ######################################################################################################## | 100%
liblapack-3.9.0      |  5.6 MB | ######################################################################################################## | 100%
libdeflate-1.14      |   73 KB | ######################################################################################################## | 100%
freetype-2.12.1      |  506 KB | ######################################################################################################## | 100%
m2w64-gmp-6.1.0      |  689 KB | ######################################################################################################## | 100%
libxcb-1.13          |  1.3 MB | ######################################################################################################## | 100%
m2w64-gcc-libgfortra |  340 KB | ######################################################################################################## | 100%
pthread-stubs-0.4    |    6 KB | ######################################################################################################## | 100%
xorg-libxau-1.0.9    |   57 KB | ######################################################################################################## | 100%
mkl-2022.1.0         | 182.7 MB | ####################################################################################################### | 100%
lcms2-2.14           |  988 KB | ######################################################################################################## | 100%
libblas-3.9.0        |  5.6 MB | ######################################################################################################## | 100%
libtiff-4.4.0        |  1.1 MB | ######################################################################################################## | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: \ "By downloading and using the CUDA Toolkit conda packages, you accept the terms and conditions of the CUDA End User License Agreement (EULA): https://docs.nvidia.com/cuda/eula/index.html"

done

(yolov5) C:\Users\asus>d:

(yolov5) D:\>cd yolov5-v3.1

(yolov5) D:\yolov5-v3.1>pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting Cython
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/56/3a/e59db3769dee48409c759a88b62cd605324e05d396e10af0a065adc956ad/Cython-0.29.33-py2.py3-none-any.whl (987 kB)
Collecting matplotlib>=3.2.2
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/df/3f/6093a23565d0f50ce433f56223fcc34af6c912cd4331dc582ba29d9b5a17/matplotlib-3.5.3-cp37-cp37m-win_amd64.whl (7.2 MB)
     ---------------------------------------- 7.2/7.2 MB 3.3 MB/s eta 0:00:00
Requirement already satisfied: numpy>=1.18.5 in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from -r requirements.txt (line 6)) (1.21.6)
Collecting opencv-python>=4.1.2
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/80/5b/6eee3a1dc0f296904f44a13749f3b2cd29569c817aa931ead50c4d085d51/opencv_python-4.7.0.68-cp37-abi3-win_amd64.whl (38.2 MB)
Requirement already satisfied: pillow in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from -r requirements.txt (line 8)) (9.2.0)
Collecting PyYAML>=5.3
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/d1/c0/4fe04181b0210ee2647cfbb89ecd10a36eef89f10d8aca6a192c201bbe58/PyYAML-6.0-cp37-cp37m-win_amd64.whl (153 kB)
     ---------------------------------------- 153.2/153.2 kB 4.6 MB/s eta 0:00:00
Collecting scipy>=1.4.1
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/40/69/4af412d078cef2298f7d90546fa0e03e65a032558bd85319239c72ae0c3c/scipy-1.7.3-cp37-cp37m-win_amd64.whl (34.1 MB)
     ---------------------------------------- 34.1/34.1 MB 3.8 MB/s eta 0:00:00
Collecting tensorboard>=2.2
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/6f/77/e624b4916531721e674aa105151ffa5223fb224d3ca4bd5c10574664f944/tensorboard-2.11.2-py3-none-any.whl (6.0 MB)
Requirement already satisfied: torch>=1.6.0 in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from -r requirements.txt (line 12)) (1.6.0)
Requirement already satisfied: torchvision>=0.7.0 in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from -r requirements.txt (line 13)) (0.7.0)
Collecting tqdm>=4.41.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/47/bb/849011636c4da2e44f1253cd927cfb20ada4374d8b3a4e425416e84900cc/tqdm-4.64.1-py2.py3-none-any.whl (78 kB)
Collecting pyparsing>=2.2.1
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/6c/10/a7d0fa5baea8fe7b50f448ab742f26f52b80bfca85ac2be9d35cdd9a3246/pyparsing-3.0.9-py3-none-any.whl (98 kB)
Collecting fonttools>=4.22.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/e3/d9/e9bae85e84737e76ebbcbea13607236da0c0699baed0ae4f1151b728a608/fonttools-4.38.0-py3-none-any.whl (965 kB)
Collecting cycler>=0.10
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/5c/f9/695d6bedebd747e5eb0fe8fad57b72fdf25411273a39791cde838d5a8f51/cycler-0.11.0-py3-none-any.whl (6.4 kB)
Collecting kiwisolver>=1.0.1
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/03/93/11790e8e81b89acd3a1c8a6b501f8a05b1c41beee0990582699cdda29557/kiwisolver-1.4.4-cp37-cp37m-win_amd64.whl (54 kB)
     ---------------------------------------- 54.9/54.9 kB 178.6 kB/s eta 0:00:00
Collecting packaging>=20.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/ed/35/a31aed2993e398f6b09a790a181a7927eb14610ee8bbf02dc14d31677f1c/packaging-23.0-py3-none-any.whl (42 kB)
Collecting python-dateutil>=2.7
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/36/7a/87837f39d0296e723bb9b62bbb257d0355c7f6128853c78955f57342a56d/python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Requirement already satisfied: wheel>=0.26 in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from tensorboard>=2.2->-r requirements.txt (line 11)) (0.38.4)
Collecting requests<3,>=2.21.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/d2/f4/274d1dbe96b41cf4e0efb70cbced278ffd61b5c7bb70338b62af94ccb25b/requests-2.28.2-py3-none-any.whl (62 kB)
Collecting markdown>=2.6.8
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/86/be/ad281f7a3686b38dd8a307fa33210cdf2130404dfef668a37a4166d737ca/Markdown-3.4.1-py3-none-any.whl (93 kB)
Collecting werkzeug>=1.0.1
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/c8/27/be6ddbcf60115305205de79c29004a0c6bc53cec814f733467b1bb89386d/Werkzeug-2.2.2-py3-none-any.whl (232 kB)
Collecting tensorboard-data-server<0.7.0,>=0.6.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/74/69/5747a957f95e2e1d252ca41476ae40ce79d70d38151d2e494feb7722860c/tensorboard_data_server-0.6.1-py3-none-any.whl (2.4 kB)
Collecting google-auth<3,>=1.6.3
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/fb/55/c6e13b79a16688069b214cf726ebe49725c0b936367f045464b1122de083/google_auth-2.16.0-py2.py3-none-any.whl (177 kB)
Requirement already satisfied: setuptools>=41.0.0 in d:\softwave\anaconda3\envs\yolov5\lib\site-packages (from tensorboard>=2.2->-r requirements.txt (line 11)) (65.5.1)
Collecting google-auth-oauthlib<0.5,>=0.4.1
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/b1/0e/0636cc1448a7abc444fb1b3a63655e294e0d2d49092dc3de05241be6d43c/google_auth_oauthlib-0.4.6-py2.py3-none-any.whl (18 kB)
Collecting tensorboard-plugin-wit>=1.6.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/e0/68/e8ecfac5dd594b676c23a7f07ea34c197d7d69b3313afdf8ac1b0a9905a2/tensorboard_plugin_wit-1.8.1-py3-none-any.whl (781 kB)
Collecting absl-py>=0.4
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/dd/87/de5c32fa1b1c6c3305d576e299801d8655c175ca9557019906247b994331/absl_py-1.4.0-py3-none-any.whl (126 kB)
Collecting protobuf<4,>=3.9.2
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/98/07/4c75a689fa173c12b92c9a64a82efad44797b9b2b784c8562f36ab28b551/protobuf-3.20.3-cp37-cp37m-win_amd64.whl (905 kB)
     ---------------------------------------- 905.1/905.1 kB 511.4 kB/s eta 0:00:00
Collecting grpcio>=1.24.3
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/f0/59/84b9868896468cccbb644f9a4e3a25226f70e4e6b7e2dab503c81dfb8c59/grpcio-1.51.1-cp37-cp37m-win_amd64.whl (3.7 MB)
     ---------------------------------------- 3.7/3.7 MB 1.4 MB/s eta 0:00:00
Collecting future
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/8f/2e/cf6accf7415237d6faeeebdc7832023c90e0282aa16fd3263db0eb4715ec/future-0.18.3.tar.gz (840 kB)
  Preparing metadata (setup.py) ... done
Collecting colorama
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl (25 kB)
Collecting cachetools<6.0,>=2.0.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/db/14/2b48a834d349eee94677e8702ea2ef98b7c674b090153ea8d3f6a788584e/cachetools-5.3.0-py3-none-any.whl (9.3 kB)
Collecting six>=1.9.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/d9/5a/e7c31adbe875f2abbb91bd84cf2dc52d792b5a01506781dbcf25c91daf11/six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting pyasn1-modules>=0.2.1
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/95/de/214830a981892a3e286c3794f41ae67a4495df1108c3da8a9f62159b9a9d/pyasn1_modules-0.2.8-py2.py3-none-any.whl (155 kB)
Collecting rsa<5,>=3.1.4
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/49/97/fa78e3d2f65c02c8e1268b9aba606569fe97f6c8f7c2d74394553347c145/rsa-4.9-py3-none-any.whl (34 kB)
Collecting requests-oauthlib>=0.7.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/6f/bb/5deac77a9af870143c684ab46a7934038a53eb4aa975bc0687ed6ca2c610/requests_oauthlib-1.3.1-py2.py3-none-any.whl (23 kB)
Collecting typing-extensions
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/0b/8e/f1a0a5a76cfef77e1eb6004cb49e5f8d72634da638420b9ea492ce8305e8/typing_extensions-4.4.0-py3-none-any.whl (26 kB)
Collecting importlib-metadata>=4.4
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/26/a7/9da7d5b23fc98ab3d424ac2c65613d63c1f401efb84ad50f2fa27b2caab4/importlib_metadata-6.0.0-py3-none-any.whl (21 kB)
Collecting idna<4,>=2.5
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/fc/34/3030de6f1370931b9dbb4dad48f6ab1015ab1d32447850b9fc94e60097be/idna-3.4-py3-none-any.whl (61 kB)
Collecting urllib3<1.27,>=1.21.1
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/fe/ca/466766e20b767ddb9b951202542310cba37ea5f2d792dae7589f1741af58/urllib3-1.26.14-py2.py3-none-any.whl (140 kB)
Collecting certifi>=2017.4.17
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/71/4c/3db2b8021bd6f2f0ceb0e088d6b2d49147671f25832fb17970e9b583d742/certifi-2022.12.7-py3-none-any.whl (155 kB)
     ---------------------------------------- 155.3/155.3 kB 132.6 kB/s eta 0:00:00
Collecting charset-normalizer<4,>=2
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/fc/64/443267b7824283b3e0e33cee4240c079939a970c2c9a5a3164fc988d690b/charset_normalizer-3.0.1-cp37-cp37m-win_amd64.whl (94 kB)
     ---------------------------------------- 94.0/94.0 kB 255.4 kB/s eta 0:00:00
Collecting MarkupSafe>=2.1.1
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/39/8d/5c5ce72deb8567ab48a18fbd99dc0af3dd651b6691b8570947e54a28e0f3/MarkupSafe-2.1.2-cp37-cp37m-win_amd64.whl (16 kB)
Collecting zipp>=0.5
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/01/3c/9d84fc1dbac1c5103bf3cd994e4895642001f75eb2139bddbc02aa1906e5/zipp-3.12.0-py3-none-any.whl (6.6 kB)
Collecting pyasn1<0.5.0,>=0.4.6
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/62/1e/a94a8d635fa3ce4cfc7f506003548d0a2447ae76fd5ca53932970fe3053f/pyasn1-0.4.8-py2.py3-none-any.whl (77 kB)
Collecting oauthlib>=3.0.0
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/7e/80/cab10959dc1faead58dc8384a781dfbf93cb4d33d50988f7a69f1b7c9bbe/oauthlib-3.2.2-py3-none-any.whl (151 kB)
Building wheels for collected packages: future
  Building wheel for future (setup.py) ... done
  Created wheel for future: filename=future-0.18.3-py3-none-any.whl size=492055 sha256=d9728aa33a2dbdf410b14c5817726ad95cca5497184b62b4a11ba0eedc44eaf6
  Stored in directory: c:\users\asus\appdata\local\pip\cache\wheels\c8\ff\15\d835921035fec8b42e31c108329e4b200365ac8573bc5f56d8
Successfully built future
Installing collected packages: tensorboard-plugin-wit, pyasn1, charset-normalizer, zipp, urllib3, typing-extensions, tensorboard-data-server, six, scipy, rsa, PyYAML, pyparsing, pyasn1-modules, protobuf, packaging, opencv-python, oauthlib, MarkupSafe, idna, grpcio, future, fonttools, Cython, cycler, colorama, certifi, cachetools, absl-py, werkzeug, tqdm, requests, python-dateutil, kiwisolver, importlib-metadata, google-auth, requests-oauthlib, matplotlib, markdown, google-auth-oauthlib, tensorboard
Successfully installed Cython-0.29.33 MarkupSafe-2.1.2 PyYAML-6.0 absl-py-1.4.0 cachetools-5.3.0 certifi-2022.12.7 charset-normalizer-3.0.1 colorama-0.4.6 cycler-0.11.0 fonttools-4.38.0 future-0.18.3 google-auth-2.16.0 google-auth-oauthlib-0.4.6 grpcio-1.51.1 idna-3.4 importlib-metadata-6.0.0 kiwisolver-1.4.4 markdown-3.4.1 matplotlib-3.5.3 oauthlib-3.2.2 opencv-python-4.7.0.68 packaging-23.0 protobuf-3.20.3 pyasn1-0.4.8 pyasn1-modules-0.2.8 pyparsing-3.0.9 python-dateutil-2.8.2 requests-2.28.2 requests-oauthlib-1.3.1 rsa-4.9 scipy-1.7.3 six-1.16.0 tensorboard-2.11.2 tensorboard-data-server-0.6.1 tensorboard-plugin-wit-1.8.1 tqdm-4.64.1 typing-extensions-4.4.0 urllib3-1.26.14 werkzeug-2.2.2 zipp-3.12.0

(yolov5) D:\yolov5-v3.1>python detect.py --source ./inference/images/ --weights weights/yolov5s.pt --conf 0.4
Namespace(agnostic_nms=False, augment=False, classes=None, conf_thres=0.4, device='1', img_size=640, iou_thres=0.45, save_conf=False, save_dir='inference/output', save_txt=False, source='./inference/images/', update=False, view_img=False, weights=['weights/yolov5s.pt'])
Traceback (most recent call last):
  File "detect.py", line 172, in <module>
    detect()
  File "detect.py", line 27, in detect
    device = select_device(opt.device)
  File "D:\yolov5-v3.1\utils\torch_utils.py", line 33, in select_device
    assert torch.cuda.is_available(), 'CUDA unavailable, invalid device %s requested' % device  # check availablity
AssertionError: CUDA unavailable, invalid device 1 requested

(yolov5) D:\yolov5-v3.1>python detect.py --source ./inference/images/ --weights weights/yolov5s.pt --conf 0.4
Namespace(agnostic_nms=False, augment=False, classes=None, conf_thres=0.4, device='', img_size=640, iou_thres=0.45, save_conf=False, save_dir='inference/output', save_txt=False, source='./inference/images/', update=False, view_img=False, weights=['weights/yolov5s.pt'])
Using CUDA device0 _CudaDeviceProperties(name='NVIDIA GeForce GTX 1050', total_memory=4095MB)

Fusing layers...
Model Summary: 140 layers, 7.45958e+06 parameters, 0 gradients
image 1/2 D:\yolov5-v3.1\inference\images\bus.jpg: 640x480 4 persons, 1 buss, 1 skateboards, Done. (0.032s)
image 2/2 D:\yolov5-v3.1\inference\images\zidane.jpg: 384x640 2 persons, 1 ties, Done. (0.026s)
Results saved to inference\output
Done. (2.122s)

你可能感兴趣的:(YOLO,python)