Peng Cheng, Cao Shanshan, Li Shujing, Bai Tao, Zhao Zengyuan, Sun Wei
College of Computer and Information Engineering, Xinjiang Agricultural University, Urumqi 830052, China.
Agricultural Information Institute, Chinese Academy of Agricultural Sciences, Beijing 100080, China.
Animals (Basel). 2024 Aug 23;14(17):2453. doi: 10.3390/ani14172453.
Traditional measurement methods often rely on manual operations, which are not only inefficient but also cause stress to cattle, affecting animal welfare. Currently, non-contact cattle dimension measurement usually involves the use of multi-view images combined with point cloud or 3D reconstruction technologies, which are costly and less flexible in actual farming environments. To address this, this study proposes an automated cattle dimension measurement method based on an improved keypoint detection model combined with unilateral depth imaging. Firstly, YOLOv8-Pose is selected as the keypoint detection model and SimSPPF replaces the original SPPF to optimize spatial pyramid pooling, reducing computational complexity. The CARAFE architecture, which enhances upsampling content-aware capabilities, is introduced at the neck. The improved YOLOv8-pose achieves a mAP of 94.4%, a 2% increase over the baseline model. Then, cattle keypoints are captured on RGB images and mapped to depth images, where keypoints are optimized using conditional filtering on the depth image. Finally, cattle dimension parameters are calculated using the cattle keypoints combined with Euclidean distance, the Moving Least Squares (MLS) method, Radial Basis Functions (RBFs), and Cubic B-Spline Interpolation (CB-SI). The average relative errors for the body height, lumbar height, body length, and chest girth of the 23 measured beef cattle were 1.28%, 3.02%, 6.47%, and 4.43%, respectively. The results show that the method proposed in this study has high accuracy and can provide a new approach to non-contact beef cattle dimension measurement.
传统的测量方法通常依赖人工操作,不仅效率低下,还会给牛带来压力,影响动物福利。目前,非接触式牛体尺寸测量通常涉及使用多视图图像结合点云或三维重建技术,这些方法成本高昂,在实际养殖环境中的灵活性较差。为了解决这个问题,本研究提出了一种基于改进的关键点检测模型结合单侧深度成像的牛体尺寸自动测量方法。首先,选择YOLOv8-Pose作为关键点检测模型,用SimSPPF替换原来的SPPF以优化空间金字塔池化,降低计算复杂度。在颈部引入增强上采样内容感知能力的CARAFE架构。改进后的YOLOv8-pose的平均精度均值(mAP)达到94.4%,比基线模型提高了2%。然后,在RGB图像上捕捉牛的关键点并映射到深度图像上,在深度图像上使用条件滤波对关键点进行优化。最后,结合欧几里得距离、移动最小二乘法(MLS)、径向基函数(RBF)和三次B样条插值(CB-SI),利用牛的关键点计算牛体尺寸参数。对23头被测肉牛的体高、腰高、体长和胸围的平均相对误差分别为1.28%、3.02%、6.47%和4.43%。结果表明,本研究提出的方法具有较高的精度,可为非接触式肉牛尺寸测量提供一种新途径。