Sow farrowing detection and farrowing duration analysis based on Rotated Bounding Box and improved YOLOv8
Sow farrowing represents a critical stage in porcine production, profoundly impacting farm profitability and the welfare of both sows and piglets. Timely monitoring of maternal behavior is essential for ensuring successful delivery outcomes. This study proposes a novel real-time detection framework designed to identify farrowing onset and track individual piglets, thereby enabling continuous monitoring of the birthing process and precise recording of the total farrowing duration. To balance high detection accuracy with the computational efficiency required for on-farm deployment, several architectural optimizations are introduced: firstly, the standard C2f module is replaced with Ghost lightweight convolutions to minimize model complexity; secondly, a parameter-free SimAM attention mechanism is integrated to refine feature extraction for subtle variations in sow posture and piglet appearance; and thirdly, a specialized detection head, incorporating a Lightweight Asymmetric Decoupled Head, is employed to address piglet orientation challenges through the implementation of rotated bounding boxes, thereby enhancing localization and classification precision. Experimental results demonstrate that the optimized model achieves a mean average precision ([email protected]) of 96.7%, representing a 2.0% improvement over the baseline, while maintaining a low computational footprint of 1.14 million parameters and 2.9 GFLOPs. This robust and efficient system facilitates practical real-time monitoring in commercial farm environments, providing critical data to improve sow welfare and production efficiency within the paradigm of smart livestock farming.
Authors
- Yizhi Luo (ORCID: https://orcid.org/0000-0002-8362-5481)
- Zhixiong Zeng (ORCID: https://orcid.org/0000-0002-3822-1074)
- Jingjing Xia
- Xinyuan He
- Enli Lv
Publication Details
- Journal
- Smart Agricultural Technology
- Published
- 2026-01-15
- DOI
- https://doi.org/10.1016/j.atech.2026.101803
- Primary Topic
- Animal Behavior and Welfare Studies
- Type
- article
- Field-Weighted Citation Impact
- 0.00