欢迎访问《图学学报》 分享到:

图学学报 ›› 2025, Vol. 46 ›› Issue (2): 249-258.DOI: 10.11996/JG.j.2095-302X.2025020249

• 图像处理与计算机视觉 • 上一篇    下一篇

面向柴油车辆排放黑烟的改进型YOLOv8检测算法研究

张立立1,3(), 杨康1, 张珂1, 魏薇1, 李晶1, 谭洪鑫2(), 张翔宇3   

  1. 1.北京石油化工学院信息工程学院,北京 102617
    2.中国人民解放军93184部队,北京 100076
    3.星禾环保科技有限公司,河南 郑州 450001
  • 收稿日期:2024-07-22 接受日期:2024-11-25 出版日期:2025-04-30 发布日期:2025-04-24
  • 通讯作者:谭洪鑫(1992-),女,工程师,博士。主要研究方向为图像识别与目标检测。E-mail:18809462629@163.com
  • 第一作者:张立立(1988-),男,副教授,博士。主要研究方向为智能交通。E-mail:zhanglili@bipt.edu.cn
  • 基金资助:
    宁夏自然科学基金(2023AAC03889);北京市数字教育研究课题(BDEC2022619048);北京市教育委员会科研计划项目(KM202410017006)

Research on improved YOLOv8 detection algorithm for diesel vehicle emission of black smoke

ZHANG Lili1,3(), YANG Kang1, ZHANG Ke1, WEI Wei1, LI Jing1, TAN Hongxin2(), ZHANG Xiangyu3   

  1. 1. School of Information Engineering, Beijing Institute of Petrochemical Technology, Beijing 102617 China
    2. PLA, No. 93184 Troop, Beijing 100076, China
    3. Xinghe Environmental Protection Technology Co., LTD., Zhengzhou Henan 450001, China
  • Received:2024-07-22 Accepted:2024-11-25 Published:2025-04-30 Online:2025-04-24
  • First author:ZHANG Lili (1988-), associate professor, Ph.D. His main research interest covers intelligent transportation. E-mail:zhanglili@bipt.edu.cn
  • Supported by:
    Ningxia Natural Science Foundation(2023AAC03889);Beijing Digital Education Research Project(BDEC2022619048);Research and Development Program of Beijing Municipal Education Commission(KM202410017006)

摘要:

柴油车辆排放黑烟是道路交通环保执法的重点和难点。由于受复杂环境条件的影响,针对目前黑烟检测存在精度和速度方面的不足,提出一种基于改进YOLOv8的轻量级柴油车辆排放黑烟的检测模型。首先,在YOLOv8主干网络的基础上,设计一种轻量化特征提取模块C2f-FasterRep提高模型的特征提取能力,同时C2f-FasterRep模块引入上下文锚框注意力机制模块来捕捉长距离的上下文信息,利用全局平均池化和条形卷积增强特征图中心区域的特征,从而提高检测精度;其次,在颈部部分提出一个新的网络结构用于融合主干网络提取的特征,并使用通道注意力模块和维度匹配机制对不同尺度的特征进行融合,增强了模型的多尺度特征融合能力;最后,使用Transformer解码器结构优化YOLOv8模型的检测头,同时,采用交并比感知的查询机制,有助于解码器查询的优化,提高了模型的分类和定位的性能。为保证实验的真实性和有效性,利用部署在河南许昌某道路断面的检测设备采集数据并进行测试验证。实验结果表明,该方法的mAp为95.4%,精确率为94.5%,召回率为97.5%,与现有的黑烟检测方法相比,具有更高的检测精度和更快的检测速度。消融实验结果表明该轻量化特征提取模块、特征融合模块和检测头有利于提高模型检测精度。

关键词: 目标检测, 黑烟检测, YOLOv8, 轻量级模型, 注意力机制

Abstract:

The emission of black smoke from diesel vehicles is a critical and challenging issue in road traffic environmental protection enforcement. Due to the influence of complex environmental conditions, to address the limitations of existing black smoke detection methods in terms of accuracy and speed, a lightweight detection model of black smoke emission from diesel vehicles based on improved YOLOv8 was proposed. Firstly, based on the YOLOv8 backbone network, a lightweight feature extraction module C2f-FasterRep was designed to improve the feature extraction capability of the model, while the C2f-FasterRep module integrated a context-anchored attention mechanism module to capture long-range contextual information. The global average pooling and bar convolution were employed to enhance the features in the central region of the feature map, thereby improving the detection accuracy. Secondly, a new network structure was proposed in the neck part to fuse the features extracted from the backbone network. The channel attention module and dimensional matching mechanism were employed to fuse features of different scales, enhancing the model’s multi-scale feature fusion capability. Lastly, the detection head of the YOLOv8 model was optimized using a Transformer decoder structure. An intersection-parallel-ratio aware query mechanism was incorporated to optimize the decoder query, improving the model’s performance for classification and localization. In order to ensure the authenticity and effectiveness of the experiment, data were collected and tested and verified using the detection equipment deployed on a road section in Xuchang, Henan Province. The experimental results demonstrated that the mAp of the proposed method was achieved at 95.4%, the precision at 94.5%, and the recall rate at 97.5%. Compared with existing black smoke detection methods, the proposed approach exhibited higher detection accuracy and faster detection speed. The results of ablation experiments confirmed that the proposed lightweight feature extraction module, feature fusion module and detection head contributed to improving the accuracy of model detection.

Key words: object detection, black smoke detection, YOLOv8, lightweight model, attention mechanism

中图分类号: