Classifying active and inactive states of growing rabbits from accelerometer data using machine learning algorithms
Résumé
Using wearable accelerometers is gaining traction in research and animal production management for monitoring animal behaviour. In this study, the objective was to automatically detect rabbit activity/inactivity states from accelerometer data in growing rabbits. For that purpose, 16 animals were equipped with an accelerometer and filmed for 2 weeks. A total of 10 h of video across all the rabbits were annotated manually using the Boris software, identifying 6 classes of different behaviours: lying, eating, moving, grooming, walking and drinking which were grouped into two classes: active and inactive. Accelerometer signal and video annotations were manually synchronized. The static and dynamic components of the signal were isolated by applying a low-pass and high-pass filter and 4 additional time series were derived from these components. The signal was segmented into time windows of different sizes: 1, 3, 5, 7 and 9 s. For each window, a total of 41 features were extracted in the time and frequency domain. Different subsets of data containing an increasing number (from 5 to 25 in steps of 5) of the most informative features identified with random forest (RF) were used to train a binary classification model (inactive as a positive class). The classification performance of RF, support vector machine (SVM) and gradient boosting (GB) was evaluated. A nested cross-validation (CV) with an outer Leave-One-Animal Out CV and an inner threefold CV for hyperparameter tunning was implemented. The same resampling was implemented for each window size and each classifier so that the models were evaluated with the same data sets. The performance was evaluated on the test datasets using different metrics: precision, recall, F1 score and accuracy. Results showed that the classifiers perform very similarly. With the best configuration (window size of 9 s and with the 5 most important features) the RF model reaches a median precision of 1 (Q1=0.99, Q3=1) and a median recall of 0.93 (Q1=0.89, Q3=0.97). These results showed that the model is highly reliable in correctly classifying positive instances. Additionally, achieving a recall of 0.93 emphasizes the model's effectiveness in capturing a substantial portion of positive instances. Accelerometers combined with machine learning models therefore hold great promise for monitoring rabbit activity and for a range of applications in animal science and behaviours.
Fichier principal
classifying_states_rabbits_accelerometer_without_lines_with_figures (1).pdf (1.2 Mo)
Télécharger le fichier
Origine | Fichiers produits par l'(les) auteur(s) |
---|