Cargando…

Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods

Automated monitoring of pigs for timely detection of changes in behavior and the onset of tail biting might enable farmers to take immediate management actions, and thus decrease health and welfare issues on-farm. Our goal was to develop computer vision-based methods to detect tail biting in pigs us...

Descripción completa

Detalles Bibliográficos
Autores principales: Hakansson, Franziska, Jensen, Dan Børge
Formato: Online Artículo Texto
Lenguaje:English
Publicado: Frontiers Media S.A. 2023
Materias:
Acceso en línea:https://www.ncbi.nlm.nih.gov/pmc/articles/PMC9879576/
https://www.ncbi.nlm.nih.gov/pubmed/36713870
http://dx.doi.org/10.3389/fvets.2022.1099347
_version_ 1784878722177826816
author Hakansson, Franziska
Jensen, Dan Børge
author_facet Hakansson, Franziska
Jensen, Dan Børge
author_sort Hakansson, Franziska
collection PubMed
description Automated monitoring of pigs for timely detection of changes in behavior and the onset of tail biting might enable farmers to take immediate management actions, and thus decrease health and welfare issues on-farm. Our goal was to develop computer vision-based methods to detect tail biting in pigs using a convolutional neural network (CNN) to extract spatial information, combined with secondary networks accounting for temporal information. Two secondary frameworks were utilized, being a long short-term memory (LSTM) network applied to sequences of image features (CNN-LSTM), and a CNN applied to image representations of sequences (CNN-CNN). To achieve our goal, this study aimed to answer the following questions: (a) Can the methods detect tail biting from video recordings of entire pens? (b) Can we utilize principal component analyses (PCA) to reduce the dimensionality of the feature vector and only use relevant principal components (PC)? (c) Is there potential to increase performance in optimizing the threshold for class separation of the predicted probabilities of the outcome? (d) What is the performance of the methods with respect to each other? The study utilized one-hour video recordings of 10 pens with pigs prior to weaning, containing a total of 208 tail-biting events of varying lengths. The pre-trained VGG-16 was used to extract spatial features from the data, which were subsequently pre-processed and divided into train/test sets before input to the LSTM/CNN. The performance of the methods regarding data pre-processing and model building was systematically compared using cross-validation. Final models were run with optimal settings and evaluated on an independent test-set. The proposed methods detected tail biting with a major-mean accuracy (MMA) of 71.3 and 64.7% for the CNN-LSTM and the CNN-CNN network, respectively. Applying PCA and using a limited number of PCs significantly increased the performance of both methods, while optimizing the threshold for class separation did result in a consistent but not significant increase of the performance. Both methods can detect tail biting from video data, but the CNN-LSTM was superior in generalizing when evaluated on new data, i.e., data not used for training the models, compared to the CNN-CNN method.
format Online
Article
Text
id pubmed-9879576
institution National Center for Biotechnology Information
language English
publishDate 2023
publisher Frontiers Media S.A.
record_format MEDLINE/PubMed
spelling pubmed-98795762023-01-27 Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods Hakansson, Franziska Jensen, Dan Børge Front Vet Sci Veterinary Science Automated monitoring of pigs for timely detection of changes in behavior and the onset of tail biting might enable farmers to take immediate management actions, and thus decrease health and welfare issues on-farm. Our goal was to develop computer vision-based methods to detect tail biting in pigs using a convolutional neural network (CNN) to extract spatial information, combined with secondary networks accounting for temporal information. Two secondary frameworks were utilized, being a long short-term memory (LSTM) network applied to sequences of image features (CNN-LSTM), and a CNN applied to image representations of sequences (CNN-CNN). To achieve our goal, this study aimed to answer the following questions: (a) Can the methods detect tail biting from video recordings of entire pens? (b) Can we utilize principal component analyses (PCA) to reduce the dimensionality of the feature vector and only use relevant principal components (PC)? (c) Is there potential to increase performance in optimizing the threshold for class separation of the predicted probabilities of the outcome? (d) What is the performance of the methods with respect to each other? The study utilized one-hour video recordings of 10 pens with pigs prior to weaning, containing a total of 208 tail-biting events of varying lengths. The pre-trained VGG-16 was used to extract spatial features from the data, which were subsequently pre-processed and divided into train/test sets before input to the LSTM/CNN. The performance of the methods regarding data pre-processing and model building was systematically compared using cross-validation. Final models were run with optimal settings and evaluated on an independent test-set. The proposed methods detected tail biting with a major-mean accuracy (MMA) of 71.3 and 64.7% for the CNN-LSTM and the CNN-CNN network, respectively. Applying PCA and using a limited number of PCs significantly increased the performance of both methods, while optimizing the threshold for class separation did result in a consistent but not significant increase of the performance. Both methods can detect tail biting from video data, but the CNN-LSTM was superior in generalizing when evaluated on new data, i.e., data not used for training the models, compared to the CNN-CNN method. Frontiers Media S.A. 2023-01-11 /pmc/articles/PMC9879576/ /pubmed/36713870 http://dx.doi.org/10.3389/fvets.2022.1099347 Text en Copyright © 2023 Hakansson and Jensen. https://creativecommons.org/licenses/by/4.0/This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) and the copyright owner(s) are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.
spellingShingle Veterinary Science
Hakansson, Franziska
Jensen, Dan Børge
Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title_full Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title_fullStr Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title_full_unstemmed Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title_short Automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
title_sort automatic monitoring and detection of tail-biting behavior in groups of pigs using video-based deep learning methods
topic Veterinary Science
url https://www.ncbi.nlm.nih.gov/pmc/articles/PMC9879576/
https://www.ncbi.nlm.nih.gov/pubmed/36713870
http://dx.doi.org/10.3389/fvets.2022.1099347
work_keys_str_mv AT hakanssonfranziska automaticmonitoringanddetectionoftailbitingbehavioringroupsofpigsusingvideobaseddeeplearningmethods
AT jensendanbørge automaticmonitoringanddetectionoftailbitingbehavioringroupsofpigsusingvideobaseddeeplearningmethods