Skip to main content
Log in

Real-time detection algorithm of helmet and reflective vest based on improved YOLOv5

  • Original Research Paper
  • Published:
Journal of Real-Time Image Processing Aims and scope Submit manuscript

Abstract

To address the current problems of helmet and reflective vest detection algorithms, such as long inference times, high hardware requirements, and difficulty detecting small objects, an improved real-time detection algorithm based on YOLOv5 is proposed. First, the Mosaic-9 data enhancement method is adopted to expand the number of image splicings from four to nine, enriching the small-scale sample dataset. Minimum rectangular area cropping is used instead of the original random cropping to improve the training efficiency. Then, the EIOU (Efficient Intersection Over Union) loss is used as the loss function, and the focal loss is introduced to focus on the high-quality anchor box, achieving the purpose of accelerating the convergence speed and improving regression accuracy. Next, the CBAM-CA (Convolutional Block Attention Module—Coordinate Attention) hybrid attention mechanism is added to the network model. The purpose of the model is to focus on the small object’s spatial and channel feature information to improve the small object’s detection performance. Finally, a new scale object detection layer is added to learn the multilevel features of the dense object. The experimental results show that the improved model’s mAP (mean average precision) is 94.9%, an improvement of 7.0% over the original model. The size of the improved model is 4.49 MB, and the mean FPS (Frames Per Second) is 62. This algorithm guarantees a small model size while significantly increasing mAP, which is suitable for deployment on low computing power platforms.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15
Fig. 16

Similar content being viewed by others

Availability of data and material

The datasets generated during and/or analyzed during the current study are available from the corresponding author on reasonable request. Requests for material should be made to the corresponding authors.

References

  1. Park, M.-W., Elsafty, N., Zhu, Z.: Hardhat-wearing detection for enhancing on-site safety of construction workers. J. Constr. Eng. Manage. 141(9), 04015024 (2015)

    Article  Google Scholar 

  2. Yan, G.B., Sun, Q., Huang, J.Y., et al.: Helmet detection based on deep learning and random forest on UAV for power construction safety. J. Adv. Comput. Intell. Intell. Inf. 25(1), 40–49 (2021)

    Article  Google Scholar 

  3. Luo, Q., Hua, J., Huang, L., et al.: Visualization analysis of domestic and overseas intelligent construction assisted by mapping knowledge domains. J. Build. Struct. 42(6), 1–14 (2021)

    Google Scholar 

  4. Liu, H., Zhang, F., Chen, Z., et al.: Applied research status and prospects of artificial intelligence in civil engineering field. J. Civil Environ. Eng. 66, 1–20 (2023). http://kns.cnki.net/kcms/detail/50.1218.TU.20220312.1605.002.html

  5. Ramachandram, D., Taylor, G.W.: Deep multimodal learning: a survey on recent advances and trends. IEEE Signal Process. Mag. 34(6), 96–108 (2017)

    Article  Google Scholar 

  6. Subramanyam, V., Kumar, J., Singh, S.N.: Temporal synchronization framework of machine-vision cameras for high-speed steel surface inspection systems. J. Real-Time Image Proc. 19(2), 445–461 (2022)

    Article  Google Scholar 

  7. Le Cun, Y., Bengio, Y., Hinton, G.: Deep learning. Nature 521(7553), 436–444 (2015)

    Article  Google Scholar 

  8. Wetzstein, G., Ozcan, A., Gigan, S., et al.: Inference in artificial intelligence with deep optics and photonics. Nature 588(7836), 39–47 (2020)

    Article  Google Scholar 

  9. Zhou, Y., Zhang, L., Liu, T., et al.: Structural system identification based on computer vision. Chin. Civil Eng. J. 51(11), 17–23 (2018)

    Google Scholar 

  10. Zhu, X., Xiong, Y., Dai, J., et al.: Deep feature flow for video recognition. In: IEEE Conference on Computer Vision and Pattern Recognition. IEEE, pp. 4141–4150 (2017)

  11. Yang, S.D., Chen, Z.H., Ma, X.M., et al.: Real-time high-precision pedestrian tracking: a detection-tracking-correction strategy based on improved SSD and Cascade R-CNN. J. Real-Time Image Proc. 19(2), 287–302 (2021)

    Article  Google Scholar 

  12. Ren, S., He, K., Girshick, R., et al.: Faster R-CNN: towards real time object detection with region proposal networks. IEEE Trans. Pattern Anal. Mach. Intell. 39(6), 1137–1149 (2017)

    Article  Google Scholar 

  13. Pan, H.G., Shi, Y.H., Lei, X.Y., et al.: Fast identification model for coal and gangue based on the improved tiny YOLO v3. J. Real-Time Image Proc. 19(3), 687–701 (2022)

    Article  Google Scholar 

  14. Jain, V., Jadhav, N., Verhelst, M.: Enabling real-time object detection on low cost FPGAs. J. Real-Time Image Proc. 19(1), 217–229 (2021)

    Article  Google Scholar 

  15. Lin, J., Dang, W.C., Pan, L.H., et al.: Safety helmet detection based on YOLO. Comp. Syst. Appl. 28(9), 174–179 (2019)

    Google Scholar 

  16. Redmon, J., Divvala, S., Girshick, R., et al.: You only look once: unified, real-time object detection. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Seattle, WA, pp. 779–788 (2016)

  17. Redmon, J., Farhadi, A.: YOLO9000: better, faster, stronger. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Honolulu, HI, pp. 6517–6525 (2017)

  18. Fang, M., Sun, T.T., Shao, Z.: Fast helmet-wearing-condition detection based on improved YOLOv2. Opt. Precis. Eng. 27(5), 1196–1205 (2019)

    Article  Google Scholar 

  19. Yang, L.Q., Cai, L.Q., Gu, S.: Detection on wearing behavior of safety helmet based on machine learning method. J. Saf. Sci. Technol. 15(10), 152–157 (2019)

    Google Scholar 

  20. Shi, H., Chen, X., Yang, Y.: Safety helmet wearing detection method of improved YOLO v3. Comput. Eng. Appl. 55(11), 213–220 (2019)

    Google Scholar 

  21. Wu, F., Jin, G.Q., Gao, M.Y., et al.: Helmet detection based on improved YOLOV3 deep model. In: 2019 IEEE 16th International Conference on Networking, Sensing and Control (ICNSC), Banff, AB, Canada, pp 363–368 (2019)

  22. Wang, Y., Gu, Y., Feng, X., et al.: Research on detection method of helmet wearing based on attitude estimation. Appl. Res. Comput. 38(3), 937–940 (2021)

    Google Scholar 

  23. Xu, C., Yuan, H., Li, G., et al.: Research on safety helmet wearing detection method based on scene augment. Comput. Eng. Appl. 58(19), 326–332 (2022)

  24. Zhu, X., Lyu, S., Wang, X., et al.: TPH-YOLOv5: improved YOLOv5 based on transformer prediction head for object detection on drone-captured scenarios. In: IEEE/CVF International Conference on Computer Vision (ICCVW), Electr Network, pp. 2778–2788 (2021)

  25. Zhu, L.L., Geng, X., Li, Z., et al.: Improving YOLOv5 with attention mechanism for detecting boulders from planetary images. Remote Sens. 13(18), 152–161 (2021)

    Article  Google Scholar 

  26. Luo, S., Yu, J., Xi, Y.J., et al.: Aircraft target detection in remote sensing images based on improved YOLOv5. IEEE Access 10, 5184–5192 (2022)

    Article  Google Scholar 

  27. Chen, J.Z., Jia, K.K., Chen, W.Q., et al.: A real-time and high-precision method for small traffic-signs recognition. Neural Comput. Appl. 34(3), 2233–2245 (2021)

    Article  Google Scholar 

  28. Fang, W., Wang, L., Ren, P.M.: Tinier-YOLO: a real-time object detection method for constrained environments. IEEE Access 8, 1935–1944 (2019)

    Article  Google Scholar 

  29. Zhang, G.Q., Yang, J.C., Zheng, Y.H., et al.: Hybrid-attention guided network with multiple resolution features for person reidentification. Inf. Sci. 578(8), 51–62 (2021)

    Google Scholar 

  30. Woo, S., Park, J., Lee, J.-Y., et al.: CBAM: convolutional block attention module. In: 15th European Conference on Computer Vision (ECCV), Munich, Germany, pp. 3–19 (2018)

  31. Hou, Q.B., Zhou, D.Q., Feng, J.S.: Coordinate attention for efficient mobile network design. In: IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Electr Network, pp. 13708–13717 (2021)

Download references

Acknowledgements

This research is supported by Hebei Province Full-time Top-level Talents Introduction Project, No. 2020HBQZYC013 and the China Construction Sixth Engineering Bureau Research and Development Project, No. CSCEC6B-2022-Z-2. We are grateful to the State Key Laboratory of Hydraulic Engineering Simulation and Safety of Tianjin University for its support to this project. Thanks to Elsevier language editing services.

Funding

Hebei Province Full-time Top-level Talents Introduction Project, 2020HBQZYC013, Hongbo Liu, China Construction Sixth Engineering Bureau Research and Development Project, CSCEC6B-2022-Z-2, Qian Zhang.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Hongbo Liu.

Ethics declarations

Conflict of interest

The authors declare that they have no competing interests.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Chen, Z., Zhang, F., Liu, H. et al. Real-time detection algorithm of helmet and reflective vest based on improved YOLOv5. J Real-Time Image Proc 20, 4 (2023). https://doi.org/10.1007/s11554-023-01268-w

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: https://doi.org/10.1007/s11554-023-01268-w

Keywords

Navigation