Validation results of the algorithm for IP100 detection in industrial incubators
In modern livestock production, biosecurity and improved disease monitoring are of great importance to safeguard public and animal health. In addition, citizens expect that farm animals have been reared and killed humanely with minimal environmental impact and that food from animals is safe. These global threats and concerns can be combated through surveillance and research networks for early detection of animal diseases and better scientific cooperation between countries and research teams. The use of information technology (IT) can provide new possibilities for continuous automatic monitoring (Fig. 1) and management of livestock farming, according to multiple objectives.
Surveillance relies on vast streams of data to identify and manage risks. Currently data collection nearly always depends on manual methods. While this might be acceptable in R&D projects, it is unrealistic when solutions are applied on the scale needed on commercial farms. Scoring of some animal-based information by human inspectors by manual methods is often inaccurate, time consuming and expensive when implemented at farm level. It is clear that a multidisciplinary and integrated approach, using modern IT systems, is needed to optimise use of expensive inspectors.
One current advantage provided by technology in livestock production is the development of sensors and sensing technologies to automatically monitor and evaluate data from processes in real-time. Collecting data from livestock and their environment is now possible using innovative, simple, low-cost IT systems; data are then integrated in real time by using knowledge-based computer models .
The initial application of technology in livestock has been the growth of housed pigs and poultry though, in principle, this approach could be applied to any farmed species, including animals farmed extensively . Stockmen routinely gather auditory, olfactory and visual information from their animals to evaluate health, welfare and productivity. New technology can aid this task, even with large flocks or herds, thanks to the (r)evolution in sensors and sensing techniques, e.g. developments in micro- and nano- electronics .
Other sensors include pedometers for monitoring oestrus behaviour in dairy cows . Automatic weighing systems for broilers, laying hens and turkeys have been used for a number of years to estimate the average weight of a flock . Telemetry sensors for measuring heart rate, body temperature and activity have also been developed . Sensors for quantifying milk conductivity and yield of individual cows are available and may be used to optimise production and provide early detection of poor welfare in individuals . The above examples are not exhaustive, but demonstrate the present and future possibilities in monitoring animal disease, welfare and performance.
The last decade a new field of research has appeared in relation to livestock production and animal welfare. Precision Livestock Farming (PLF) has emerged as a tool that uses continuous and automatic techniques in real-time in order to monitor and control/manage animal production, health, welfare and environmental load in livestock production. The first step in PLF is the measurement and interpretation of animal bioresponses. In this direction, sound has been extensively used as an important bioreponse that can provide useful information regarding the status of the animals.
In this chapter, three examples of monitoring animal sounds as a tool to determine animal status are presented, namely chicken embryos, chickens and pigs.
2. Interpretation of chicken embryo sounds
Industrial egg incubators vary in size and capacity from 10.800 to 129.600 eggs, with the larger machines being commercially more attractive to hatchery managers due to the lower investment and operational costs per egg. It has been shown in the relevant literature that the spread of hatch of the eggs in an industrial incubator can be as long as 48h . This has serious implications to the later life of the chicks because for operational reasons access to feed and water is delayed for the early hatchlings.
To study the effect further, techniques for monitoring the hatch window have been developed. For example, monitoring climate variables (e.g. temperature and humidity) along with biological variables (e.g. heart rate) have shown potential as estimators of the hatching process. More specifically  studied the CO2 balance as an indirect measure of thermoregulation. In  heart rate fluctuations were studied and were shown to have specific patterns during the pipping and hatching stages. The resonance frequency of incubating eggs was also linked to hatching and even a predictor of hatching could be made . More recently, it was shown  that magnetic resonance imaging (MRI) can be used to monitor hatching.
The above techniques are valuable tools in a research environment. However, their invasive nature and/or high cost of implementation don’t allow for use in an industrial or commercial setup. To overcome such problems, sound was used to study the hatching process . Sound can be measured non-invasively and a single microphone can acquire information about the complete incubator which makes it attractive for the industry. At the same time, current technology makes it possible to use microphones in different environment at a low cost.
At the same time, research has been conducted in relation to reducing the hatch window (i.e. the time between the first and last chick that hatched) -. However, successful application of many of these techniques requires accurate identification of Internal Pipping (IP – the moment in which the embryo is entering the air cell inside the egg) which is an important milestone in the hatching process. Once this stage has been reached, chicks inside the egg start to vocalise.
To address this problem of identifying the IP stage, an algorithm has been developed where sound is recorded in an industrial incubator , is analysed in real-time using a Digital Signal Processor (DSP) and is able to detect when all the chicks in the incubator have reached the IP stage (i.e. IP100). Despite the fact that the collected sound is coming from the whole incubator, the developed technique is able to isolate the sounds coming from all the eggs and infer information about the embryo state. The algorithm is based on the observation that the frequency content of the embryo sounds during different hatching stages is significantly different . This is visually illustrated in Fig. 2.
2.1. Algorithm description
Although the vocalisations at different stages of the hatching process do show statistically significant differences in terms of the peak frequency, a successful classification algorithm requires a robust feature that will not (or minimally) be affected by other sounds that are acquired by the microphone. To account for this, the peak frequency of a sound is not used directly by the algorithm. From the results of Fig. 2 and by experimentation a ratio of the total energy in the 2-3 and 3-4 kHz frequency bands was able to provide a robust measure that can easily be calibrated as explained below. This difference is visualised in Fig. 3 where the mean spectra of the collected sounds are presented.
The classification of the frequency ratio is based on an adaptive threshold. This threshold reflects the background noise characteristics during a period where IP has not started yet. During the beginning of the sound recording (e.g. Incubation Day 16) when the embryos have not penetrated the air cell yet, the algorithm is defining a baseline. The threshold is then set to 90% lower than this threshold. Once the algorithm output remains below this threshold value for more than 5 minutes continuously, IP100 has been reached an the algorithm is giving a signal. In the training dataset, the algorithm has shown to have an accuracy of ±3.1 hrs in the detection of IP100.
A block diagram description of the algorithm is shown in Fig. 4.
2.2. Validation results
The algorithm was developed and tested using data collected during 12 incubations in an industrial incubator (Petersime, Belgium). The algorithm had an absolute deviation of 3.2 hrs from the actual IP100 point. An example of the output of the algorithm is presented in Fig. 5. As explained in the previous section, the threshold shown in Fig. 5 is automatically defined as 90% of the mean value during the initialisation of the algorithm. This value was chosen after experimentation with the data and allows for short variations of the algorithm output due to non-incubation sounds not to be considered as an alarm.
For the validation, the algorithm was implemented on a DSP (TMS320C6416T by Texas Instruments) using the Real-Time Workshop® of the MATLAB® environment. Once it was giving the signal that IP100 has been reached, a sample of 300 eggs was manually checked for IP. This experimental setup is shown in Fig. 6. In total, 5 experiments were performed during 5 incubations and the results are shown in Table 1.
The results of Table 1 show that IP100 was identify correctly. Although this may seem an inaccurate claim (since the IP count was between 93% and 98%), it is important to note the nature of the validation trial. Once the algorithm is providing a signal, IP is manually checked in the incubator. In the hypothetical case that IP is shown to be 100% (i.e. all embryos have been through the IP stage), it is not certain when this has happened. It is perfectly possible that IP100 has been reached long before the manual count. However, if IP of 98% is manually checked, then this means that almost all the embryos have been in the IP stage and therefore from a practical point of view, it is very close to the actual IP100.
3. Monitoring of vocalisations of chickens
Analysis and interpretation of vocalisations of chickens is a powerful tool when studying the behaviour and welfare. It has been presented in the literature that different types of calls (such as distress or happy calls) can be identified based on their frequency characteristics , . More recently, attempts are made to automatically classify these calls and relate them to animal welfare .
In relation to thermoregulation, chicken vocalisations have been shown to have specific patterns when chicks are exposed to cold stress . Furthermore, vocal solicitation of heat, forms an integral part of the development of the thermoregulatory system of young chickens . Finally, the thermal comfort of chicks has been shown to have links with the amplitude and frequency of calls .
On a social level, chick vocalisations are directly linked to stress and welfare parameters. A dissociation of stress behaviour during social-separation of the chick is mediated by novelty while distress calls are mediated by isolation . Lastly, a method has been developed that could be used for stress monitoring of a flock and is based on multi-parametric sound analysis .
It should be noted that chickens, being living organisms, are Complex, Individually different, Time varying and Dynamic (CITD) . As such, the characteristics of their vocalisations are expected to change with time. This is confirmed by experimental results in which the peak frequency of the chicken vocalisations for the same chicken at 1 day and at 20 days old was estimated to be 3603(±303) Hz and 3441(±289) Hz respectively. This parameters shows to be significantly different between the two groups.
It should be noted that no distinction was made between different types of vocalisations. For example, in  different types of calls (e.g. distress or pleasure calls) were studied and it was shown that there are differences in terms of frequency content. A more detailed analysis is needed in terms of the evolution of the frequency characteristics with age.
4. Pig cough identification for health monitoring
Similar to the effect on humans, respiratory diseases in pigs result in coughing and in a different sound of coughing due to the different response of the respiratory system when contacting different pathogenic agents. In humans, an experienced physician can identify over 100 different respiratory diseases based on the sound timbre . In animals, veterinarians use a similar approach to detect sick animals when they enter a farm. Their initial impression over the herd is based on visual and auditory observation when they collect information about the welfare, health and productive status of the animals. In this direction, pig vocalisations related to pain were studied in , while vocalisation analysis in livestock farms as a measure of welfare has been employed in , .
The frequency characteristics of pig vocalisation have been extensively studied under different conditions . These approaches have been further extended to develop algorithms for automatic classification of pig coughing under commercial farming conditions. For this, both frequency  and time domain  sound analysis techniques have been used. Furthermore, the distinction between dry and productive coughs has been made to further enhance the capabilities of the algorithm. This latter has been studied in detail in  where the energy envelope of a sound was shown to be different in dry and productive cough. The system is therefore able to not only provide information about the number of coughing incidents, but also in relation to the quality of the produced cough.
4.1. Algorithm description
As mentioned above, the objective of the algorithm is to detect productive and non-productive coughs in a commercial piggery. Sound is acquired in the pig house by a single microphone placed in the middle of the compartment at a height of 2 meters above the ground. The overall algorithm is shown in Fig. 7 and each block is subsequently described in more detail.
The first step of the algorithm is to identify individual sounds before using a cough classifier. A procedure that is based on the energy envelope of the sound signal has been described in . Briefly explained, this approach is identifying the parts of the signal with high enough energy that could potentially be cough incidents. An example of this is shown in Fig. 8 for a cough attack (a series of coughing events). It should be noted that each sound is identified as an event for further processing. There is no guarantee that the sound originates from a single animal while overlap of sounds is possible (especially during busy periods of the day).
It can be argued that a such a simple sound extraction algorithm would require accurate calibration of the microphone and would be prone to errors due to large background noise. To tackle this, depending on the situation, noise filters can be included preceding the application of the sound extraction algorithm in order to remove any structured and know background noise. At the same time, an adaptive threshold procedure has also been integrated  that allows for accurate selection of only sounds events without including noise. It was further shown in  that despite the background noise, classification is still possible using this sound extraction method.
In the next instance, the algorithm is applying a classifier in order to identify coughs. At this stage it is not important to determine whether the cough is productive or not. For this, either the approach described in  or the approach described in  can be used. Both methods are based on frequency analysis and exploit the characteristics of the frequency content of the cough sounds in different frequency bands in comparison to other sounds that can occur in a pig house (e.g. screams, grunts, feeding systems, contact with doors, etc.). Table 2 provides an overview of the frequency bands an which of those are used by the two algorithms. It should further be noted that both algorithms have employed fuzzy c-means clustering to reach their results and have identified fixed thresholds for their classifiers.
Once a sound has been identified as a cough, then the distinction between a productive and a non-productive cough has to be made. For this, the algorithms presented in  or  can be used. Both algorithms are based on time-domain characteristics of the coughs. The algorithm presented in  is focusing on the decay of the cough sound. To do so, the cough is described by it energy envelope and subsequently a mathematical model is made for the drop of the amplitude. It was shown that productive coughs have a longer decay (as expressed by the time constant) than dry coughs. This is visualised in Fig. 9. It has been hypothesised that this difference is due to differences in lung plasticity that is changing with the occurrence of a respiratory disease. However, further research is needed to confirm this hypothesis.
An alternative method to classify a cough as productive or not is to use the algorithm described in . In this approach, a third order Auto-Regression (AR) model is used (e.g. ) to estimate the sound signal. This model has the following form:
Where is the value of the signal at sample time k and , and are the 3 model parameters. It was shown that productive coughs can be distinguished from dry coughs by using these three parameters. More specifically, a polyhedron is defined in the space that is subsequently used as a classifier for productive coughs. Alternatively, the centre of the dry cough can be defined and it can be assumed the coughs outside this cluster are productive coughs.
In the literature it was shown  that the vocal tract can act as a first order filter that has the form:
Where is the time-shift operator (i.e. ) and is the input to the system. Similarly, (1) can be re-written to have the form:
Where is white noise.
Since coughing can be considered involuntary in the studied cases, white noise can be considered the input to the system. From the above it can be hypothesised that the classifier was able to identify and exploit some higher order dynamics of the effect of the vocal tract on the produced sound response. Of course this claim has to be studied further.
During the calibration phase of the algorithm, the centre of the dry cough cluster has to be defined. For this, the first five dry coughs need to be identified and the average of their parameters should be used as the centre of the productive cough cluster (the edges of the cluster are defined by the variance of the parameters). It can be assumed that at the beginning of the growing period there is no respiratory disease present and therefore only dry coughs are present. So, the first five coughs that will be introduced are dry coughs and can be used to define the dry cough cluster.
4.2. Validation results
The algorithm has been applied on a continuous recording with a total of 671 sounds (291 productive coughs, 231 dry coughs and 149 other sounds) collected under laboratory conditions.
The following Table 3 shows the results of the classification power of the algorithm.
The above algorithm has been integrated in a commercial system by SoundTalks nv. (Belgium – www.soundtalks.be).
This chapter has presented three cases where sound has been used to identify and interpret animal vocalisations. The studied cases are focused on identifying the status of animals in livestock production that will allow the caretaker of the animals to quickly identify health, welfare and production issues and take action. On the positive side, sound can be acquired from a large space and without any contact with the animal. This latter is an important factor in the potential for such technology to be applied in practice. Issues such as cost for placement, loss of sensors due to misuse by the animals and acquisition of sensor at the slaughter line are immediately solved. On the negative side though, the acquired sound signal cannot immediately be linked to a specific animal and it is the combination of all sounds and vocalisations in the area. As such, conclusions about a group of animals can be reached but not necessarily for individual ones.
Sound analysis is an excellent show case for the merits of Precision Livestock Farming (PLF) and can already demonstrate the benefit that PLF can have on intensive livestock production. Further research in the field should focus on identifying critical areas for livestock productions and work towards providing automatic tools for early diagnosis. In order for practical implementation, issues that are not related to animal vocalisations will also have to be dealt with. These include, but are not limited to room acoustics, positioning of the microphones for better sound acquisition, identification of vocalisations in a noisy environment, etc.
In the direction of implementation of PLF systems, an EU project (EU-PLF, project number 311825) is currently running with the objective of creating a Blueprint that describes the process of starting from a scientific idea, development of a commercial prototype, implementing a system on farm and creating value for the farmer. In this framework, the results that have been presented in section 4 of this chapter will be applied in a practical setting.
AcknowledgmentsWe would like to thank the European Union, the IWT (agentschap voor Innovatie door Wetenschap en Technologie), the KU Leuven and Petersime nv. for funding parts of the research described in this chapter. We would also like to thank all the researchers and technicians involved in the research throughout the years.
Precision Livestock Farming- Preface. Computers and Electronics in Agriculture Berckmans D 2008
An overview of integrated management systems for sustainable livestock production. In: Wathes C.M., Frost A.R., Gordon F., Wood J.D. (eds.) Edinburgh, British Society of Animal Science. Occasional Publication Frost A. R 28 2001 45 50
A review of livestock monitoring and the need for integrated systems. Computers and Electronics in Agriculture Frost A Schofield C Beaulah S Mottram T Lines J Wathes C 1997 17 2 139 159
Automatic on-line monitoring of animals by precision livestock farming. In: ISAH conference “Animal production in Europe : The way forward in a changing world, Berckmans D 1October 2004, Saint-Malo, France, 2004 27 31
Safer oestrus detection with sensor aided ALT-pedometer. In: Book of Abstracts of the Third International Workshop on Smart Sensors in Livestock Monitoring, 10-11 September 2004, Leuven, Belgium, Brehme U Stollberg E Holz R Schleusener T 2004 43 46
Estimation of average body weight of broilers using automatic weighing in combination with image analysis. In: book of abstracts of the Third International Workshop on Smart Sensors in Livestock Monitoring, 10-11 September Vranken E Chedad A Aerts J-M Berckmans D 2004Leuven, Belgium, 2004, 68 70
The effects of blindfolding on behavior and heart rate in beef cattle during restraint. Applied Animal Behaviour Science Mitchell K. D Stookey J. M Laturnas D. K Watts J. M Haley D. B Huyde T 2004
Quarter-related measurements of milking and milk parameters in an AMS-herd. Milk Science International Kohler S. D Kaufmann O 2003 58 3 6
Effects of age of broiler breeders, incubation egg storage duration and turning during incubation on embryo physiology and broiler production parameters. PhD Thesis. KU Leuven, Tona K 2003
Importance of prenatal temperature experience on development of the thermoregulatory constrol system in birds. Thermochimica Acta Nickelmann M 2004
Continuous measurements of instantaneous heart rate and its fluctuations before and after hatching in chickens. Journal of Experimental Biology Moriya K Pearson J. T Burggren W. W Ar A Tazawa H 2000 203 5 895 903
Vibration analysis on incubating eggs and its relation to embryonic development. Biotechnology Progress Kemps B De Ketelaere B Bamelis F Decuypere E De Baerdemaeker J 2003 19 3 1022 1025
Noninvasive monitoring of chick development in ovo using 7T MRI system from day 12 of incubation through to hatching. Journal of Magnetic Resonance Imaging Bain M Fagan A Mullin M Mcnaught I Mclean J Condon B 2007 26 1 198 201
An automatic monitoring of the hatching process based on the noise of the hatching chicks. Poultry Science Bamelis F Kemps B Mertens K De Ketelaere B Decuypere E Debaerdemaeker J 2005 84 1101 1107
Quantification and control of the spatiotemporal gradients of air speed and air temperature in an incubator. Poultry Science Van Brecht A Aerts J. M Degraeve P Berckmans D 2003 82 1677 1687
Embryonic developmental plasticity of the chick: Increased CO2 during early stages of incubation changes the developmental trajectories during prenatal and postnatal growth. Comparative Biochemistry and Physiology a-Molecular & Integrative Physiology De Smit L Bruggeman V Tona J. K Debonne M Onagbesan O Arckens L De Baerdemaeker J Decuypere E 2006 145 166 175
Metabolic response to cooling temperatures in chicken embryos and hatchlings after cold incubation. Comparative Biochemistry and Physiology a-Molecular & Integrative Physiology Mortola J. P 2006 145 441 448
Real-time analysis of chicken embryo sounds to monitor different incubation stages. Computers and Electronics in Agriculture Exadaktylos V Silva M Berckmans D 2011 75 321 326
Vocalisation in chicks (Galus galus dom.) during stepwise social isolation. Applied Animal Behaviour Science Marx G Leppet J Ellendorff F 2001 75 1 61 74
Non-invasive quantification of stress in the laying hen: a vocalization analysis approach. Mededelingen Faculteit Landbouwkundige en Toegepaste Biologische Wetenshcapen Universiteit Gent Ghesquire K Van Hirtum A Buyse J Berckmans D 2002 67 4 55 58
Using vocalization pattern to assess broiler’s well-being. In: Lokhorst K., Berckmans D. (eds.) Precision Livestock Farming’ Pereira E. M Naas I. A Jacob F. C 11 11 14July 2011, Prague, Czech Republic; 2011
The development of vocal thermoregulatory response to temperature in embryos of the domestic chicken. Wilson Bulletin Bugden S. C Evans R. M 1999 111 2 188 194
Vocal solicitation of heat as an integral component of the developing thermoregulatory system in young domestic chickens. Canadian journal of Zoology Bugden S. C Evans R. M 1997 75 12 1949 1954
Noise analysis to evaluate chick thermal comfort. Scientia Agricola De Moura J Naas I Alves E Crvalho T Vale M Lima K 2008
Dissociation of stress behaviors in the chick social-separation-stress procedure. Physiology & behavior Feltenstein M Ford N Freeman K Sufka K 2002 75 5 675 679
Development of multi parametric sound analysis parameters as welfare indicator in chicken flocks. Proceedings of the international seminar on modal analysis Mair J Marx G Petersen J Mennicken L 2001 3 1523 1528
Methods for Monitoring Individual Bioresponses in Relation to Health Management. In: Smigorski K (ed.) health Management- Different Approaches and Solutions. Rijeka: InTech; Exadaktylos V Berckmans D Aerts J M Non-invasive 2011 143 160
Analysis of the cough sound: an overview. Puylmomnary Pharmacology Korpáš I Sadlonová J Vrabec M 1996 9 56 261 368
Analysis of pain-related vocalization in young pigs. Journal of Sound and Vibration Marx G Horn T Thielebein J Knubel B Von Borell E 2003 266 3 678 698
C. Vocalization of farm animals as a measure of welfare. Applied Animal Behaviour Science Manteuffel G Puppe B Schön P 2004
G. Automated recording of stress vocalisation as a tool to document impaired welfare n pigs. Animal Welfare Schön P C Puppe B Manteuffel 2004 13 2 105 110
G. Linear prediction coding analysis and self-organizing feature map as tools to classify stress calls of domestic pigs (Sus scrofa). Journal of the Acoustical Society of America Schön P C Puppe B Manteuffel 2001 110 1425 1431
Analysis of pain-related vocalisation in young pigs, Journal of Sound and Vibration Marx G Horn T Thielebein J Knubel B Von Borell E 2003 266 687 698
Fuzzy approach for improved recognition of citric acid induced piglet coughing from continuous registration. Journal of Sound and Vibration Van Hirtum A Berckmans D 2003 266 3 677 686
recognition of sick ppig cough sounds. Computers and Electronics in Agriculture Exadaktylos V Silva M Aerts J M Taylor C. J Berckmans D Real-time 2008 63 207 214
analysis for online recognition and localization of sick pig (Sus scrofa) cough sounds. Journal of the Acoustical Society of America Exadaktylos V Silva M Ferrari S Guarino M Taylor C. J Aerts J M Taylor C. J Berckmans D Time-series 2008 124 6 3803 3809
D. The influence of respiratory disease on the energy envelope dynamics of pig cough sounds. Computers and Electronics in Agriculture Silva M Exadaktylos V Ferrari S Guarino M Aerts J M Berckmans 2009 69 1 80 85
Recursive Estimation oand Time-Series Analysis- An Introduction for the Student and Practitioner. Berlin: Springer; Young P. C 2011
Modelling Dynamic Biological Systems. New York: Springer, Hannon B Mathias R 1997