{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,6,12]],"date-time":"2026-06-12T07:08:26Z","timestamp":1781248106829,"version":"3.54.1"},"reference-count":48,"publisher":"MDPI AG","issue":"5","license":[{"start":{"date-parts":[[2023,2,27]],"date-time":"2023-02-27T00:00:00Z","timestamp":1677456000000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"funder":[{"name":"ICT-AGRI-2 ERA-NET"}],"content-domain":{"domain":[],"crossmark-restriction":false},"short-container-title":["Sensors"],"abstract":"<jats:p>Due to technological developments, wearable sensors for monitoring the behavior of farm animals have become cheaper, have a longer lifespan and are more accessible for small farms and researchers. In addition, advancements in deep machine learning methods provide new opportunities for behavior recognition. However, the combination of the new electronics and algorithms are rarely used in PLF, and their possibilities and limitations are not well-studied. In this study, a CNN-based model for the feeding behavior classification of dairy cows was trained, and the training process was analyzed considering a training dataset and the use of transfer learning. Commercial acceleration measuring tags, which were connected by BLE, were fitted to cow collars in a research barn. Based on a dataset including 33.7 cow \u00d7 days (21 cows recorded during 1\u20133 days) of labeled data and an additional free-access dataset with similar acceleration data, a classifier with F1 = 93.9% was developed. The optimal classification window size was 90 s. In addition, the influence of the training dataset size on the classifier accuracy was analyzed for different neural networks using the transfer learning technique. While the size of the training dataset was being increased, the rate of the accuracy improvement decreased. Beginning from a specific point, the use of additional training data can be impractical. A relatively high accuracy was achieved with few training data when the classifier was trained using randomly initialized model weights, and a higher accuracy was achieved when transfer learning was used. These findings can be used for the estimation of the necessary dataset size for training neural network classifiers intended for other environments and conditions.<\/jats:p>","DOI":"10.3390\/s23052611","type":"journal-article","created":{"date-parts":[[2023,2,27]],"date-time":"2023-02-27T04:13:16Z","timestamp":1677471196000},"page":"2611","update-policy":"https:\/\/doi.org\/10.3390\/mdpi_crossmark_policy","source":"Crossref","is-referenced-by-count":44,"title":["Development and Analysis of a CNN- and Transfer-Learning-Based Classification Model for Automated Dairy Cow Feeding Behavior Recognition from Accelerometer Data"],"prefix":"10.3390","volume":"23","author":[{"given":"Victor","family":"Bloch","sequence":"first","affiliation":[{"name":"Natural Resources Institute Luke (Finland), Latokartanonkaari 9, 00790 Helsinki, Finland"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Lilli","family":"Frondelius","sequence":"additional","affiliation":[{"name":"Natural Resources Institute Luke (Finland), Latokartanonkaari 9, 00790 Helsinki, Finland"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-4639-6229","authenticated-orcid":false,"given":"Claudia","family":"Arcidiacono","sequence":"additional","affiliation":[{"name":"Department of Agriculture, Food and Environment (Di3A), Building and Land Engineering Section, University of Catania, Via Santa Sofia 100, 95123 Catania, Italy"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Massimo","family":"Mancino","sequence":"additional","affiliation":[{"name":"Department of Agriculture, Food and Environment (Di3A), Building and Land Engineering Section, University of Catania, Via Santa Sofia 100, 95123 Catania, Italy"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-5810-4801","authenticated-orcid":false,"given":"Matti","family":"Pastell","sequence":"additional","affiliation":[{"name":"Natural Resources Institute Luke (Finland), Latokartanonkaari 9, 00790 Helsinki, Finland"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"1968","published-online":{"date-parts":[[2023,2,27]]},"reference":[{"key":"ref_1","doi-asserted-by":"crossref","first-page":"105826","DOI":"10.1016\/j.compag.2020.105826","article-title":"A systematic literature review on the use of machine learning in precision livestock farming","volume":"179","author":"Aguilar","year":"2020","journal-title":"Comput. Electron. Agric."},{"key":"ref_2","doi-asserted-by":"crossref","first-page":"5664","DOI":"10.3168\/jds.2016-11526","article-title":"Machine-learning-based calving prediction from activity, lying, and ruminating behaviors in dairy cattle","volume":"100","author":"Borchers","year":"2017","journal-title":"J. Dairy Sci."},{"key":"ref_3","doi-asserted-by":"crossref","first-page":"102","DOI":"10.1016\/j.jveb.2017.04.003","article-title":"Triaxial accelerometers for recording grazing and ruminating time in dairy cows: An alternative to visual observations","volume":"20","year":"2017","journal-title":"J. Vet. Behav."},{"key":"ref_4","doi-asserted-by":"crossref","first-page":"3487","DOI":"10.3168\/jds.2018-15563","article-title":"Technical note: Validation of a behavior-monitoring collar\u2019s precision and accuracy to measure rumination, feeding, and resting time of lactating dairy cows","volume":"102","author":"Grinter","year":"2019","journal-title":"J. Dairy Sci."},{"key":"ref_5","doi-asserted-by":"crossref","first-page":"162","DOI":"10.1016\/j.biosystemseng.2018.10.011","article-title":"Design and test of a low-power acceleration sensor with Bluetooth Low Energy on ear tags for sow behaviour monitoring","volume":"176","author":"Liu","year":"2018","journal-title":"Biosyst. Eng."},{"key":"ref_6","doi-asserted-by":"crossref","first-page":"106500","DOI":"10.1016\/j.compag.2021.106500","article-title":"IoT device-based data acquisition system with on-board computation of variables for cow behaviour recognition","volume":"191","author":"Arcidiacono","year":"2021","journal-title":"Comput. Electron. Agric."},{"key":"ref_7","doi-asserted-by":"crossref","first-page":"106610","DOI":"10.1016\/j.compag.2021.106610","article-title":"Predicting livestock behaviour using accelerometers: A systematic review of processing techniques for ruminant behaviour prediction from raw accelerometer data","volume":"192","author":"Riaboff","year":"2022","journal-title":"Comput. Electron. Agric."},{"key":"ref_8","doi-asserted-by":"crossref","first-page":"189","DOI":"10.1007\/s40860-021-00147-0","article-title":"Trends in human activity recognition using smartphones","volume":"7","author":"Ferrari","year":"2021","journal-title":"J. Reliab. Intell. Env."},{"key":"ref_9","doi-asserted-by":"crossref","first-page":"3","DOI":"10.1016\/j.patrec.2018.02.010","article-title":"Deep learning for sensor-based activity recognition: A survey","volume":"119","author":"Wang","year":"2019","journal-title":"Pattern Recognit. Lett."},{"key":"ref_10","doi-asserted-by":"crossref","unstructured":"Pavlovic, D., Davison, C., Hamilton, A., Marko, O., Atkinson, R., Michie, C., Crnojevi\u0107, V., Andonovic, I., Bellekens, X., and Tachtatzis, C. (2021). Classification of Cattle Behaviours Using Neck-Mounted Accelerometer-Equipped Collars and Convolutional Neural Networks. Sensors, 21.","DOI":"10.3390\/s21124050"},{"key":"ref_11","doi-asserted-by":"crossref","first-page":"247","DOI":"10.1016\/j.compag.2018.12.023","article-title":"Classification of multiple cattle behavior patterns using a recurrent neural network with long short-term memory and inertial measurement units","volume":"157","author":"Peng","year":"2019","journal-title":"Comput. Electron. Agric."},{"key":"ref_12","first-page":"1","article-title":"Data Augmentation for Inertial Sensor Data in CNNs for Cattle Behavior Classification","volume":"5","author":"Li","year":"2021","journal-title":"IEEE Sens. Lett."},{"key":"ref_13","doi-asserted-by":"crossref","first-page":"211","DOI":"10.1007\/s11263-015-0816-y","article-title":"ImageNet Large Scale Visual Recognition Challenge","volume":"115","author":"Russakovsky","year":"2015","journal-title":"Int. J. Comput. Vis."},{"key":"ref_14","doi-asserted-by":"crossref","first-page":"182","DOI":"10.1016\/j.compag.2018.07.005","article-title":"A hidden Markov model to estimate the time dairy cows spend in feeder based on indoor positioning data","volume":"152","author":"Pastell","year":"2018","journal-title":"Comput. Electron. Agric."},{"key":"ref_15","doi-asserted-by":"crossref","first-page":"105179","DOI":"10.1016\/j.compag.2019.105179","article-title":"Development of a methodological framework for a robust prediction of the main behaviours of dairy cows using a combination of machine learning algorithms on accelerometer data","volume":"169","author":"Riaboff","year":"2020","journal-title":"Comput. Electron. Agric."},{"key":"ref_16","doi-asserted-by":"crossref","first-page":"124","DOI":"10.1016\/j.compag.2017.01.021","article-title":"Development of a threshold-based classifier for real-time recognition of cow feeding and standing behavioural activities from accelerometer data","volume":"134","author":"Arcidiacono","year":"2017","journal-title":"Comput. Electron. Agric."},{"key":"ref_17","doi-asserted-by":"crossref","first-page":"20","DOI":"10.1016\/j.compag.2016.08.009","article-title":"Detecting heat events in dairy cows using accelerometers and unsupervised learning","volume":"128","author":"Shahriar","year":"2016","journal-title":"Comput. Electron. Agric."},{"key":"ref_18","unstructured":"(2023, January 02). WISDM HAR Dataset. Available online: https:\/\/www.cis.fordham.edu\/wisdm\/dataset.php."},{"key":"ref_19","doi-asserted-by":"crossref","first-page":"115702","DOI":"10.1016\/j.eswa.2021.115702","article-title":"Minimum training sample size requirements for achieving high prediction accuracy with the BN model: A case study regarding seismic liquefaction","volume":"185","author":"Hu","year":"2021","journal-title":"Expert Syst. Appl."},{"key":"ref_20","doi-asserted-by":"crossref","unstructured":"Kalouris, G., Zacharaki, E.I., and Megalooikonomou, V. (2019, January 22\u201325). Improving CNN-based activity recognition by data augmentation and transfer learning. Proceedings of the IEEE 17th International Conference on Industrial Informatics (INDIN), Helsinki, Finland.","DOI":"10.1109\/INDIN41052.2019.8972135"},{"key":"ref_21","doi-asserted-by":"crossref","unstructured":"Eyobu, S.O., and Han, D.S. (2018). Feature Representation and Data Augmentation for Human Activity Classification Based on Wearable IMU Sensor Data Using a Deep LSTM Neural Network. Sensors, 18.","DOI":"10.3390\/s18092892"},{"key":"ref_22","doi-asserted-by":"crossref","unstructured":"Oh, S., Ashiquzzaman, A., Lee, D., Kim, Y., and Kim, J. (2021). Study on Human Activity Recognition Using Semi-Supervised Active Transfer Learning. Sensors, 21.","DOI":"10.3390\/s21082760"},{"key":"ref_23","doi-asserted-by":"crossref","unstructured":"Li, F., Shirahama, K., Nisar, M.A., Huang, X., and Grzegorzek, M. (2020). Deep Transfer Learning for Time Series Data Based on Sensor Modality Classification. Sensors, 20.","DOI":"10.3390\/s20154271"},{"key":"ref_24","doi-asserted-by":"crossref","unstructured":"Bloch, V., and Pastell, M. (2020). Monitoring of Cow Location in a Barn by an Open-Source, Low-Cost, Low-Energy Bluetooth Tag System. Sensors, 20.","DOI":"10.3390\/s20143841"},{"key":"ref_25","doi-asserted-by":"crossref","unstructured":"Hossain, T., Ahad, M.A.R., and Inoue, S. (2020). A Method for Sensor-Based Activity Recognition in Missing Data Scenario. Sensors, 20.","DOI":"10.3390\/s20143811"},{"key":"ref_26","doi-asserted-by":"crossref","unstructured":"Um, T.T., Pfister, F.M.J., Pichler, D., Endo, S., Lang, M., Hirche, S., Fietzek, U., and Kuli\u0107, D. (2017, January 13\u201317). Data augmentation of wearable sensor data for parkinson\u2019s disease monitoring using convolutional neural networks. Proceedings of the 19th ACM International Conference on Multimodal Interaction, New York, NY, USA.","DOI":"10.1145\/3136755.3136817"},{"key":"ref_27","unstructured":"Brownlee, J. (2019). Deep Learning for Computer Vision: Image Classification, Object Detection, and Face Recognition in Python, [1st ed.]. Available online: https:\/\/books.google.com.hk\/books\/about\/Deep_Learning_for_Computer_Vision.html?id=DOamDwAAQBAJ&redir_esc=y."},{"key":"ref_28","doi-asserted-by":"crossref","first-page":"167","DOI":"10.1016\/j.eswa.2019.04.057","article-title":"A survey on wearable sensor modality centred human activity recognition in health care","volume":"137","author":"Wang","year":"2019","journal-title":"Expert Syst. Appl."},{"key":"ref_29","doi-asserted-by":"crossref","first-page":"109497","DOI":"10.1109\/ACCESS.2021.3099212","article-title":"Real-Time Behavioral Recognition in Dairy Cows Based on Geomagnetism and Acceleration Information","volume":"9","author":"Tian","year":"2021","journal-title":"IEEE Access"},{"key":"ref_30","doi-asserted-by":"crossref","first-page":"161","DOI":"10.1016\/j.neucom.2021.02.046","article-title":"A review of irregular time series data handling with gated recurrent neural networks","volume":"441","author":"Weerakody","year":"2021","journal-title":"Neurocomputing"},{"key":"ref_31","doi-asserted-by":"crossref","unstructured":"Tosi, J., Taffoni, F., Santacatterina, M., Sannino, R., and Formica, D. (2017). Performance Evaluation of Bluetooth Low Energy: A Systematic Review. Sensors, 17.","DOI":"10.3390\/s17122898"},{"key":"ref_32","doi-asserted-by":"crossref","first-page":"105651","DOI":"10.1016\/j.knosys.2020.105651","article-title":"A knowledge-light approach to personalised and open-ended human activity recognition","volume":"192","author":"Wijekoon","year":"2020","journal-title":"Knowl. -Based Syst."},{"key":"ref_33","doi-asserted-by":"crossref","first-page":"105068","DOI":"10.1016\/j.compag.2019.105068","article-title":"Unsupervised automated monitoring of dairy cows\u2019 behavior based on Inertial Measurement Unit attached to their back","volume":"167","author":"Achour","year":"2019","journal-title":"Comput. Electron. Agric."},{"key":"ref_34","doi-asserted-by":"crossref","first-page":"289","DOI":"10.1016\/j.compag.2018.01.007","article-title":"Categorising sheep activity using a tri-axial accelerometer","volume":"145","author":"Barwick","year":"2018","journal-title":"Comput. Electron. Agric."},{"key":"ref_35","doi-asserted-by":"crossref","first-page":"425","DOI":"10.1016\/j.rvsc.2017.10.005","article-title":"On the use of on-cow accelerometers for the classification of behaviours in dairy barns","volume":"125","author":"Benaissa","year":"2019","journal-title":"Res. Vet. Sci."},{"key":"ref_36","doi-asserted-by":"crossref","first-page":"18","DOI":"10.1016\/j.compag.2014.12.002","article-title":"Dynamic cattle behavioural classification using supervised ensemble classifiers","volume":"111","author":"Dutta","year":"2015","journal-title":"Comput. Electron. Agric."},{"key":"ref_37","doi-asserted-by":"crossref","first-page":"105139","DOI":"10.1016\/j.compag.2019.105139","article-title":"Automatic equine activity detection by convolutional neural networks using accelerometer data","volume":"168","author":"Eerdekens","year":"2020","journal-title":"Comput. Electron. Agric."},{"key":"ref_38","doi-asserted-by":"crossref","first-page":"190824","DOI":"10.1098\/rsos.190824","article-title":"Automated detection of lameness in sheep using machine learning approaches: Novel insights into behavioural differences among lame and non-lame sheep","volume":"7","author":"Kaler","year":"2020","journal-title":"R. Soc. Open Sci."},{"key":"ref_39","doi-asserted-by":"crossref","unstructured":"Pavlovic, D., Czerkawski, M., Davison, C., Marko, O., Michie, C., Atkinson, R., Crnojevic, V., Andonovic, I., Rajovic, V., and Kvascev, G. (2022). Behavioural Classification of Cattle Using Neck-Mounted Accelerometer-Equipped Collars. Sensors, 22.","DOI":"10.3390\/s22062323"},{"key":"ref_40","first-page":"124","article-title":"Cattle behaviour classification from collar, halter, and ear tag sensors","volume":"5","author":"Rahman","year":"2018","journal-title":"Inform. Process. Agric."},{"key":"ref_41","first-page":"427","article-title":"Automatic recognition of ingestive-related behaviors of dairy cows based on triaxial acceleration","volume":"7","author":"Shen","year":"2020","journal-title":"Inf. Process. Agric."},{"key":"ref_42","doi-asserted-by":"crossref","unstructured":"Simanungkalit, G., Barwick, J., Cowley, F., Dobos, R., and Hegarty, R. (2021). A Pilot Study Using Accelerometers to Characterise the Licking Behaviour of Penned Cattle at a Mineral Block Supplement. Animals, 11.","DOI":"10.3390\/ani11041153"},{"key":"ref_43","first-page":"1","article-title":"Classification of behaviour in housed dairy cows using an accelerometer-based activity monitoring system","volume":"3","author":"Barker","year":"2015","journal-title":"Animal Biotelemetry"},{"key":"ref_44","doi-asserted-by":"crossref","unstructured":"V\u00e1zquez-Diosdado, J.A., Paul, V., Ellis, K.A., Coates, D., Loomba, R., and Kaler, J.A. (2019). Combined Offline and Online Algorithm for Real-Time and Long-Term Classification of Sheep Behaviour: Novel Approach for Precision Livestock Farming. Sensors, 19.","DOI":"10.3390\/s19143201"},{"key":"ref_45","doi-asserted-by":"crossref","first-page":"171442","DOI":"10.1098\/rsos.171442","article-title":"Evaluation of sampling frequency, window size and sensor position for classification of sheep behaviour","volume":"5","author":"Walton","year":"2018","journal-title":"R. Soc. Open Sci."},{"key":"ref_46","doi-asserted-by":"crossref","unstructured":"Wang, J., He, Z., Zheng, G., Gao, S., and Zhao, K. (2018). Development and validation of an ensemble classifier for real-time recognition of cow behavior patterns from accelerometer data and location data. PLoS ONE, 13.","DOI":"10.1371\/journal.pone.0203546"},{"key":"ref_47","doi-asserted-by":"crossref","unstructured":"Wang, J., Bell, M., Liu, X., and Liu, G. (2020). Machine-Learning Techniques Can Enhance Dairy Cow Estrus Detection Using Location and Acceleration Data. Animals, 10.","DOI":"10.3390\/ani10071160"},{"key":"ref_48","doi-asserted-by":"crossref","first-page":"156","DOI":"10.1016\/j.biosystemseng.2018.11.011","article-title":"Variable segmentation and ensemble classifiers for predicting dairy cow behaviour","volume":"178","author":"Williams","year":"2019","journal-title":"Biosyst. Eng."}],"container-title":["Sensors"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/www.mdpi.com\/1424-8220\/23\/5\/2611\/pdf","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,10,10]],"date-time":"2025-10-10T18:43:40Z","timestamp":1760121820000},"score":1,"resource":{"primary":{"URL":"https:\/\/www.mdpi.com\/1424-8220\/23\/5\/2611"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2023,2,27]]},"references-count":48,"journal-issue":{"issue":"5","published-online":{"date-parts":[[2023,3]]}},"alternative-id":["s23052611"],"URL":"https:\/\/doi.org\/10.3390\/s23052611","relation":{},"ISSN":["1424-8220"],"issn-type":[{"value":"1424-8220","type":"electronic"}],"subject":[],"published":{"date-parts":[[2023,2,27]]}}}