中国安全科学学报 ›› 2025, Vol. 35 ›› Issue (1): 75-83.doi: 10.16265/j.cnki.issn1003-3033.2025.01.0127

• 安全工程技术 • 上一篇    下一篇

基于YOLOv5s的轻量化森林火灾探测算法

刘惠临1(), 方琼1, 江宇1, 魏华章2,**(), 王涛3, 张树川4   

  1. 1 安徽理工大学 计算机科学与工程学院,安徽 淮南 232001
    2 淮南职业技术学院 智能与电气工程学院,安徽 淮南 232001
    3 滁州学院 无人应急装备与灾害过程数字化重建安徽省联合共建学科重点实验室,安徽 滁州 239099
    4 安徽理工大学 安全科学与工程学院,安徽 淮南 232001
  • 收稿日期:2024-08-20 修回日期:2024-10-25 出版日期:2025-01-28
  • 通信作者:
    **魏华章(1996—),男,安徽淮南人,硕士研究生,研究方向为计算机视觉。E-mail:
  • 作者简介:

    刘惠临 (1979—),男,安徽合肥人,博士,高级实验师,主要从事计算机视觉、图像处理、多模态数据融合等方面的研究。E-mail:

    王涛 副教授

    张树川 副教授

  • 基金资助:
    安徽省重点研究与开发计划项目(2023g07020007); 安徽理工大学研究生创新基金资助(2024cx2111)

A lightweight forest fire detection algorithm based on YOLOv5s

LIU Huilin1(), FANG Qiong1, JIANG Yu1, WEI Huazhang2,**(), WANG Tao3, ZHANG Shuchuan4   

  1. 1 School of Computer Science and Engineering, Anhui University of Science and Technology, Huainan Anhui 232001, China
    2 School of Intelligence and Electrical Engineering, Huainan Vocational Technical College, Huainan Anhui 232001, China
    3 Key Laboratory of Unmanned Emergency Equipment and Digital Reconstruction of Disaster Processes in Anhui Province, Chuzhou College, Chuzhou Anhui 239099, China
    4 School of Safety Science and Engineering, Anhui University of Science and Technology, Huainan Anhui 232001, China
  • Received:2024-08-20 Revised:2024-10-25 Published:2025-01-28

摘要:

为解决当前基于深度学习的森林火灾探测算法存在结构复杂、规模庞大,且难以兼顾检测精度和效率的问题,提出一种基于YOLOv5s的轻量化森林火灾探测算法。首先,采用优化的背景差分技术消除背景图像中类火物体的干扰,减少分析图像所需的时间;其次,设计分组混洗策略优化常规卷积,并在特征提取的C3模块中融入高效通道注意力(ECA)机制和深度可分离卷积,增强图像特征提取与融合能力的同时有效降低模型的参数量;然后,采用动态非单调聚焦机制优化Wise-交并比(WIOU)损失函数,减少低质量样本产生的有害梯度;最后,在构建的森林火灾数据集上将所提算法与其他算法做充分的试验对比。结果表明: 所提算法在各类场景均展现出良好的泛化性,对火焰目标的检测精度达到86.1%,较标准YOLOv5s检测精度提升2.7%,检测速度提升11.4%,有效降低了火灾误报率,增强了模型的检测性能。

关键词: YOLOv5s, 轻量化, 森林火灾探测, 深度可分离卷积, 注意力, Wise-交并比(WIOU)

Abstract:

In order to solve the problems of complex structure, large scale and difficulty in balancing detection accuracy and efficiency of the current forest fire detection algorithm based on deep learning, a lightweight forest fire detection algorithm based on YOLOv5s was proposed. Firstly, an optimized background difference technique was used to eliminate the interference of fire-like objects in the background image, thus reducing the time required for image analysis. Secondly, a group blending strategy was designed to optimize the conventional convolution, and an efficient channel attention (ECA) mechanism and depthwise separable convolution were incorporated into the C3 module of feature extraction, which enhanced the ability of image feature extraction and fusion and at the same time effectively reduces the number of model parameters. Then, a dynamic non-monotonic focusing mechanism was used to optimize the WIOU loss function, reducing the harmful gradients generated by low-quality samples. Finally, sufficient experimental comparisons between the proposed algorithm and other algorithms on the constructed forest fire dataset. The results show that the proposed algorithm shows good generalization in various scenarios, and the detection accuracy of the flame target can reach 86.1%, which is 2.7% higher than that of the standard YOLOv5s, and the detection speed is increased by 11.4%, which effectively reduces the fire false alarm rate and enhances the detection performance of the model.

Key words: YOLOv5s, lightweighting, forest fire detection, depthwise separable convolution, attention, wise intersection over union(WIOU)

中图分类号: