Abstract
Pig face detection plays a crucial role in the field of agricultural farming, especially in precise feeding and disease monitoring. This study proposes a method called adaptive region-based convolutional neural network (A-RCNN) for multiangled dirty pig face detection in outdoor environments. First, in order to address the interference caused by dirty cleaning surfaces, a feature enhancement module (FEM) is designed to improve the network's classification ability. Second, in order to ensure that the anchor points are more in line with the shape of the pig surface, an anchor point selection module (APSM) is introduced to generate high-quality area recommendations. Finally, in response to the interference problem of complex outdoor backgrounds, this article adopts a dynamic training strategy (DTS) to optimize the final detection results using these high-quality region suggestions. This study conducted an in-depth exploration of the publicly available JD dataset, and the experimental results showed that compared with existing methods, this method demonstrated excellent performance, achieving 56.3% mean average precision (mAP) and an improvement of 6.02% compared to the baseline Faster RCNN. In addition, to verify the practical application effect of the model, this article also deployed it on the edge device Raspberry Pi 4B, further confirming the effectiveness and practicality of the model.