As the unique identifier of individual breeding pigs, the loss of ear tags can result in the loss of breeding pigs’ identity information, leading to data gaps and confusion in production and genetic breeding records, which can have catastrophic consequences for breeding efforts. Detecting the loss of ear tags in breeding pigs can be challenging in production environments due to factors such as overlapping breeding pig clusters, imbalanced pig-to-tag ratios, and relatively small-sized ear tags. This study proposes an improved method for the detection of lost ear tags in breeding pigs based on Cascade Mask R-CNN. Firstly, the model utilizes ResNeXt combined with a feature pyramid network (FPN) as the feature extractor; secondly, the classification branch incorporates the online hard example mining (OHEM) technique to improve the utilization of ear tags and low-confidence samples; finally, the regression branch employs a decay factor of Soft-NMS to reduce the overlap of redundant bounding boxes. The experiment employs a sliding window detection method to evaluate the algorithm’s performance in detecting lost ear tags in breeding pigs in a production environment. The results show that the accuracy of the detection can reach 92.86%. This improvement effectively enhances the accuracy and real-time performance of lost ear tag detection, which is highly significant for the production and breeding of breeding pigs.
Read full abstract