作者投稿和查稿 主编审稿 专家审稿 编委审稿 远程编辑

计算机工程 ›› 2025, Vol. 51 ›› Issue (3): 342-351. doi: 10.19678/j.issn.1000-3428.0068826

• 开发研究与工程应用 • 上一篇    下一篇

面向弱光交通场景的YOLOv7道路标志检测算法优化

孙亭, 杨洁*(), 李家璇, 王耀宗   

  1. 西南林业大学机械与交通学院, 云南 昆明 650224
  • 收稿日期:2023-11-13 出版日期:2025-03-15 发布日期:2024-05-06
  • 通讯作者: 杨洁
  • 基金资助:
    云南省教育厅重点基金项目(2023J0711); 农业推广理论与实践案例库的建设(503210305); 农林研究生教育中产教融合和科教融合的探索(503210401)

Optimization of YOLOv7 Road Sign Detection Algorithm for Low-Light Traffic Scenes

SUN Ting, YANG Jie*(), LI Jiaxuan, WANG Yaozong   

  1. School of Mechanics and Transportation, Southwest Forestry University, Kunming 650224, Yunnan, China
  • Received:2023-11-13 Online:2025-03-15 Published:2024-05-06
  • Contact: YANG Jie

摘要:

针对交通标志检测算法在黑夜及弱光条件下存在检测精度不高、漏检等问题, 提出一种改进YOLOv7的交通标志检测算法。构建用于弱光增强的高斯图像滤波器, 抑制其背景噪声, 对图像实现像素增强。在YOLOv7网络中, 构建新的AC-ResBlock残差模块来替代ELAN中的3×3卷积模块, 以提高交通标志的特征提取能力和网络推理速度。引入SIoU损失函数提高模型的准确度, 加速训练过程收敛。采用K-means++算法代替K-means重新标定锚框的尺寸, 在扩展后的中国交通标志检测数据集CCTSDB上的实验结果表明, 改进后的YOLOv7算法准确率达到95.7%, 召回率达到94.8%, 平均精度达到96.3%, 优于YOLOv8、YOLOv5及其他主流检测算法, 可以实现黑夜及弱光条件下的交通标志检测。对于复杂环境下的交通标志检测具有一定的研究意义。

关键词: 交通标志检测, YOLOv7算法, 黑夜图像增强, 自注意力机制, 损失函数

Abstract:

This paper proposes an improved YOLOv7 traffic sign detection algorithm to address the issues of low detection accuracy and missed detections under dark and low-light conditions by existing algorithms. A Gaussian image filter for low-light enhancement is constructed to suppress background noise and enhance the image pixels. In the YOLOv7 network, a new AC-ResBlock residual module has replaced the 3×3 convolution module in Efficient Layer Aggregation Network(ELAN), thereby enhancing the feature extraction capability and network inference speed for traffic signs. The Scylla-Intersection over Union(SIoU) loss function is introduced to improve model accuracy and accelerate training convergence. The K-means++ algorithm is used instead of K-means to recalibrate the anchor box dimensions. Experiments on the expanded Chinese Traffic Sign Detection Benchmark(CCTSDB) have shown that the improved YOLOv7 algorithm achieves a accuracy of 95.7%, recall rate of 94.8%, and average accuracy of 96.3%. This performance surpasses those of YOLOv8, YOLOv5, and other mainstream detection algorithms, enabling the detection of traffic signs under night and low-light conditions, which is a significant advancement for traffic sign detection in complex environments.

Key words: traffic sign detection, YOLOv7 algorithm, night image enhancement, self-attention mechanism, loss function