Artificial intelligence (AI) can be considered an umbrella term for any system that can analyse vast amounts of data, learn from the information provided and make outcome predictions. AI is not a new concept in dairy herd health monitoring; for example, many sensor technologies use AI to process data on rumination, activity and temperature in real-time and provide health alerts or heat probability (Neethirajan, 2023) to the herd manager on a simple online dashboard. Computer vision is a form of AI that uses algorithms to ‘teach’ a computer model to recognise cattle images and video footage (Tassinari et al, 2021). This can then perform a multitude of tasks normally conducted by humans, such as identifying individual animals from their morphological appearance and recognising key anatomical landmarks that can attribute values for outputs such as body condition and mobility score. As well as identification of individual animals, computer vision models can be trained to recognise different behaviours of cows in a cubicle or free-housed system and generate time budgets for standing, lying down perching and feeding behaviours (Yu et al, 2022), to give producers and their advisors objective long-term data on cow behaviour and identify management factors that may be contributing to poor performance in a herd.
This article summarises some of the different applications of computer vision-based monitoring systems currently used on commercial dairy herds, specifically focusing on body condition scoring, mobility and behaviour monitoring. It will discuss the opportunities they present to the practising farm veterinarian and the limitations that published work has identified with their implementation.
Body condition scoring
Body condition scoring is a tool which estimates a dairy cow's body reserves (Ferguson et al, 1994). A body condition score (BCS) which falls outside the recommended ranges can have negative health and production outcomes, such as decreased milk production and reproductive performance in underconditioned cows (Roche et al, 2009; 2013) and an increased risk of metabolic disorders in over-conditioned postpartum cows (Roche et al, 2009). Despite the large body of work surrounding body condition scoring, implementation and use of the data in commercial settings is variable, with a UK survey finding 75.8% of farmers using body condition scoring as a method of monitoring metabolic disease (Donadeu et al, 2020). The labour involved in routinely evaluating every cow's BCS at strategic points and processing the data required are common barriers to implementing strategic body condition scoring on dairy farms.
This area presents an opportunity for automation and AI to enhance the monitoring and processing of BCS data, allowing for more targeted interventions to improve the health and productivity of dairy cows. Several systems have already been developed using computer vision technology, typically featuring a mounted video camera above the exit of the milking parlour. These systems use trained algorithms to make predictions about individual cows’ BCS. This routine, daily monitoring of dairy cows offers significant opportunities for proactive herd health monitoring and the implementation of tailored action plans for individual cows. Excessive loss of BCS in early lactation can profoundly affect health, reproduction and milk production (Stevenson and Atanasov, 2022). Many automated systems currently in use on dairy farms use a more precise scale than the typical 0.25 scale used in most manual scoring methods and smaller changes in BCS that may not be easily detectable by a manual scorer, have been shown to correlate with reproductive success when daily changes in BCS were monitored through the DeLaval BCS system (Pinedo et al, 2022).
Despite the promise of computer vision-based approaches to monitoring dairy cows’ BCS, practitioners should exercise caution with herds that already have these automated systems in place. Three such systems, CattleEye (Cattle Eye, Belfast, UK), DeLaval BCS (DeLaval International) and HerdVision (Agsenze Ltd, Lancaster, UK), have been evaluated in studies (Mullins et al, 2019; Angel and Mahendran, 2024; Siachos et al, 2024). These studies found that automatically generated BCS typically overestimates the condition of under-conditioned cows, with the inverse being true of over-conditioned cows.. With these cows being the most at risk of negative health and production outcomes, currently, the clinical application of these systems is currently limited. The HerdVision system was also found to have a poorer agreement with manual scorers for Jersey cows than Holsteins (Angel and Mahendran, 2024). Presumably, this relates to the algorithm being trained on Holstein-type animals and with Jersey animals having a smaller skeletal frame, the automated system's performance is understandably poorer when assessing animals; the algorithm may not have received sufficient training. This emphasises the point that the output of computer vision-based systems relies on the quality of the data and images used to train them, and proper due diligence testing of the systems in different settings, on different populations, should be carried out before the data they produce can be trusted to inform decision making fully.
However, as these automated systems can be improved by further training and refinements to the algorithms they use without having to make changes to the physical hardware itself, these current limitations can be addressed, opening the door to tailored health and reproductive management measures for individuals experiencing varying degrees of BCS change. In the meantime, until more work is published on this topic demonstrating a better agreement in BCS for at-risk cows, practitioners should continue to use manual methods of BCS monitoring alongside the computer vision-based systems, familiarising themselves with the technology and the strengths and limitations of the data that they make available to them.
Lameness detection
The impact of lameness in dairy farms is well-researched and documented. However, prevalence estimates have shown very little change since the 1980s (Thomsen et al, 2023). Different mobility scoring systems are used across studies and in commercial settings. Still, in the UK, the industry standard is the four-point scoring system described by the Agriculture and Horticulture Development Board. While this may be a useful tool to assess herd lameness levels, it has several limitations. Similar to body condition scoring, mobility scoring is time-consuming and highly subjective, with agreement between even the same assessor shown to have been variable (Garcia et al, 2015). This system also has practical limitations, whereby it is highly prone to human error, with whole herds frequently being scored by one assessor, who has only seconds to identify and assess an animal and record the information before moving on to the next cow. As well as the practical issues, mobility scoring systems such as this often miss individual animals with painful foot lesions, with the sensitivity of visual mobility scoring for the detection of any foot lesion calculated to be as low as 0.18 in one study on pasture-based dairy cows in Ireland (Logan et al, 2024). Early identification of lameness cases and prompt treatment are important aspects of maintaining low lameness levels in dairy herds (Leach et al, 2012; Groenevelt et al, 2014). Therefore, the use of visual mobility scoring systems may be limited in their impact on reducing herd lameness levels.
Automated lameness detection using computer vision has been developed and researched relatively extensively and is summarised well by Kang et al (2021). There are systems which commercially available and already used on UK dairy farms. These systems typically use low-cost cameras mounted above the parlour exit that record video clips of individual cows. The algorithms used can then recognise the individual animal (from a combination of coat colour, head shape and integration with electronic identification systems) and assign a lameness score by assessing either changes in position or movement of the feet or limbs of cows, or the changes in position and movement of multiple anatomical landmarks (Siachos et al, 2024). Clearly, the potential advantages of such systems over visual mobility scoring include the objectivity and consistency of scoring and providing daily information and trends on herd and individual animal lameness status.
One system, Cattle Eye (CattleEye Ltd, Belfast, United Kingdom), has been validated in a UK study by Anagnostopoulos et al (2023) by comparing its performance to human-generated visual scores, known as ground-truthing. In this study, the system generated comparable scores to two experience scorers but was more sensitive than the human scorer for lesion detection.
The Cattle Eye system uses a 0–100 scale instead of a four-point scale used by human visual scoring. With the daily monitoring this system provides, the more precise scale could allow for the identification of lame animals in pre-clinical stages and appropriate intervention to prevent the animals from becoming more obviously lame. The author's experience with this system on one dairy herd has seen it implemented alongside other management factors, resulting in a successful reduction in lameness levels, but has found that integration of the data with other farm records, such as treatment and foot trimming records, to be a barrier to it maximising its potential. As these systems continue to develop and become more commonplace, one anticipates such issues will be straightforward to overcome.
Other limitations of similar automated lameness detection systems are frequently cited as limitations of artificial intelligence systems. The validation of such systems, like that performed by Anagnostopoulos et al (2023), is achieved by comparing results obtained with the current reference standard; in this case, visual mobility scoring. These reference values will influence the automated system's performance results (Afonso et al, 2020). How these systems recognise limb, foot or anatomical landmark positioning is also a potential limitation of these systems, as some hoof lesions will not always affect this, particularly digital dermatitis (Afonso et al, 2020). To this end, more work is being performed to train computer models to detect digital dermatitis lesions. Low-cost cameras have been fitted on footbaths or in rotary and robotic milking to capture foot images that are then processed by an algorithm to generate a Digital Dermatitis score after being trained using lesion images labelled by trained investigators (Aravamuthan et al, 2024). Aravamuthan et al (2024) investigated, the ability of several different computer models to perform real-time detection of digital dermatitis lesions was encouraging, with the top performing model (Tiny YOLOv4) achieving speeds of 333 frames per second. Most models performed remarkably well compared to the ground truth, with a mean average precision between 0.964 and 0.998.
Although practical issues on a farm may arise (eg obstruction of camera lenses or the lesions themselves with faeces), there are solutions available. These include automated wipers on cameras and appropriate positioning of the hardware to ensure the feet are as clean as possible when passing (post footbathing). When practical issues are adjusted for, systems like this have the potential to revolutionise the detection of digital dermatitis lesions.
Behaviour monitoring
As well as identification of physical attributes such as body condition and mobility score, computer vision technology has been and is being used on dairy farms to monitor cow behaviour. Tassinari et al (2021) trained a computer vision system to detect individual cows within a free-stall barn, tracking their movements and behaviour that has also been investigated in other studies. Yu et al (2022) successfully… successfully trained deep learning algorithms to recognise the characteristics of feeding behaviour. Monitoring feeding time, including the availability and access to rations, is critical for maximising dry matter intake (Bach et al, 2008; Miller-Cushon and DeVries, 2017). Computer vision systems can identify peaks in feeding behaviour, ensuring that feed delivery and management are implemented efficiently on the farm. Recently launched behaviour monitoring systems include the Lely Zeta (Lely Industries NV, Maassluis, Netherlands) barn and calving monitoring system and Vet Vision AI (Vet Vision AI, Nottingham, UK). The author's experience with the latter has included assessment and comparison of cow comfort across different environments, troubleshooting poor performance and increased lameness prevalence, identifying reduced time lying down and increased perching behaviour (standing in a cubicle rather than lying down) as risk factors and areas to address on the farm. The ability of these systems to monitor space usage within a shed can help identify several environmental and management issues, for example, unfavourable cubicles or lying areas leading to reduced time lying down and increased standing, excessive crowding around water troughs in periods of heat stress and increased time spent out of a pen for milking. Computer vision can quantify the time dairy cows spend performing these behaviours, allowing early identification of adverse alterations to their time budgets that can negatively influence health and production (Krawczel et al, 2012; Tucker et al, 2021). The benefit of a computer vision system for monitoring these behaviours is the continuous nature and objectivity they provide, where behaviours are not influenced by manual observers being present and the variability of the behaviours over different time periods can be identified that is not easily quantifiable using human visual observation.
Computer vision technologies are becoming more commonplace in commercial dairy herds. Current commercial systems have the ability to recognise individual animals through a combination of coat pattern recognition and link with electronic identification as cows exit the milking parlour. They can then assign a body condition and mobility score to each cow. This has many benefits, including increased monitoring and data availability, allowing for earlier detection of cows at greater risk of poor health and performance. In the case of body condition scoring, evidence suggests that this dynamic monitoring over a more precise scale can accurately predict those likely to have poor reproductive performance (Pinedo et al, 2022). To a similar degree with mobility scoring, lame animals can be identified for earlier intervention to reduce the long-term negative impacts of lameness. However, these systems are not without limitations and practitioners should exercise care as they are not a direct replacement for manual scoring. For example, the poor agreement demonstrated in multiple studies with automated body condition scoring systems and manual scoring, particularly for cows outside of what is considered ‘normal’ (Mullins et al, 2019; Angel and Mahendran, 2024; Siachos et al, 2024), limits their application with identifying a problem cow at a specific time point, such as an over-conditioned cow at drying off. Rather, they should be used dynamically; for example, monitoring the change in BCS in early lactation and practitioners working with farms with these systems in place should familiarise themselves with the data provided and the scales they use before incorporating them into their routine health management. Behaviour monitoring with computer vision, both on an individual and group level, has the potential to identify management factors that can be addressed to improve the welfare and productivity of dairy cows, as well as identify cows demonstrating abnormal behaviour that may be a disease indicator.
Conclusions
This article summarises only some of the current applications of computer vision technologies on dairy farms that have the potential to enhance the involvement of the practicing farm vet in herd health monitoring. Practitioners should be aware of their limitations and willing to scrutinise the data provided by these systems in herds under their care, but they should equally embrace the opportunity to use these insights that conventional methods cannot so easily provide.