doi: 10.17706/jsw.21.1.1-13
Fire Detection System Based on YOLOv5 with Attention Mechanism
- 1 School of Computer Science and Software Engineering, Southwest Petroleum University, Chengdu, Sichuan Province, 610500, China
- 2 School of Sciences, Southwest Petroleum University, Chengdu, Sichuan Province, 610500, China
- Manuscript received September 3, 2025
- accepted November 25, 2025
- published January 29, 2026
Abstract
The increasing frequency of fire incidents in dense urban areas has highlighted the limitations of traditional sensor-based detection systems, such as delayed response and high false alarm rates. To address these challenges, this study proposes an enhanced fire detection algorithm based on You Only Look Once Version 5 (YOLOv5), incorporating a Squeeze-and-Excitation (SE) attention mechanism. The SE module was selected for its effective channel-wise feature recalibration capability and its minimal computational overhead, making it ideal for deployment on edge devices in real-time scenarios. Experimental results demonstrate that the proposed method achieves a precision of 0.87, recall of 0.86, and mAP@0.5 of 0.91, with a mAP@0.5:0.95 of 0.42, indicating robust performance under stricter evaluation criteria. The model maintains high computational efficiency, exhibiting strong potential for practical, real-time fire detection applications.
Keywords
- YOLOv5
- fire detection
- Squeeze-and-Exci
How to Cite
Ruoxi Huang, Xiasheng Lu, and Yiming Chen, "Fire Detection System Based on YOLOv5 with Attention Mechanism," Journal of Software, vol. 21, no. 1, pp. 1-13, 2026. https://doi.org/ 10.17706/jsw.21.1.1-13
Copyright & License
Copyright © 2026 by the authors. This is an open access article distributed under the Creative Commons Attribution License which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited (CC BY 4.0).
