Phương pháp phát hiện đối tượng thời gian thực dựa trên YOLOv5 và mạng di động hiệu quả

Shuai Feng1, Huaming Qian1, Huilin Wang1, Wenna Wang1
1College of Intelligent Systems Science and Engineering, Harbin Engineering University, Harbin, China

Tóm tắt

Thuật toán phát hiện đối tượng YOLOv5, dựa trên học sâu, gặp phải những bất cập do số lượng tham số mô hình quá nhiều và cấu trúc quá phức tạp. Những nhược điểm này cản trở việc triển khai nó trên các thiết bị di động, vốn bị hạn chế bởi khả năng tính toán và dung lượng lưu trữ. Để giải quyết những giới hạn này, chúng tôi giới thiệu một thuật toán phát hiện đối tượng nhẹ nhàng, tận dụng cơ chế chú ý tọa độ (CA) kết hợp với khung YOLOv5. Phương pháp của chúng tôi tích hợp cơ chế CA vào MobileNetv2 để tạo ra MobileNetv2-CA, từ đó thay thế CSDarkNet53 làm mạng xương sống cho YOLOv5. Sự đổi mới này không chỉ giúp giảm số lượng tham số của mô hình mà còn duy trì mức độ chính xác cạnh tranh. Để tăng cường hiệu suất, chúng tôi đề xuất một lớp phân tầng không gian nhanh đa tỉ lệ (MSPPF), được thiết kế để tăng tốc và tinh chỉnh cách mô hình xử lý các kích thước hình ảnh khác nhau. Kết hợp với điều này, chúng tôi tích hợp MPANet, một mạng tổng hợp đặc trưng bao gồm các mô-đun tăng mẫu và giảm mẫu được thiết kế tối ưu, cùng với các tế bào chiết xuất đặc trưng. Cấu hình này nhằm nâng cao độ chính xác phát hiện đồng thời giảm thiểu chi phí tham số. Kết quả thực nghiệm cho thấy sức mạnh của phương pháp chúng tôi: chúng tôi đạt được độ chính xác trung bình (mAP) là 87,6% trên tập dữ liệu PASCAL VOC07+12 và độ chính xác trung bình (AP) là 39,4% trên tập dữ liệu MS COCO, với kích thước tham số của mô hình chỉ 10,1MB. Khi so sánh với YOLOv5 gốc, mô hình mà chúng tôi đề xuất đạt được sự giảm tham số lên đến 76,9% và hoạt động với tốc độ nhanh gấp 1,72 lần, đạt 54,9 khung hình mỗi giây (FPS) trên NVIDIA RTX3060. So với các phương pháp SOTA, phương pháp của chúng tôi thể hiện sự cân bằng đáng khen giữa độ chính xác và hiệu suất thời gian thực.

Từ khóa

#YOLOv5 #phát hiện đối tượng #mạng di động #chú ý tọa độ #MobileNetv2 #MSPPF #MPANet

Tài liệu tham khảo

Bell, S., Zitnick, C.L., Bala, K., et al.: Inside-outside net: detecting objects in context with skip pooling and recurrent neural networks. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Las Vegas, NV, USA. pp. 2874–2883 (2016) Bochkovskiy, A., Wang, C.Y., Liao, H.Y.M.: YOLOv4: optimal speed and accuracy of object detection (2020). arXiv preprint. arXiv:2004.10934 Cai, L., Zhao, B., Wang, Z., et al.: MaxpoolNMS: getting rid of NMS bottlenecks in two-stage object detectors. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Long Beach, CA, USA. pp. 9356–9364 (2019) Carion, N., Massa, F., Synnaeve, G., et al.: End-to-end object detection with transformers. In: Proceedings of European Conference on Computer Vision(ECCV), Glasgow, UK. pp. 213–229 (2020) Ding, P., Qian, H., Chu, S.: SlimYOLOv4: lightweight object detector based on YOLOv4. J. Real-Time Image Process. 19(3), 487–498 (2022) Ding, P., Qian, H., Bao, J., et al.: L-YOLOv4: lightweight YOLOv4 based on modified RFB-s and depthwise separable convolution for multi-target detection in complex scenes. J. Real-Time Image Process. 20(4), 71 (2023) Elfwing, S., Uchibe, E., Doya, K.: Sigmoid-weighted linear units for neural network function approximation in reinforcement learning. Neural Netw 107, 3–11 (2018) Ge, Z., Liu, S., Wang, F., et al.: YOLOX: exceeding yolo series in 2021 (2021). arXiv preprint. arXiv:2107.08430 Girshick, R.: Fast R-CNN. In: Proceedings of the IEEE International Conference on Computer Vision(ICCV), Santiago, Chile. pp. 1440–1448 (2015) Han, K., Wang, Y., Tian, Q., et al.: GhostNet: more features from cheap operations. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Seattle, WA, USA. pp. 1580–1589 (2020) He, K., Zhang, X., Ren, S., et al.: Spatial pyramid pooling in deep convolutional networks for visual recognition. IEEE Trans. Pattern Anal. Mach. Intell. 37(9), 1904–1916 (2015) He, K., Gkioxari, G., Dollár, P., et al.: Mask R-CNN. In: Proceedings of the IEEE International Conference on Computer Vision(ICCV), Venice, Italy. pp. 2961–2969 (2017) Hou, Q., Zhou, D., Feng, J.: Coordinate attention for efficient mobile network design. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Nashville, TN, USA. pp. 13713–13722 (2021) Howard, A., Sandler, M., Chu, G., et al.: Searching for MobileNetV3. In: Proceedings of the IEEE/CVF International Conference on Computer Vision(ICCV), Seoul, Korea (South). pp. 1314–1324 (2019) Howard, A.G., Zhu, M., Chen, B., et al.: MobileNets: efficient convolutional neural networks for mobile vision applications (2017). arXiv preprint. arXiv:1704.04861 Jocher, G.: YOLOv5 by Ultralytics (2020). https://github.com/ultralytics/yolov5 Li, C., Li, L., Jiang, H., et al.: YOLOv6: a single-stage object detection framework for industrial applications (2022). arXiv preprint. arXiv:2209.02976 Li C, Li L, Geng Y, et al.: YOLOv6 v3.0: a full-scale reloading (2023). arXiv preprint. arXiv:2301.05586 Li, L., Li, B., Zhou, H.: Lightweight multi-scale network for small object detection. PeerJ Comput. Sci. 8, e1145 (2022) Li, Z., Zhou, F.: FSSD: feature fusion single shot multibox detector (2017). arXiv preprint. arXiv:1712.00960 Lin, T.Y., Dollár, P., Girshick, R., et al.: Feature pyramid networks for object detection. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Honolulu, HI, USA. pp. 2117–2125 (2017) Lin, T.Y., Goyal, P., Girshick, R., et al.: Focal loss for dense object detection. In: Proceedings of the IEEE International Conference on Computer Vision(ICCV), Venice, Italy. pp. 2980–2988 (2017) Liu, S., Huang, D., Wang, Y.: Learning spatial fusion for single-shot object detection (2019). arXiv preprint. arXiv:1911.09516 Liu, W., Anguelov, D., Erhan, D., et al.: SSD: single shot multibox detector. In: Proceedings of European Conference on Computer Vision(ECCV), Amsterdam, The Netherlands. pp. 21–37 (2016) Ma, N., Zhang, X., Zheng, H.T., et al.: ShuffleNet v2: practical guidelines for efficient CNN architecture design. In: Proceedings of the European Conference on Computer Vision (ECCV), pp. 116–131 (2018) Qi, F., Wang, Y., Tang, Z., et al.: Real-time and effective detection of agricultural pest using an improved YOLOv5 network. J. Real-Time Image Process. 20(2), 33 (2023) Qian, H., Wang, H., Feng, S., et al.: FESSD: SSD target detection based on feature fusion and feature enhancement. J. Real-Time Image Process. 20(1), 2 (2023) Qiao, S., Chen, L.C., Yuille, A.: Detectors: detecting objects with recursive feature pyramid and switchable atrous convolution. In; Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Nashville, TN, USA. pp. 10213–10224 (2021) Redmon, J., Farhadi, A.: YOLO9000: better, faster, stronger. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Honolulu, HI, USA. pp. 7263–7271 (2017) Redmon, J., Farhadi, A.: YOLOv3: an incremental improvement (2018). arXiv preprint. arXiv:1804.02767 Redmon, J., Divvala, S., Girshick, R., et al.: You only look once: unified, real-time object detection. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Las Vegas, NV, USA. pp. 779–788 (2016) 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) Sandler, M., Howard, A., Zhu, M., et al.: MobileNetv2: inverted residuals and linear bottlenecks. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Salt Lake City, UT, USA. pp. 4510–4520 (2018) Shi, W., Caballero, J., Huszár, F., et al.: Real-time single image and video super-resolution using an efficient sub-pixel convolutional neural network. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Las Vegas, NV, USA. pp. 1874–1883 (2016) Tan, M., Le, Q.V.: MixConv: mixed depthwise convolutional kernels (2019). arXiv preprint. arXiv:1907.09595 Tan, M., Pang, R., Le, Q.V.: EfficientDet: scalable and efficient object detection. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Seattle, WA, USA. pp. 10781–10790 (2020) Tang, Y., Han, K., Guo, J., et al.: GhostNetv2: enhance cheap operation with long-range attention (2022). arXiv preprint. arXiv:2211.12905 Wang, C., Tong, X., Gao, R., et al.: Mobile-YOLO: a lightweight and efficient implementation of object detector based on YOLOv4. Adv. Comput. Sci. Eng. Educ. 134, 221–234 (2022) Wang, C.Y., Liao, H.Y.M., Wu, Y.H., et al.: CSPNet: a new backbone that can enhance learning capability of CNN. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops(CVPR), Seattle, WA, USA. pp. 390–391 (2020) Wang, C.Y., Bochkovskiy, A., Liao, H.Y.M.: Scaled-yolov4: Scaling cross stage partial network. Proceedings of the IEEE/cvf conference on computer vision and pattern recognition(CVPR), Nashville, TN, USA. pp. 13,029–13,038 (2021) Wang, C.Y., Bochkovskiy, A., Liao, H.Y.M.: YOLOv7: trainable bag-of-freebies sets new state-of-the-art for real-time object detectors. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Vancouver, Canada. pp. 7464–7475 (2023) Wang, K., Liew, J.H., Zou, Y., et al.: PANet: few-shot image semantic segmentation with prototype alignment. In: Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 9197–9206 (2019) Wang, Q., Wu, B., Zhu, P., et al.: ECA-Net: efficient channel attention for deep convolutional neural networks. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR), Seattle, WA, USA. pp. 11534–11542 (2020) Xu, X., Jiang, Y., Chen, W., et al.: DAMO-YOLO: a report on real-time object detection design (2022). arXiv preprint. arXiv:2211.15444 Zhang, X., Zhou, X., Lin, M., et al.: ShuffleNet: an extremely efficient convolutional neural network for mobile devices. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition(CVPR), Salt Lake City, UT, USA. pp. 6848–6856 (2018) Zhao, Q., Sheng, T., Wang, Y., et al.: M2det: a single-shot object detector based on multi-level feature pyramid network. In: Proceedings of the AAAI Conference on Artificial Intelligence(AAAI), Honolulu, Hawaii, USA. pp. 9259–9266 (2019)