IDEAS home Printed from https://ideas.repec.org/a/gam/jagris/v14y2024i8p1402-d1459371.html
   My bibliography  Save this article

Detection of Feeding Behavior in Lactating Sows Based on Improved You Only Look Once v5s and Image Segmentation

Author

Listed:
  • Luo Liu

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Veterinary Medicine, Nanjing Agricultural University, Nanjing 210095, China)

  • Shanpeng Xu

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Artificial Intelligence, Nanjing Agricultural University, Nanjing 210031, China)

  • Jinxin Chen

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Engineering, Nanjing Agricultural University, Nanjing 210031, China)

  • Haotian Wang

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Artificial Intelligence, Nanjing Agricultural University, Nanjing 210031, China)

  • Xiang Zheng

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Artificial Intelligence, Nanjing Agricultural University, Nanjing 210031, China)

  • Mingxia Shen

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Artificial Intelligence, Nanjing Agricultural University, Nanjing 210031, China)

  • Longshen Liu

    (Key Laboratory of Livestock Farming Equipment, Ministry of Agriculture and Rural Affairs, Nanjing 210031, China
    College of Artificial Intelligence, Nanjing Agricultural University, Nanjing 210031, China)

Abstract

The production management of lactating sows is a crucial aspect of pig farm operations, as their health directly impacts the farm’s production efficiency. The feeding behavior of lactating sows can reflect their health and welfare status, and monitoring this behavior is essential for precise feeding and management. To address the issues of time-consuming and labor-intensive manual inspection of lactating sows’ feeding behavior and the reliance on breeders’ experience, we propose a method based on the improved YOLO (You Only Look Once) v5s algorithm and image segmentation for detecting the feeding behavior of lactating sows. Based on the YOLOv5s algorithm, the SE (Squeeze-and-Excitation) attention module was added to enhance the algorithm’s performance and reduce the probability of incorrect detection. Additionally, the loss function was replaced by WIoU (Weighted Intersection over Union) to accelerate the model’s convergence speed and improve detection accuracy. The improved YOLOv5s-C3SE-WIoU model is designed to recognize pre-feeding postures and feed trough conditions by detecting images of lactating sows. Compared to the original YOLOv5s, the improved model achieves an 8.9% increase in mAP@0.5 and a 4.7% increase in mAP@0.5 to 0.95. This improvement satisfies the requirements for excellent detection performance, making it suitable for deployment in large-scale pig farms. From the model detection results, the trough remnant image within the detection rectangle was extracted. This image was further processed using image processing techniques to achieve trough remnant image segmentation and infer the remnant amount. Based on the detection model and residue inference method, video data of lactating sows’ feeding behavior were processed to derive the relationship between feeding behavior, standing time, and residue amount. Using a standing duration of 2 s and a leftover-feed proportion threshold of 2% achieves the highest accuracy, enabling the identification of abnormal feeding behavior. We analyzed the pre-feeding postures and residual feed amounts of abnormal and normal groups of lactating sows. Our findings indicated that standing time was significantly lower and residual feed amount was higher in the abnormal groups compared to the normal groups. By combining standing time and residual feed amount information, accurate detection of the feeding status of lactating sows can be realized. This approach facilitates the accurate detection of abnormal feeding behaviors of lactating sows in large-scale pig farm environments.

Suggested Citation

  • Luo Liu & Shanpeng Xu & Jinxin Chen & Haotian Wang & Xiang Zheng & Mingxia Shen & Longshen Liu, 2024. "Detection of Feeding Behavior in Lactating Sows Based on Improved You Only Look Once v5s and Image Segmentation," Agriculture, MDPI, vol. 14(8), pages 1-21, August.
  • Handle: RePEc:gam:jagris:v:14:y:2024:i:8:p:1402-:d:1459371
    as

    Download full text from publisher

    File URL: https://www.mdpi.com/2077-0472/14/8/1402/pdf
    Download Restriction: no

    File URL: https://www.mdpi.com/2077-0472/14/8/1402/
    Download Restriction: no
    ---><---

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:gam:jagris:v:14:y:2024:i:8:p:1402-:d:1459371. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    We have no bibliographic references for this item. You can help adding them by using this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: MDPI Indexing Manager (email available below). General contact details of provider: https://www.mdpi.com .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.