Dynamic coupling analysis of group-housed pig behaviors and pigsty environmental factors based on the PIG-Net model - Zhang, Wen; Zhang, Xinzhe; Shi, Zhengxiang; Lin, Hai; Gao, Zhan; Shao, Mingxi; Du, Yuefeng; Zhang, Zaiying; Fu, Shenghui (International Journal of Agricultural and Biological Engineering, 2026)
Behavioral responses of group-housed pigs are strongly influenced by pigsty environmental conditions, yet their dynamic coupling is difficult to quantify under commercial farming scenarios. This difficulty arises from high inter-pig similarity, complex interactions, and rapidly changing environmental conditions, which pose significant challenges for existing vision-based multi-pig behavior detection and tracking methods. To address these challenges, this study proposes a PIG-Net–based dynamic coupling analysis framework that integrates behavior detection, multi-pig tracking, and behavior-environment interaction analysis. The model uses an EfficientRepBiFusion backbone with bidirectional feature fusion and a lightweight LSDGCD detection head, achieving mean Average Precision (mAP) of 93.5% for PIG YOLO on four pig behaviors—standing, dog-sitting, lateral lying, and prone lying. The integrated PIG-Net system achieves stable tracking performance with identification average rate (IDF1) of 90.7%, multiple object tracking accuracy (MOTA) of 88.6%, and a real-time processing speed of 26 FPS, while environmental sensors continuously record temperature, humidity, and CO2 levels for long-term correlation analysis. Based on long-term monitoring, Pearson correlation analysis was applied to quantify the associations between pig behaviors and environmental factors, highlighting significant correlations with coefficients r ranging from 0.65 to 0.76. By combining these quantitative results with temporal and dimensionality reduction analyses, temperature, humidity, and CO2 were identified as the primary environmental drivers. Active behaviors decreased under elevated temperature and humidity and increased during cooler and drier periods, whereas prone lying and lateral lying increased under thermal and moisture stress. Elevated CO2 concentrations further suppressed activity, reflecting inhibitory effects of degraded air quality. These findings provide a quantitative basis for behavior-environment coupling assessment and early health warning in group-housed pigs. Keywords: pig behavior detection, environmental dynamics, PIG-Net, behavior–environment coupling, animal welfare assessment DOI: 10.25165/j.ijabe.20261901.10337 Citation: Zhang W, Zhang X Z, Shi Z X, Lin H, Gao Z, Shao M X, et al. Dynamic coupling analysis of group-housed pig behaviors and pigsty environmental factors based on the PIG-Net model. Int J Agric & Biol Eng, 2026; 19(1): 47–58.