江西农业大学学报2024,Vol.46Issue(3):763-773,11.DOI:10.3724/aauj.2024068
基于改进YOLOv5的病死猪猪头的识别及三维定位方法
Identification and 3D localization of dead pig head based on improved YOLOv5
摘要
Abstract
[Objective]In order to provide the grasping target for the sick and dead pig handling robot,[Method]A new method for the identification and 3D location of dead pig head based on improved YOLOv5 is proposed.In this method,the backbone of YOLOv5 object detection algorithm is replaced with a lightweight feature extraction network mobilenetv2,and the size of the obtained training weight parameters is reduced.CBAM attention mechanism was introduced into the backbone feature extraction network to improve the attention of dead pig head.realsenseD435 depth camera was used to acquire the target image,and the 3D spatial coordinate imaging model was established for the pig head of the dead pig.The comparison experiment and localization experiment are designed to verify it.[Result]Compared with the YOLOv5 feature extraction network,the lightweight processing backbone network can reduce the weight file size from 13.7 MB to 5.9 MB,a reduction of 56%.The introduction of CBAM reduces the detection speed of a single image from 17.9 ms to 11.6 ms,a decrease of 6.3 ms.The average error of the 3D positioning model constructed by the realsenseD435 depth camera in the X,Y and Z axes is 0.021 m,0.023 m and 0.042 m,respectively,which are all less than 0.05 m.[Conclusion]The improved YOLOv5 object detection model can effectively reduce the weight file size and improve the detection rate.The 3D positioning model constructed by the realsenseD435 depth camera can accurately locate the head of a dead pig and calculate its 3D spatial coordinates.Therefore,based on the improved YOLOv5 pig head recognition and three-dimensional positioning method,it meets the identification and positioning requirements of the pig handling robot.关键词
YOLOv5/病死猪/猪头识别/三维定位/注意力机制/无人化Key words
YOLOv5/diseased pigs/pig head recognition/three-dimensional positioning/attention mecha-nism/unmanned分类
农业科技引用本文复制引用
彭兴鹏,何秀文,孙云涛,刘仁鑫,梁亚茹,钟玉媚,庞佳,熊康文..基于改进YOLOv5的病死猪猪头的识别及三维定位方法[J].江西农业大学学报,2024,46(3):763-773,11.基金项目
国家自然科学基金项目(62041106)Project supported by the National Natural Science Foundation of China(62041106) (62041106)