Skip to main content
ARS Home » Plains Area » Clay Center, Nebraska » U.S. Meat Animal Research Center » Genetics and Animal Breeding » Research » Publications at this Location » Publication #417902

Research Project: Multi-Dimension Phenotyping to Enhance Prediction of Performance in Swine

Location: Genetics and Animal Breeding

Title: Deep learning algorithms to identify individual finishing pigs using 3D data

Author
item PAUDEL, SHIVA - University Of Nebraska
item BROWN-BRANDL, TAMI - University Of Nebraska
item Rohrer, Gary
item SHARMA, SUDHENDU RAJ - University Of Nebraska

Submitted to: Biosystems Engineering
Publication Type: Peer Reviewed Journal
Publication Acceptance Date: 4/3/2025
Publication Date: 4/19/2025
Citation: Paudel, S., Brown-Brandl, T.M., Rohrer, G., Sharma, S.R. 2025. Deep learning algorithms to identify individual finishing pigs using 3D data. Biosystems Engineering. 255. Article 104143. https://doi.org/10.1016/j.biosystemseng.2025.104143.
DOI: https://doi.org/10.1016/j.biosystemseng.2025.104143

Interpretive Summary: Accurately tracking and identifying individual pigs in commercial barns with computer vision is a crucial goal of many precision livestock farming studies. Tagging individual pigs reduces profit due to cost of the tags, labor to install tags, and the market value of the ears. However, the use of standard video cameras are unable to accurately identify animals due to changes in lighting, especially at night. Depth cameras are unaffected by level of light. Therefore, the objectives of this study were to determine the feasibility of using depth camera computer vision methods to identify individual finishing pigs and to determine the number of images, image resolution and frequency of retraining for continuous animal identification using two different software packages. Depth images were collected using a camera positioned over drinkers containing an RFID reader. Data used for this study included images from eight pigs over 14 days. The data were then processed to create different image resolutions. The findings revealed that the maximum accuracy of identifying individual animals resulted from low resolution images after five days of images were collected. In addition, acceptable accuracy of identification continued for approximately one week before the computer model would need to be retrained. This study underscores the potential of utilizing depth images and computer models for the purpose of individual pig identification within actual barn environments, including those with natural lighting conditions.

Technical Abstract: The application of precision livestock farming technology is heavily reliant on the identification of individuals. However, due to the cost and time constraints, finishing pigs are rarely tagged or otherwise identified. Therefore, the objectives of this study were to determine the feasibility of using deep learning on 3D spatial data to identify individual finishing pigs and to quantify the amount of data required, image resolution needed, and frequency of retraining for continuous identification using two different architectures: PointNet (which utilises point clouds directly) and 3D convolution neural network (3D CNN). Digital/depth images were collected using ToF (Time of Flight) camera positioned over RFID (Radio Frequency Identification) instrumented drinkers. A subset of this data were used for this initial validation study, which included 31976 images from eight pigs over 14 days. The data were then processed to create different sets of training and testing data with varying point sets (1500, 3000, 6000, 12000, 24000, and 48000) for point clouds and voxel sizes (50, 35, 25, and 15 mm) for 3D CNN. The findings revealed that the 3D CNN model achieved the highest F1 score of 0.91 after the sixth training session with a point voxel size of 15 mm. PointNet achieved its highest F1 score of 0.90 after five training sessions with a point set size of 1500 points. This study underscores the potential of utilising deep learning techniques for the purpose of individual pig identification within actual barn environments, including those with natural lighting conditions.