DOI: 10.3390/ai7070233 ISSN: 2673-2688

Continual Learning for Precision Livestock Farming: Mitigating Catastrophic Forgetting in Edge-Deployed Behavioral Recognition

Rodrigo Garcia, Horderlin Robles

Precision Livestock Farming (PLF) increasingly relies on edge-deployed sensors to monitor bovine behaviors, fostering improved welfare and management. However, behavioral data naturally expands over time and presents severe class imbalances due to animals’ predominantly sedentary routines. When continuous sequential updates are required without access to historical datasets, deep learning methods frequently succumb to catastrophic forgetting. This study introduces an ultra-lightweight (∼0.85 MB) Continual Learning (CL) architecture built upon a CNN-BiLSTM feature extractor, tailored to process multivariate Inertial Measurement Unit (IMU) streams. We exhaustively evaluated baseline Naïve Fine-Tuning against Elastic Weight Consolidation (EWC), Learning without Forgetting (LwF), and episodic Replay under three rigorous real-world paradigms: Class Incremental, Subject Incremental (domain shift), and Imbalanced Realistic scenarios. Our empirical findings expose the fragility of static paradigms: in Class Incremental expansions, Naïve Fine-Tuning collapsed to an Average Accuracy of 33.33%. Conversely, Experience Replay emerged as the most robust defense, achieving a statistically significant Average Accuracy of 74.64 ± 6.77% across multiple random seeds. Furthermore, LwF effectively mitigated structural variations across unseen animal domains (Subject Incremental) without requiring raw data buffers. Notably, under severe biological class imbalances (Imbalanced Cumulative), the architecture proved highly resilient, maintaining 98.46% Average Accuracy and retaining perfect minority class recall. This research validates the operational feasibility of deploying adaptive, privacy-preserving CL frameworks directly on low-power wearable devices for lifelong livestock monitoring.

More from our Archive