Abstract
In intelligent and precision livestock farming, continuous individual-level tracking of group-housed pigs is essential for behavior monitoring and health management. However, in real-world group-housing environments, high appearance similarity among pigs, frequent occlusions, intensive interactions, and irregular motion patterns cause trajectory fragmentation and identity drift. Therefore, a long-term multi-pig tracking framework tailored for group-housed pig barn scenarios is developed in this study. Within a standard “detection–association–trajectory management” pipeline, data association is performed by jointly exploiting appearance features and motion information, with Re-identification-based appearance modeling. In addition, an identity memory bank and a trajectory relinking mechanism are introduced to enhance identity recovery following occlusions and reduce identity switches (IDSWs). The proposed framework was evaluated on real-world pig barn surveillance video data. Under same-scene conditions, the model demonstrated improved identity consistency and high tracking accuracy, achieving a multiple object tracking accuracy (MOTA) of 0.9010, an identity F1 Score (IDF1) of 0.6762, and an IDSW of 24, outperforming BoT-SORT (MOTA = 0.8673, IDF1 = 0.5675, IDSW = 40), ByteTrack (MOTA = 0.8585, IDF1 = 0.5735, IDSW = 30) and DeepSORT (MOTA = 0.8640, IDF1 = 0.5615, IDSW = 40). Moreover, under more challenging cross-scene conditions, partial generalization was still observed (MOTA = 0.7011, IDF1 = 0.0950, IDSW = 405), indicating transferability to scene variations, severe occlusions, and imaging noise. Overall, the proposed framework provides more reliable long-term individual-level trajectory acquisition for group-housed pigs, supporting behavior analysis and management decision-making in intelligent livestock farming. The method has been made publicly available on GitHub (https://github.com/glimmerc33-ui/pig_track.git). © 2026 Elsevier B.V.
| Original language | English |
|---|---|
| Article number | 112203 |
| Journal | Computers and Electronics in Agriculture |
| Volume | 253 |
| Online published | 18 Jul 2026 |
| DOIs | |
| Publication status | Online published - 18 Jul 2026 |
Funding
The authors acknowledge financial support provided by the Science and Technology Innovation Capacity Building Program of the Beijing Academy of Agriculture and Forestry Sciences (KJCX20250913), the Open Research Fund of Key Laboratory of Smart Farming Technology for Agricultural Animals, Ministry of Agriculture and Rural Affairs (KLSFTAA-KF001-2025), and the Outstanding Scientist Program of the Beijing Academy of Agriculture and Forestry Sciences (JKZX202214).
Research Keywords
- Group-housed pigs
- Multi-object tracking
- Re-identification
- Occlusion-robust tracking
- Precision livestock farming
Fingerprint
Dive into the research topics of 'Long-Term identity-consistent multi-pig tracking in group-housed pens'. Together they form a unique fingerprint.Cite this
- APA
- Author
- BIBTEX
- Harvard
- Standard
- RIS
- Vancouver