Abstract:
Precise phenotypic measurement is often required in the domain of dairy sheep breeding. Three-dimensional (3D) reconstruction can be expected to phenotype the dairy sheep. However, the conventional 3D reconstruction pipelines are confined to significant challenges in practical applications, including the limited robustness of background segmentation in complex farming environments and the high sensitivity of registration to initial poses. It is often required for the multi-stage process rather than a streamlined one-step process. In this study, an integrated 3D reconstruction was proposed to combine an improved PointNet++ model, the coherent point drift (CPD) algorithm, and a local overlap-based strategy. Firstly, the dataset annotation was developed using the set difference. A scenario-adaptive parameter tuning strategy was augmented to accommodate the varying environments. The initial annotation accuracy was further improved after error detection and localized manual correction. Secondly, an enhanced PointNet++ model was applied for the background segmentation. Some improvements included the incorporation of point pair features (PPF), optimized sampling strategies, and a refined loss function. Model performance was evaluated using mean intersection over union (mIoU), mean accuracy, and inference speed. Finally, the CPD algorithm was integrated with a local overlap strategy for 3D registration of dairy sheep point clouds. Evaluation metrics included the isotropic and anisotropic rotation and translation errors, as well as the chamfer distance of overlapping point clouds. Body measurements were compared with the manual reconstruction. Ablation experiments were carried out to validate the practicality and reliability. The reconstruction accuracy was then obtained to fully meet the practical requirements of breeding. The experimental results show that the addition of PPF features improved the accuracy and mean intersection over union (IoU) by 2.91 and 2.2 percentage points, respectively, compared with the original PointNet++. The PPF effectively enhanced the representation of the local geometric information in point clouds, thereby significantly improving segmentation performance. The farthest point sampling (FPS) was replaced with the sliding window sampling (SWR). The inference speed increased by 44.5 ms, as the SWR was reduced the computational complexity. Global distance iteration was avoided to maintain the point set representativeness. The loss function improved the accuracy and mIoU by 1.12 and 1.10 percentage points, respectively, after optimization, indicating better regularization against overfitting for the high perception of local geometry. Once all three improvements were combined, the model achieved the optimal performance: 98.78% accuracy, 97.25% mIoU, and 53.4 ms inference speed—corresponding to a 3.04 percentage points gain in accuracy, 2.53 percentage points in mIoU, and a 45.17% reduction in inference time, compared with the original model. In 3D registration using the CPD algorithm with the overlapping region point cloud model, the anisotropic rotation error, anisotropic translation error, isotropic rotation error, isotropic translation error, and chamfer distance were 0.025 6°, 0.022 9 m, 3.0887°, 0.046 3 m, and 0.0078 9 m, respectively. Compared with the original CPD for complete point cloud registration, these metrics were improved by factors of 3.18, 2.11, 3.07, 2.14, and 3.77, respectively. The mean absolute percentage errors (MAPE) were 3.34%, 3.07%, 3.32%, 3.63%, and 2.81%, respectively, for the body length, front height, rear height, chest depth, and chest circumference, compared with the manual body measurements data. The mean absolute errors (MAE) of the key body dimensions ranged from 1.77 to 3.40 cm, and the root mean square errors (RMSE) ranged from 1.86 to 3.85 cm. The PointNet++ model with the CPD algorithm and overlapping region point cloud strategy improved the accuracy of the background segmentation and processing speed, fully meeting the requirements for one-step 3D reconstruction of dairy sheep. The body measurement errors were within an acceptable range, indicating the practical applicability in the phenotypic assessment for breeding.