雨滴科技技术论坛

 找回密码
 立即注册
查看: 551|回复: 1

yolov5的速度让人印象深刻

[复制链接]

513

主题

1974

帖子

8158

积分

论坛元老

Rank: 8Rank: 8

积分
8158
扫一扫,手机访问本帖
发表于 2021-2-18 00:22:48 | 显示全部楼层 |阅读模式
import torch
from IPython.display import Image, clear_output  # to display images

clear_output()
print('Setup complete. Using torch %s %s' % (torch.__version__, torch.cuda.get_device_properties(0) if torch.cuda.is_available() else 'CPU'))
!pwd
!python detect.py --weights yolov5s.pt --img 640  --conf 0.25 --source data/images/



在jupyter lab里面测试了一下, yolov5s.pt, yolov5m.pt, yolov5l.pt, yolov5x.pt
这几个根据名字猜测是small, large, 分辨率大小
最大的权重5x那个才100多MB,不过半天没下载成功。
我用5s测试摄像头,速度让人印象深刻,大概0.007s一帧,480x640分辨率。

python detect.py --weights yolov5s.pt --img 640  --conf 0.25 --source 0

回复

使用道具 举报

513

主题

1974

帖子

8158

积分

论坛元老

Rank: 8Rank: 8

积分
8158
 楼主| 发表于 2021-2-18 00:25:32 | 显示全部楼层
0: 480x640 1 person, 1 banana, Done. (0.007s)
0: 480x640 1 person, 1 banana, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, 1 chair, Done. (0.008s)
0: 480x640 1 person, 1 chair, Done. (0.007s)
0: 480x640 1 person, Done. (0.008s)





0: 576x736 2 persons, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 toilet, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.010s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.010s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 3 persons, 1 bottle, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
0: 576x736 2 persons, 1 handbag, 1 toilet, Done. (0.009s)
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

在线客服
在线咨询
咨询热线
0755-26787502-8006/8016
扫一扫二维码
直接访问本站

QQ|Archiver|手机版|小黑屋|雨滴科技  

GMT+8, 2021-10-22 05:04 , Processed in 0.053261 second(s), 10 queries , Gzip On, Memcache On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表