
0 引言
目标检测算法是在图像中找到感兴趣的目标并对其进行分类和定位的一种算法,定位
基于改进
YOLOv5
的行人车辆检测与识别
算法研究
**
摘要:作为目前最先进的一阶段算法,YOLOv5
在通用的目标检测数据集上表现不错,然而
在实际车辆行人检测数据集中,由于远距离下的目标像素少、相似性高等问题,YOLOv5
对
小目标的检测还存在一些问题。为了解决这一问题,本文对
YOLOv5
算法进行了改进,提
高了其对小目标的检测效果。本文的主要工作如下:
(1)针对数据集中样本不均衡的问题,采取了
Stitcher
和尺度匹配等数据增强的方式,丰富了
样本的多样性,扩充了目标训练集,增加了小目标在训练集中所占的比例。
(2)针对网络机制对小目标不友好的问题,采取了新增一个用于微小目标的检测头和优化损
失函数的方式,从网络结构上对算法做出改进,使得小目标所起的影响不被忽视。
实验证明,改进后的模型在满足实时性要求的同时,在小目标检测上表现由于改进前的模型,
提高了对于远距离下的车辆行人的检测效果。
关键词:计算机视觉;YOLOv5;目标检测;车辆行人检测;小目标检测
中图分类号:TP391.4
Research on pedestrian and vehicle detection and
recognition algorithm based on improved yolov5
MENG Zidi,
LIU Liang
(School of Computer Science, Beijing University of Posts and Telecommunications, Beijing
100876)
Abstract:
As the most
advanced one-stage algorithm at present, yolov5 performs well in the general
object detection data set. However, in the actual pedestrian and vehicle detection data set, there are still
some problems in the detection of small targets in yolov5 due to the problems of few target pixels and
high similarity at a long distance. In order to solve this problem, this paper improves the yolov5 algorithm
and improves its detection effect on tiny objects. The main work of this paper is as follows:
(1) Aiming at the problem of unbalanced samples in the data set, data enhancement methods such as
stitcher and scale match are adopted to enrich the diversity of samples, expand the target training set and
increase the proportion of tiny objects in the training set.
(2) Aiming at the problem that the network mechanism is not friendly to tiny objects, a new detection
head for small targets is added and the loss function is optimized. The algorithm is improved from the
network structure, so that the influence of tiny objects can
not be ignored.
Experiments show that the improved model not only meets the real-time requirements, but also performs
in tiny object detection. Due to the improved model, the detection effect of vehicles and pedestrians at a
long distance is improved.
Key
words:
Computer
Vision;
YOLOv5;
object detection;
Pedestrian and vehicle detection;tiny object
detection
-
1
-