{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,10,7]],"date-time":"2026-10-07T17:04:53Z","timestamp":1791392693690,"version":"4.3.3"},"reference-count":20,"publisher":"MDPI AG","issue":"17","license":[{"start":{"date-parts":[[2025,9,5]],"date-time":"2025-09-05T00:00:00Z","timestamp":1757030400000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"funder":[{"name":"Key Research and Development Project of Guangxi","award":["GuikeAB23026031"],"award-info":[{"award-number":["GuikeAB23026031"]}]},{"name":"Key Research and Development Project of Guangxi","award":["GuikeAD23023002"],"award-info":[{"award-number":["GuikeAD23023002"]}]},{"name":"Key Research and Development Project of Guangxi","award":["2022003"],"award-info":[{"award-number":["2022003"]}]},{"name":"Science and Technology Project of Guangxi","award":["GuikeAB23026031"],"award-info":[{"award-number":["GuikeAB23026031"]}]},{"name":"Science and Technology Project of Guangxi","award":["GuikeAD23023002"],"award-info":[{"award-number":["GuikeAD23023002"]}]},{"name":"Science and Technology Project of Guangxi","award":["2022003"],"award-info":[{"award-number":["2022003"]}]},{"name":"Yongjiang Plan Talent Project","award":["GuikeAB23026031"],"award-info":[{"award-number":["GuikeAB23026031"]}]},{"name":"Yongjiang Plan Talent Project","award":["GuikeAD23023002"],"award-info":[{"award-number":["GuikeAD23023002"]}]},{"name":"Yongjiang Plan Talent Project","award":["2022003"],"award-info":[{"award-number":["2022003"]}]}],"content-domain":{"domain":[],"crossmark-restriction":false},"short-container-title":["Sensors"],"abstract":"<jats:p>Heat stress severely impacts pig welfare and farm productivity. However, existing methods lack the capability to detect subtle physiological cues (e.g., skin erythema) in complex farm environments while maintaining real-time efficiency. This paper proposes PigStressNet, a novel lightweight detector designed for accurate and efficient heat stress recognition. Our approach integrates four key innovations: (1) a Normalization-based Attention Module (NAM) integrated into the backbone network enhances sensitivity to localized features critical for heat stress, such as posture and skin erythema; (2) a Rectangular Self-Calibration Module (RCM) in the neck network improves spatial feature reconstruction, particularly for occluded pigs; (3) an MBConv-optimized detection head (MBHead) reduces computational cost in the head by 72.3%; (4) the MPDIoU loss function enhances bounding box regression accuracy in scenarios with overlapping pigs. We constructed the first fine-grained dataset specifically annotated for pig heat stress (comprising 710 images across 5 classes: standing, eating, sitting, lying, and stress), uniquely fusing posture (lying) and physiological traits (skin erythema). Experiments demonstrate state-of-the-art performance: PigStressNet achieves 0.979 mAP for heat stress detection while requiring 15.9% lower computation (5.3 GFLOPs) and 11.7% fewer parameters compared to the baseline YOLOv12-n model. The system achieves real-time inference on embedded devices, offering a viable solution for intelligent livestock management.<\/jats:p>","DOI":"10.3390\/s25175534","type":"journal-article","created":{"date-parts":[[2025,9,5]],"date-time":"2025-09-05T12:18:18Z","timestamp":1757074698000},"page":"5534","update-policy":"https:\/\/doi.org\/10.3390\/mdpi_crossmark_policy","source":"Crossref","is-referenced-by-count":1,"title":["PigStressNet: A Real-Time Lightweight Vision System for On-Farm Heat Stress Monitoring via Attention-Guided Feature Refinement"],"prefix":"10.3390","volume":"25","author":[{"ORCID":"https:\/\/orcid.org\/0009-0009-3817-2872","authenticated-orcid":false,"given":"Shuai","family":"Cao","sequence":"first","affiliation":[{"name":"School of Computer Science and Information Security, Guilin University of Electronic Technology, Guilin 541004, China"},{"name":"Center for Applied Mathematics of Guangxi (GUET), Guilin 541004, China"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Fang","family":"Li","sequence":"additional","affiliation":[{"name":"School of Computer Science and Information Security, Guilin University of Electronic Technology, Guilin 541004, China"},{"name":"Center for Applied Mathematics of Guangxi (GUET), Guilin 541004, China"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Xiaonan","family":"Luo","sequence":"additional","affiliation":[{"name":"School of Computer Science and Information Security, Guilin University of Electronic Technology, Guilin 541004, China"},{"name":"Center for Applied Mathematics of Guangxi (GUET), Guilin 541004, China"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Jiacheng","family":"Ni","sequence":"additional","affiliation":[{"name":"School of Computer Science and Information Security, Guilin University of Electronic Technology, Guilin 541004, China"},{"name":"Center for Applied Mathematics of Guangxi (GUET), Guilin 541004, China"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Linsong","family":"Li","sequence":"additional","affiliation":[{"name":"School of Computer Science and Information Security, Guilin University of Electronic Technology, Guilin 541004, China"},{"name":"Center for Applied Mathematics of Guangxi (GUET), Guilin 541004, China"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"1968","published-online":{"date-parts":[[2025,9,5]]},"reference":[{"key":"ref_1","doi-asserted-by":"crossref","first-page":"59","DOI":"10.1093\/jas\/skad341.064","article-title":"Bioenergetic consequences of pre- and post-natal heat stress on swine productivity","volume":"101","author":"Johnson","year":"2023","journal-title":"J. Anim. Sci."},{"key":"ref_2","doi-asserted-by":"crossref","first-page":"txaf001","DOI":"10.1093\/tas\/txaf001","article-title":"Heat stress matters: Insights from United States swine producers","volume":"9","author":"Johnson","year":"2025","journal-title":"Transl. Anim. Sci."},{"key":"ref_3","doi-asserted-by":"crossref","first-page":"1404","DOI":"10.1071\/AN17725","article-title":"Heat stress: Impact on livestock well-being and productivity and mitigation strategies to alleviate the negative effects","volume":"58","author":"Johnson","year":"2018","journal-title":"Anim. Prod. Sci."},{"key":"ref_4","doi-asserted-by":"crossref","first-page":"18","DOI":"10.1093\/jas\/skae234.019","article-title":"Genomic selection for heat stress resilience in pigs: Advancements, applications, and challenges","volume":"102","author":"Johnson","year":"2024","journal-title":"J. Anim. Sci."},{"key":"ref_5","doi-asserted-by":"crossref","unstructured":"Nasirahmadi, A., Sturm, B., Edwards, S., Jeppsson, K.-H., Olsson, A.-C., M\u00fcller, S., and Hensel, O. (2019). Deep learning and machine vision approaches for posture detection of individual pigs. Sensors, 19.","DOI":"10.3390\/s19173738"},{"key":"ref_6","doi-asserted-by":"crossref","unstructured":"Sa, J., Choi, Y., Lee, H., Chung, Y., Park, D., and Cho, J. (2019). Fast pig detection with a top-view camera under various illumination conditions. Symmetry, 11.","DOI":"10.3390\/sym11020266"},{"key":"ref_7","doi-asserted-by":"crossref","unstructured":"Zhang, L., Gray, H., Ye, X., Collins, L., and Allinson, N. (2019). Automatic individual pig detection and tracking in pig farms. Sensors, 19.","DOI":"10.3390\/s19051188"},{"key":"ref_8","doi-asserted-by":"crossref","first-page":"105391","DOI":"10.1016\/j.compag.2020.105391","article-title":"Automatically detecting pig position and posture by 2D camera imaging and deep learning","volume":"174","author":"Riekert","year":"2020","journal-title":"Comput. Electron. Agric."},{"key":"ref_9","unstructured":"Kang, F.L. (2018). Research on Multi-Target Pig State and Individual Behavior Recognition Based on Machine Learning. [Ph.D. Thesis, Inner Mongolia Agricultural University]. (In Chinese)."},{"key":"ref_10","unstructured":"Li, L. (2019). Research on Motion Feature Recognition of Quadruped Animals Based on Vision. [Master\u2019s Thesis, Kunming University of Science and Technology]. (In Chinese)."},{"key":"ref_11","first-page":"137","article-title":"Application of acceleration sensors in livestock behavior research","volume":"52","author":"Liu","year":"2020","journal-title":"Anim. Husb. Vet. Med."},{"key":"ref_12","first-page":"148","article-title":"Pig behavior recognition method based on posture and time series characteristics","volume":"38","author":"Dong","year":"2022","journal-title":"Trans. Chin. Soc. Agric. Eng."},{"key":"ref_13","unstructured":"Tian, Y., Ye, Q., and Doermann, D. (2025). Yolov12: Attention-centric real-time object detectors. arXiv."},{"key":"ref_14","unstructured":"Shao, Z., and Hoffmann, N. (2021, January 13). NAM: Normalization-based attention module. Proceedings of the NeurIPS Workshop ImageNet: Past, Present, Future, Mexico City, Mexico."},{"key":"ref_15","doi-asserted-by":"crossref","unstructured":"Ni, Z., Chen, X., Zhai, Y., Tang, Y., and Wang, Y. (October, January 29). Context-guided spatial feature reconstruction for efficient semantic segmentation. Proceedings of the Computer Vision\u2013ECCV 2024, 18th European Conference, Milan, Italy.","DOI":"10.1007\/978-3-031-72943-0_14"},{"key":"ref_16","unstructured":"Tan, M., and Le, Q.V. (2019, January 9\u201315). EfficientNet: Rethinking model scaling for convolutional neural networks. Proceedings of the 36th International Conference on Machine Learning, Long Beach, CA, USA."},{"key":"ref_17","unstructured":"Ma, S., and Xu, Y. (2023). MPDIoU: A loss for efficient and accurate bounding box regression. arXiv."},{"key":"ref_18","doi-asserted-by":"crossref","unstructured":"Ma, N., Zhang, X., and Zheng, H.T. (2018, January 8\u201314). ShuffleNet V2: Practical guidelines for efficient CNN architecture design. Proceedings of the European Conference on Computer Vision (ECCV), Munich, Germany.","DOI":"10.1007\/978-3-030-01264-9_8"},{"key":"ref_19","doi-asserted-by":"crossref","unstructured":"Han, K., Wang, Y., Tian, Q., Guo, J., Xu, C., and Xu, C. (2020, January 14\u201319). GhostNet: More features from cheap operations. Proceedings of the IEEE\/CVF Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA.","DOI":"10.1109\/CVPR42600.2020.00165"},{"key":"ref_20","unstructured":"Howard, A., Sandler, M., Chen, B., Wang, W., Chen, L.-C., Tan, M., Chu, G., Vasudevan, V., Zhu, Y., and Pang, R. (November, January 27). Searching for MobileNetV3. Proceedings of the IEEE\/CVF International Conference on Computer Vision, Seoul, Republic of Korea."}],"container-title":["Sensors"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/www.mdpi.com\/1424-8220\/25\/17\/5534\/pdf","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,10,9]],"date-time":"2025-10-09T18:40:04Z","timestamp":1760035204000},"score":1,"resource":{"primary":{"URL":"https:\/\/www.mdpi.com\/1424-8220\/25\/17\/5534"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2025,9,5]]},"references-count":20,"journal-issue":{"issue":"17","published-online":{"date-parts":[[2025,9]]}},"alternative-id":["s25175534"],"URL":"https:\/\/doi.org\/10.3390\/s25175534","relation":{},"ISSN":["1424-8220"],"issn-type":[{"value":"1424-8220","type":"electronic"}],"subject":[],"published":{"date-parts":[[2025,9,5]]}}}