Precision livestock farming

Blueprint: When technology improves on-farm piglet welfare monitoring.

April 23, 2020

14 Min Read
Piglets nursing on a sow
National Pork Board

It is estimated that by 2050, the world population will be more than 9 billion people and that food production will need to increase up to 60% more to meet demand (Food and Agriculture Organization of the U.N., 2009). World population increase will mainly take part in developing countries, where economic growth will be accompanied by an increase in income level and changes in dietary habits, and it is expected that people will eat more animal products (Godfray and Garnett, 2014).

It is likely that livestock production would intensify even more, with farmers aiming to maximize output per animal unit. Additionally, as more animals will need to be produced, farm expansion will likely increase animal density and lower the stockperson-per-animal ratio. This will result in less time available to monitor and manage individual animals properly, jeopardizing animal health and welfare.

In recent years, consumers have demanded a higher welfare environment for sows and piglets in food production, meaning systems that use little or no confinement for sows during lactation could soon be standard practice.

Therefore, it is essential to protect piglets during that critical period when mortality risk, especially due to crushing, is greatest to maintain high standards of welfare, productivity and output from commercial farms.

Additionally, welfare assessment within all phases of swine production involves pigs at a single stage of their productive life — except in the farrowing environment, where the sow and her piglets are at two very different stages of their lives and have different requirements for their thermal, social and physical environments.

Consequently, a system that may be ideal for the welfare needs and requirements of the sow may be far from optimal for her piglets, and vice versa. To decrease piglet mortality, there needs to be a greater reliance on optimal management of the farrowing and lactating systems (Marchant-Forde, 2011).

Therefore, there is currently a growing interest to automate piglet welfare assessment using precision livestock farming. PLF comprises the application of engineering techniques in livestock farming to monitor, model and manage animal production, health and welfare. Its aim is to inform farmers more regularly — and with more details — about the health, welfare and productivity of their animals to help them make quick and evidence-based decisions on the animals' needs.

What is PLF?
In modern livestock production systems, farmers need reliable and affordable technologies to assist them in daily management tasks, which guarantees accurate and continuous individual animal monitoring. Application of engineering techniques in livestock farming to monitor, model and manage animal production is called PLF. Its aim is to increase the farmer's ability to keep contact with individual animals in the growing livestock production intensification (Vranken and Berckmans, 2017).

Three distinct conditions within a PLF system need to be fulfilled to achieve adequate monitoring and management levels (Berckmans, 2006).

■ continuous measurement of animal behavioral or physiological variables with sensor technology

■ prediction (expectation) on animal variables and animal response fluctuation

■ integrating predictions and measurements in analyzing algorithm for automatic monitoring and/or management

On-farm assessment 
There is no consensus on a unique definition of animal welfare within or across species where applicable. Definitions vary depending on factors such as cultural, scientific, religious and political background (Swanson, 1995).

There are several proposed approaches to scientifically assess animal welfare (e.g., feelings-based approach, natural living, the five freedoms, etc.), and each tends to emphasize different measurements. Curtis proposed that objective animal-based measures would provide a more accurate approach to assess farm animal welfare state, because "what cannot be measured cannot be managed" (Curtis, 2007).

Animal-based measures address the actual welfare states of animals in terms of their behavior, fearfulness, health or physical condition. Over the years, a series of pig welfare assessment protocols, such as the Welfare Quality Protocol, AssureWel, the Danish Animal Welfare Index and the Swine Welfare Assurance Program has been developed.

The protocols include several animal-based indicators that could be used to measure aspects of on-farm piglet welfare by farmers, veterinarians and advisory service personnel, among others. A summary of the animal-based measures included in the Welfare Quality Protocol is presented in Table 1.

Table: Animal-based measures to assess piglet welfare

Why is automation important?
Most animal-based welfare assessment is done using subjective methods. While visual scorings are easy to use and cheap to implement (Gregoire et al., 2013), they have disadvantages — such as the time and labor involved — and they are prone to observer error, mainly due to human visual perception limitations (Fan et al., 2009).

Once the animal-based measures are classified, the next step is to identify the maximum and minimum limits, and desired frequency of the measurements, to ensure real-time swine welfare management.

In the past, information collection on wide-ranging parameters was difficult, costly and often neglected. However, on-farm automated data collection systems have made the large amount of data collection and analysis highly feasible (Black, 2001).

Reliable data collection at acceptable time intervals is impractical using conventional scales due to greater labor requirements, and stress on both farmer and stock. With PLF, real-time, on-farm welfare monitoring and management becomes possible. (Banhazi and Black, 2009).

Data collection available
It is important to choose the appropriate technology with correct application to measure animal welfare in order to successfully automate animal health and welfare monitoring (Schon and Meiering, 1987).

Sensors that are commercially available and technically feasible for detecting thermal comfort (e.g., panting, huddling and body surface temperature), absence of injury (e.g., lameness), absence of disease (e.g., coughing, sneezing, pumping or labored breathing) are discussed in the next section.

Thermal comfort
Cook et al. (2018) used an automated method of estimating spatial distribution of piglets within a pen to assess huddling behavior under normal conditions and during a febrile response to vaccination. Results indicated infrared imaging could be used to quantify temperature and behavior from the same image (Cook et al., 2018).

Wouters et al. (1999) developed an interactive software package to integrate thermoregulatory behavior parameters in piglets into an image-analysis procedure. The parameters included: (a) the temporal and spatial occupancy of piglets in the sleeping area to decide the need for a temperature change; and (b) the proportion of pigs' thermal image pixels within a predefined window bordering the sleeping area in order to decide the need for heating or cooling (Wouters et al., 1990).

Lu et al. (2018) proposed an algorithm to extract ear base temperature automatically from top-view piglet thermal images. Left and right ear base temperature had the accuracy of 97% and 98%, respectively, to automatically identify sick piglets (Lu et al., 2018).

Cook et al. (2015) used infrared thermography to automatically assess piglets' thermal comfort (Cook et al., 2015).

Mostaco et al. (2015) identified the most adequate body surface areas of piglets to measure temperatures that best represent thermoregulation.

They showed that the tympanic region is the best area for monitoring using an infrared thermometer. In contrast, when using temperature sensors, the ear and the loin region are preferred to be used for temperature predictions (Mostaco et al., 2015).

Gorczyca et al. (2018) suggested that machine learning algorithms are robust to predict rectal, skin-surface and hair-coat surface temperatures of piglets with an error range of 0.36% to 1.35% (Gorczyca et al., 2018).

Da Fonseca et al. (2020) developed a model to predict stress in piglets based on the infrared skin temperature using machine learning and the paraconsistent logic (da Fonseca et al., 2020).

Take-home message. Further studies are needed to comprehend the surface temperature and body temperature relationship, and to include other attributes in the machine learning process to broadly apply thermal imaging as a technique for thermal comfort monitoring in swine production.

Absence of injury
Lind et al. (2005) and Kongsro et al. (2013) found that a digital video-based tracking system for automatically tracking pigs' locomotor behavior was inexpensive, highly reliable and accurate (Lind et al., 2005; Kongsro, 2013).

Kashiha et al. (2014) showed that piglet's locomotion in a group can be determined using image analysis with an accuracy of 89.8% (Kashiha et al., 2014).

Meijer et al. (2014) recommended a pressure mat as an objective, highly replicable tool to analyze and quantify porcine gait (Meijer et al., 2014).

Pluym et al. (2013) developed a detection system, based on force stance variables derived from force plate analysis, and visual stance variables derived from image processing.

She indicated that this system has very promising potential to support future objective research in swine lameness (Pluym et al., 2013).

McNeil et al. (2019) reported that force plate measurements could detect lameness almost five days earlier than using a visual scoring system (McNeil et al., 2019).

Take-home message. The digital video-based tracking system, pressure mat and force plate are accurate, reliable and save labor on-farm. However, more measurements and especially delicate software are needed to have a robust system for the farm environment.

Absence of disease
Some innovative approaches have already been taken to automatically detect coughing episodes in piggery buildings and use the frequency and intensity of these coughing episodes to detect respiratory diseases (Chedad et al., 2001; Moshou et al., 2001a, 2001b).

Gurino et al. (2004) validated cough detection algorithms and showed that they are able to classify coughs correctly in 86% of cases (Gurino et al., 2004).

Wang et al. (2019) identified the relationship between piglet sounds and air quality of their living environment using feature extraction.

The results indicated that the cough sound analysis can provide qualitative information about the situation of the air quality in commercial livestock buildings (Wang et al., 2019). Additionally, cough sound analysis could be used as an indication of pneumonic lesions (Pessoa et al. 2019).

Take-home message. Automatic detection and recognition of piglet diseases using sound data can be an efficient and economical solution. We suggest considering the multi-modality of video and audio data in a pig house surveillance system, which can incorporate the automatic detection and recognition of a piglet's vocalization.

Issues with automation
It is assumed that automation is more accurate than human observers; but machines do make mistakes, and events can occur which reduce the accuracy by which the electronic signals match the behavior of interest.

We need to choose behavioral measures according to their relevance to animal welfare and then develop automatic recording methods, rather than choosing measures for their ability to be recorded automatically (Rushen et al., 2012).

Using PLF, a large amount of data can be collected in a short time period, which can improve piglet welfare monitoring. However, future larger-scale studies and data combination from different sources in a multivariate approach are needed to develop a robust on-farm welfare monitoring system.

Azarpajouh* was previously with the Iowa State University Department of Animal Science; Calderón Díaz is in the Pig Development Department, Animal and Grassland Research and Innovation Centre, Teagasc; and Taheri is in the Georgia Southern University Department of Manufacturing Engineering.


Banhazi, T.M., and J.L. Black. 2009. "Precision Livestock Farming: A Suite of Electronic Systems to Ensure the Application of Best Practice Management on Livestock Farms." Australian Journal of Multi-Disciplinary Engineering 7 (1): 1-14.
Berckmans, D. 2006. "Automatic On-Line Monitoring of Animals by Precision Livestock Farming." Livestock Production and Society, 287-294.
Black, J. L. 2001. "Swine Production — Past, Present and Future." In Palestras XXXVII Reuniao Annual Sociedade Brasileira de ZootecniaBrazil, Sociedade Brasileira Do Zootecnia.
Chedad, A., D. Moshou, J. M. Aerts, A. Van Hirtum, H. Ramon, and D. Berckmans. 1001. "Recognition System for Pig Cough Based on Probabilistic Neural Networks." Journal of Agricultural Engineering Research 79 (4): 449-57.
Cook, N. J., C. J. Bench, T. Liu, B. Chabot, and A. L. Schaefer. 2018. "The Automated Analysis of Clustering Behaviour of Piglets from Thermal Images in Response to Immune Challenge by Vaccination." Animal 12 (1): 122-33.
Cook, N.J., B. Chabot, T. Lui, C.J. Bench, and A.L. Schaefer. 2015. "Infrared Thermography Detects Febrile and Behavioural Responses to Vaccination of Weaned Piglets." Animal: An International Journal of Animal Bioscience 9: 339-346.
Curtis, SE. 2007. "Performance Indicates Animal State of Being: A Cinderella Axiom?" The Professional Animal Scientist 27 (6): 573-83.
Fan, B., S. Onteru, B. Mote, T. Serenius, K. Stalder, and M. Rothschild. 2009. "Large-Scale Association Study for Structural Soundness and Leg Locomotion Traits in the Pig." Genetic Selection Evolution 41: 14-23.
FAO. 2009. The State of Food and Agriculture 2009 ; Livestock in the Balance. Rome, Italy.
Fonseca, Felipe Napolitano da, Jair Minoro Abe, Irenilza de Alencar Nääs, Alexandra Ferreira da Silva Cordeiro, Fábio Vieira do Amaral, and Henry Costa Ungaro. 2020. "Automatic Prediction of Stress in Piglets (Sus Scrofa) Using Infrared Skin Temperature." Computers and Electronics in Agriculture 168 (January 2019): 105148.
Godfray, HCJ, and T Garnett. 2014. "Food Security and Sustainable Intensification." Philosophical Transaction of the Royal Society B 369: 20120273.
Gorczyca, Michael T., Hugo Fernando Maia Milan, Alex Sandro Campos Maia, and Kifle G. Gebremedhin. 2018. "Machine Learning Algorithms to Predict Core, Skin, and Hair-Coat Temperatures of Piglets." Computers and Electronics in Agriculture 151 (March): 286-94.
Grégoire, J., R. Bergeron, S. D'Allaire, M. C. Meunier-Salaün, and N. Devillers. 2013. "Assessment of Lameness in Sows Using Gait, Footprints, Postural Behaviour and Foot Lesion Analysis." Animal 7 (7): 1163-73.
Kashiha, Mohammad Amin, Claudia Bahr, Sanne Ott, Christel P H Moons, Theo A. Niewold, Frank Tuyttens, and Daniel Berckmans. 2014. "Automatic Monitoring of Pig Locomotion Using Image Analysis." Livestock Science 159 (1): 141-48.
Kongsro, Jørgen. 2013. "Development of a Computer Vision System to Monitor Pig Locomotion." Open Journal of Animal Sciences 03 (03): 254-60.
Lind, Nanna M., Michael Vinther, Ralf P. Hemmingsen, and Axel K. Hansen. 2005. "Validation of a Digital Video Tracking System for Recording Pig Locomotor Behaviour." Journal of Neuroscience Methods 143 (2): 123-32.
Lu, M., J. He, C. Chen, C. Okinda, M. Shen, L. Liu, W. Yao, T. Norton, and D. Berckmans. 2018. "An Automatic Ear Base Temperature Extraction Method for Top View Piglet Thermal Image." Computers and Electronics in Agriculture 155: 339-47.
Marchant-forde, Jeremy N. 2011. "Welfare of Sows and Piglets at Farrowing." Swine Welfare Factsheet, 3.
McNeil, B., K. Stalder, J. Calderon Diaz, J. Stock, T. Parsons, D. Beam, and A. Johnson. 2019. "Development of Sow Lameness Classification Trees Using an Embedded Microcomputer-Based Force Plate in a Commercial Setting" 3 (1): 1-6.
Meijer, Ellen, Christian P. Bertholle, Maarten Oosterlinck, Franz J. van der Staay, Willem Back, and Arie van Nes. 2014. "Pressure Mat Analysis of the Longitudinal Development of Pig Locomotion in Growing Pigs after Weaning." BMC Veterinary Research 10 (1): 1-11.
Moshou, D., A. Chedad, A. Van Hirtum, D. De Baerdemaeker, J. Berckmans, and H. Ramon. 2001a. "An Intelligent Alarm for Early Detection of Swine Epidemics Based on Neural Networks." Transactions of the ASAE 44 (1): 167-74.
Moshou, D., A. Chedad, A. Van Hirtum, D. De Baerdemaeker, J. Berckmans, and H. Ramon. 2001b. "Neural Recognition System for Swine Cough." Mathematics and Computers in Simulation 56 (4–5): 475-87.
Mostaço, Gustavo M., Késia O.Da S. Miranda, Isabella C.F.Da S. Condotta, and Douglas D.alessandro Salgado. 2015. "Determination of Piglets' Rectal Temperature and Respiratory Rate through Skin Surface Temperature under Climatic Chamber Conditions." Engenharia Agricola 35 (6): 979-89.
Pessoa, J.C., E.G. Rodrigues da Costa, M. Manzanilla, T. Norton, C. McAloon, and L. Boyle. 2019. "Relationship between Automatic Records of Pig Respiratory Distress on Farm and the Prevalence of Lung Lesions at Slaughter." In Proceedings of the 9th European Conference on Precision Livestock Farming, 518-24. Cork, Ireland.
Pluym, Liesbet M., Dominiek Maes, Jürgen Vangeyte, Koen Mertens, Jeroen Baert, Stephanie Van Weyenberg, Sam Millet, and Annelies Van Nuffel. 2013. "Development of a System for Automatic Measurements of Force and Visual Stance Variables for Objective Lameness Detection in Sows: SowSIS." Biosystems Engineering 116 (1): 64-74.
Rushen, J., N. Chapinal, and A. M. De Passillé. 2012. "Automated Monitoring of Behavioural-Based Animal Welfare Indicators." Animal Welfare 21 (3): 339-50.
Schon, H., and A. G. Meiering. 1987. "Computer-Aided Control Improves Livestock Operations." Agricultural Engineering 68 (7): 15-18.
Swanson, JC. 1995. "Farm Animal Well-Being and Intensive Production Systems." Journal of Animal Science 73: 2744-51.
Vranken, Erik, and Dries Berckmans. 2017. "Precision Livestock Farming for Pigs." Animal Frontiers 7 (1): 32-37.
Wang, Xiaoshuai, Xiaoyang Zhao, Yong He, and Kaiying Wang. 2019. "Cough Sound Analysis to Assess Air Quality in Commercial Weaner Barns." Computers and Electronics in Agriculture 160 (November 2018): 8-13.
Welfare Quality. 2009. "Welfare Quality Assessment Protocol for Pig." Lelystad, The Netherlands.
Wouters, P., R. Geers, G. Parduyns, K. Goossens, B. Truyen, V. Goedseels, and E. Van der Stuyft. 1990. "Image-Analysis Parameters as Inputs for Automatic Environmental Temperature Control in Piglet Houses." Computers and Electronics in Agriculture 5 (3): 233-46.
Subscribe to Our Newsletters
National Hog Farmer is the source for hog production, management and market news

You May Also Like