Automatic Assessing Body Condition Score from Digital Images by Active Shape Model and Multiple Regression Technique

Body Condition Score (BCS) of a dairy cow is a magnificent indicator for determining energy reserves of cows. The purpose of this study is to assess BCS of dairy cattle by analyzing cows’ rear-view images. In order to do so, we first model shape of cow’s tailhead area by using active shape model. Then, angle features are modelled as multiple regression model for estimating scores. The experimental results show that proposed system is promising compared to some existing methods.


Introduction
Most of the existing methods for measuring Body Condition Scores of dairy cows have been based on a subjective assessment of tissue reserves of lactating dairy cows. 1 BCS is widely considered as an important factor for management of dairy cattle due to its simplicity and repeatability. Moreover, it can evaluate body fat stores and estimate cumulative energy balance through visual or tactile inspection. 2 Svaluation of BCS is important for analyzing health problems, feed intake, and optimal time interval between calving and first insemination. For cattle, sheep and goats, the scoring systems most commonly used for BCS are numerical scales with 5-point, 6-point, 8-point or 10-point scales. For dairy cows, the BCS is normally a number in a scale that spans from 1 to 5 (0.25 increments) or from 1 to 9 (1 increment). Generally, the score range used by dairy management advisors describes thin animals with receiving lower scores and fat animals with receiving higher scores (1 represents emaciated cows, 5 represents obese cows for a 5-point system). For a certain management of farms, the BCS should be assessed. However, this task is time consuming and observed experts need considerable training and experience. Roii et al. stated 3 that automatic and objective BCS will help to ensure that the cow is in the correct condition for each stage of her annual cycle and correct any deficiencies with appropriate dietary changes. The aim of the proposed research is to develop a system that models the body shape of a cow from the back view images and then assesses the BCS with observed angle features in score estimation. The rest of the paper is organized as follows: section 2 introduces some related works on approximations for automatic body condition scoring system, section 3 describes system overview with theoretical methods that are mainly applied in this research, section 4 explains how the experiments performed with output results, and finally in section 5, the conclusions and future works are described.

Some Related Works
Among the many attempts for estimating body condition scores automatically, the first attempt by Coffey et al., tested 4 using line patterns painted with laser light over the tailhead area of the cows. Some attempts apply digital images or some system used videos and an analysis of the cow's contour and shape that commonly involved. Roii et al., have taken 3 3D images from the above view view of the cow acquisition of data automatically. Halachmi et al., have also taken 5 thermal images and they made decision that fatter cow's shape are rounder. Bewley et al., use 6 top view images, 23 points and 15 angles are extracted and show a good correlation with their expected score. Bercovich et al., also used 7 the above view images and they use Fourier descriptors method and regression method for the cow signature showing that body condition score can be automatically extracted from those images. Rafel et al. used 8 twenty-two angle features from the rear view images with the classifiers from Weka tool and they showed that their estimation is possibly comparable with difference of two human experts. Nevertheless, currently most dairy farms don't pay so much attention on automatic estimation of BCS in their dairy management. This is because some systems need to preprocess like laser paint or some systems need to install some kind of high cost camera like 3D camera, 3D Kinect camera, thermal camera despite their usefulness. Some commercial application like DeLaval-2015 has appeared, but its accuracy was not published in a scientific publication in the statement 3 . So, this study will build the BCS estimation system of using simple 2D images by expressing observed accuracy.

System Overview
The proposed system for assessing BCS from digital images contains three main components. The preprocessing of the images, the segmentation of the shape and the estimation of the BCS as depicted in fig 1.

Preprocessing
The images for this study were collected from the web. We choose the back shape view of cow images because

Segmentation of the back shape of the cow
Once we have the preprocessed cows' back view images, we need to extract the computationally manageable representation of the anatomy of the back shape of cows. A computer program written with Matlab 2015a was used in annotating of cow images from the dataset. Twentyfive anatomical points are identified. Those anatomical points according to recognizable features can influence the important information for representation of the shape. Those anatomical points with their description are depicted in the figure 1. The shapes are then aligned to endure the pose (scaling, rotation and resizing). Angles are measured according to law of cosine method using three points. There are five angles totally computed, two angles around the left and right hooks and two angles around the tailhead depression area and one angle at the peak of the tailhead as shown in figure 2.

Analysis by Regression Method
By using those angle features, we compute the regression coefficients in estimation of BCS. The multiple regression method is computed with the equation as follows: BCSi = b0+ b1Ang1+b2Ang2+b3Ang3+ b4Ang4+b5Ang5 (1) where BCSi is the BCS of the i th cow, Ang1 and Ang5 are the left and right hook angles, Ang2 and Ang4 are the left and right tailhead depression angles, and Ang3 is the tailhead peak angle respectively. And b0 is the constant or intercept and b1, b2, b3, b4 and b5 are the slope (coefficients) of the three angles respectively. We computed the angles in radian rather than degrees to reduce the variation among values.

Experiments and Results
After analyzing those angle features using regression method, the computed regression coefficient and the predicted BCS values are shown in Table 1. In the experiment, we take threshold to those angle values by rounding the point value and then observed that the predicted BCS values are close and some even identical to the estimated BCS as in shown in figure 3. The residual values (which is the difference between predicted values and already estimated values) are 0, 0.5 and 1.
Out of seventy images, twenty-four images have zero difference, thirty-four images have 0.5 difference and eleven images have 1 difference. We assumed the 0.5 difference is feasible because even the difference between the trained experts can have 0.5 difference in estimating the BCS. Thus, the accuracy for this experiment is 83% which is acceptable to estimate. We also computed the correlation between each angle feature with their respective BCS value as shown in Table 2(c) and we find that all these angle features have the positive correlation with the BCS. This means that if those angle have the higher value (wider angle) the BCS value is the higher value. This assumption agrees with the wider Fig. 2. Five Angle features from the shape of the cow.

Conclusion
In this paper, we used the back view images of cows in estimation of BCS. The BCS of the cows are estimated using the 5 point scale. Experimental results showed that this method is effective in assessing the BCS of the cow as the predicted scores are closed to the actual scores. Moreover, our experiment also hold the same impression with the assumption of the rounder shape have the higher scores. In the future, a more robust method for extraction of shape and a dataset of back view cow images useful for cattle management will be addressed.