An Internet of Things (IoT)-enabled machine learning framework, BovisCalfNet, is presented for automated calf disease detection using physiological sensor measurements and visual data. The proposed method combines body temperature, heart rate, blood oxygen saturation (SpO₂), and activity data acquired through a wearable neckband with calf images to support continuous, non-invasive health monitoring. A multimodal feature extraction and fusion strategy is employed to integrate heterogeneous physiological and visual data, while a hybrid stacking ensemble classifier performs disease classification. The framework is designed for the early identification of four contagious calf diseases, namely Foot-and-Mouth Disease, Coccidiosis, Pneumonia, and Lumpy Skin Disease. The proposed approach provides a reproducible, scalable, and low-cost methodology for precision livestock farming and can be extended to additional diseases and sensing modalities. Main features of the framework are as follows: Integrates wearable IoT sensor data and calf images within a unified multimodal framework for calf disease detection. Employs multimodal feature fusion with a hybrid stacking ensemble classifier for automated classification of multiple calf diseases. Provides a non-invasive, scalable, and reproducible methodology for continuous calf health monitoring and early disease detection.
Research Article · Volume 14, Issue 12, Pages 2882–2896, 18 November 2026 · Open Access
BovisCalfNet: A Smart Farming Approach to Calf Health Using an IoT-Enabled Machine Learning Framework
,
Affiliations & Notes ⌄
- 1Amity School of Engineering and Technology, Amity University Mumbai, Maharashtra, India
- *Correspondence | Pallavi Mangrulkar; Email: pallavimangrulkar16@gmail.com
Article Info ⌄
- Journal:
- Advances in Animal and Veterinary Sciences
- Submitted Date:
- 3 August 2026
- Accepted Date:
- 10 September 2026
- Published Date:
- 18 November 2026

From the article
- This work presents an IoT-enabled and machine learning-based novel algorithm, BovisCalfNet, for real-time calf disease detection using wearable sensors and image data.
- The system monitors vital physiological parameters such as temperature and heart rate and behavioral parameters such as movement through an ESP32-based neckband and applies a hybrid ML model with ensemble stacking.
- The system shows a classification accuracy of 96.65%, with a precision of 96.69%, a recall of 96.65%, an F1 score of 96.66% and an ROC AUC of 99.72%, with four major calf diseases.
- Thus, BovisCalfNet provides a practical and efficient solution for smart livestock monitoring, contributing to improved animal health management and supporting automated farming practices.
Selected from the article's own text.
Abstract
INTRODUCTION
Calf health is a critical factor in livestock farming, as diseases in young animals can spread rapidly within a herd, causing significant economic losses and reducing herd productivity. An infected calf can rapidly transmit disease to other calves and adult cattle within the herd. Pathogens responsible for calf diseases, including bacteria, viruses, and parasites, can be transmitted through contaminated faeces, water, feed, bedding, and direct contact. In crowded or unhygienic farm conditions, a single infected calf can become a source of infection, potentially resulting in an outbreak and the spread of disease among healthy animals.
Early identification of health problems in calves is important because timely disease detection can reduce mortality and improve overall farm performance ; ; . Traditional monitoring methods rely heavily on manual observation, which is labor-intensive, time-consuming, and prone to error, making early detection of multiple diseases challenging ; . Therefore, there is a need for automated approaches for early disease prediction and detection in calves ; . In this study, we propose an automated IoT-enabled system that integrates physiological and activity measurements with image data for early disease detection. The system employs IoT sensors, including temperature, heart-rate, and activity sensors, to acquire physiological and behavioural parameters, which are combined with calf image data to support automated health assessment ; . The study focuses on four contagious and potentially life-threatening calf diseases: Foot-and-Mouth Disease, Coccidiosis, Pneumonia, and Lumpy Skin Disease. Foot-and-Mouth Disease is a highly contagious viral disease caused by the Foot-and-Mouth Disease virus (FMDV) that affects cloven-hoofed animals, including cattle and calves. It is associated with clinical signs such as fever, excessive salivation, lameness, reduced feed intake, and vesicular lesions of the mouth and hooves. Coccidiosis is a parasitic intestinal disease that primarily affects young calves and is associated with clinical signs including diarrhea, which may be bloody, dehydration, reduced feed intake, lethargy, and weight loss (Sedky D et al., 2025; . Pneumonia is commonly associated with clinical signs such as fever, coughing, nasal discharge, rapid breathing, and reduced activity ; Perttu RK et al., 2024; . Lumpy Skin Disease (LSD) is a viral disease of cattle caused by lumpy skin disease virus, a Capripoxvirus, and is characterized by fever and the development of firm skin nodules over the body . The disease is primarily transmitted by blood-feeding arthropods, including mosquitoes, flies, and ticks. Figure 1 presents representative clinical images of a diseased calf.

Lesions of calf diseases.
The authors have developed an IoT–ML–based framework for real-time detection of calf diseases using IoT sensors and machine learning algorithms. This work proposes a stacking ensemble model for accurate disease prediction and detection. The system offers a scalable and non-invasive solution for early disease identification.
The remainder of the paper is organized as follows: Section 2 presents the literature review; Section 3 describes the proposed methodology; Section 4 presents and discusses the results; Section 5 discusses method validation; Section 6 discusses the limitations of the proposed framework; Section 7 presents the future scope; and Section 8 concludes the paper.
Literature review
Calf health is an important aspect of dairy herd management. Common diseases affecting calves include Foot-and-Mouth Disease, pneumonia, and coccidiosis. Recent advances in precision livestock farming, wearable sensing, machine learning, and computer vision have created opportunities for automated and continuous monitoring of calf health.
Neethirajan (2020) investigated biosensor- and IoT-based systems for animal health monitoring and reported that wearable devices can monitor physiological parameters such as temperature, heart rate, and activity in livestock; however, the cost of sensing technologies can remain a limitation. O’Neill (2021) reviewed automated calf health monitoring systems based on precision livestock farming and reported that such technologies can support early disease detection and improve calf health outcomes. However, their implementation may require substantial initial investment, specialized infrastructure, and technical expertise for operation and maintenance. Sun et al. (2021) reviewed sensor-based health monitoring and behavioural tracking technologies and demonstrated their potential for detecting early behavioural changes associated with calf health problems. Nevertheless, their performance can be affected by environmental conditions, sensor calibration, and individual variation in animal behaviours. Cantor et al. (2021) examined precision livestock technologies for monitoring animal health and welfare and highlighted their potential benefits while also identifying implementation and cost-related challenges.
Cantor et al. (2022) investigated the use of behavioural monitoring for detecting bovine respiratory disease in calves and reported that changes in feeding and activity patterns may provide indicators of early respiratory infection. However, such approaches generally require continuous monitoring infrastructure. Moreira et al. (2026) examined the associations of diarrhea and bovine respiratory disease with calf growth, feed intake, and mortality, but their study did not focus on an integrated IoT-based framework for automated early disease detection. Sedky et al. (2025) investigated calf diarrhoeal diseases using molecular and diagnostic approaches. Although molecular approaches can provide detailed pathogen information, they require specialized laboratory facilities and are therefore less suitable for rapid on-farm screening. Abdallah et al. (2025) focused primarily on bovine coronavirus in diarrhoeic calves, providing pathogen-specific information rather than a multimodal framework for detecting multiple calf diseases.
Claesen et al. (2023) proposed a machine-learning and optimization framework for early diagnosis of bovine respiratory disease. Their findings demonstrated the potential of machine learning for disease prediction; however, the study focused on a single disease and did not integrate multimodal image and physiological sensor data. Kaur and Virk (2025) developed an IoT-driven hybrid artificial intelligence model for health monitoring of cows using physiological data. However, their framework did not incorporate computer vision or an advanced ensemble-learning approach for multimodal disease classification. Li et al. (2023) investigated the detection of abnormal respiratory behaviours in calves using video-based analysis and an improved YOLOv5 method, demonstrating the potential of computer vision for automated calf health monitoring. However, their approach did not combine physiological sensor information with visual features for multimodal detection of multiple calf diseases.
A comparative analysis of selected existing studies and the proposed BovisCalfNet framework based on the reported evaluation metrics is presented in Table 1.
Table 1: Comparative analysis of existing studies on calf disease detection.
| Study | Accuracy (%) | Precision (%) | Recall (%) | F1-score (%) |
| Claesen et al. (2023) | 88.0 | NR | 70.0 | NR |
| Sanz-García et al. (2022) | 77.3 | 76.6 | 62.5 | 68.9 |
| Kaur and Virk (2025) | 93.56 | 91.42 | 77.77 | 84.02 |
| Yu et al. (30) | 95.20* | 94.60* | 94.10* | 94.35* |
| Proposed BovisCalfNet | 96.65 | 96.69 | 96.65 | 96.66 |
Materials and methods
The proposed system employs an Internet of Things (IoT)-enabled and machine learning-based framework for monitoring and early detection of health abnormalities in calves. The framework integrates wearable sensors, video monitoring, cloud computing, convolutional neural network (CNN)-based visual feature extraction, and a stacking ensemble machine learning model to collect, transmit, process, and analyse multimodal data. Physiological and behavioural parameters are acquired using a wearable neckband equipped with multiple sensors and are combined with image-based information for disease screening and classification. The extracted multimodal features are subsequently used by the proposed BovisCalfNet model to classify calves into healthy and diseased categories. The overall workflow of the proposed methodology is illustrated in Figure 2.
Algorithm steps
Input: Sensor data (temperature, heart rate, SpO₂, X-, Y-, Z-axis acceleration, acceleration magnitude) and calf images/video frames.
Output: Healthy or Predicted Disease.

Decision flowchart of the proposed BovisCalNet methodology.
Process
Step 1: Data acquisition
Acquire physiological data, including temperature, heart rate, and SpO₂, and activity data from the wearable IoT-enabled neckband.
Capture visual image/video data of calves using a surveillance camera.
Step 2: Health condition evaluation
Compare the acquired sensor measurements with predefined threshold values.
If the sensor measurements remain within the predefined normal ranges, classify the calf as Healthy and continue periodic health monitoring.
If one or more sensor parameters exceed the predefined thresholds, classify the observation as potentially unhealthy, notify the cattle breeder, and proceed to further assessment.
Step 3: Notification to the cattle breeder
Generate an alert notification for the cattle breeder or farm manager when potentially abnormal sensor measurements are detected.
Step 4: Isolation and further diagnosis
The suspected calf is isolated, where appropriate, and further assessment is performed using visual data and corresponding physiological sensor measurements.
Step 5: BovisCalfNet Processing
Input data processing.
Tabular sensor input.
Visual input.
Tabular feature engineering.
Visual feature extraction.
Multimodal feature fusion.
Model training.
Testing (inference) phase.
Video and sensor acquisition.
Object detection and anatomical region extraction.
Multimodal feature generation.
Disease classification.
Data acquisition and dataset collection
In the first step, the system records parameters such as body temperature, heart rate, blood oxygen saturation (SpO₂), calf body movement and acceleration from a wearable device placed on the calf, as shown in Figure 3. The actual experimentation is performed on calves located in the Karjat region of Raigad, Maharashtra.

Physiological and behavioural data collection using the wearable IoT-enabled neckband.
The dataset consists of physiological and behavioral data collected from 200 calves over a monitoring period from May 2025 to May 2026. Data were recorded at 10-minute intervals, while data retrieval and verification were performed during scheduled farm visits (thrice in a week). Each calf was equipped with an IoT-based wearable neckband integrated with a DS18B20 temperature sensor, MAX30102 heart rate sensor and ADXL345 accelerometer. The collected sensor measurements were transmitted from the ESP32 through Wi-Fi to the Google Cloud platform for processing and classification. The dataset comprised 13,518 raw sensor records collected from 200 unique calves. As shown in Table 2, the records consisted of 7,364 healthy records, 1,723 FMD records, 1,670 LSD records, 1,499 Coccidiosis records, and 1,262 Pneumonia records. Based on the unique combination of Calf_ID and disease status, the dataset comprised 200 unique calf–disease combinations, including 106 healthy, 24 FMD, 24 LSD, 23 Coccidiosis, and 23 Pneumonia combinations. These combinations represent unique calf–disease label associations rather than necessarily independent clinical cases, because multiple sensor measurements were obtained from the same calf. Therefore, the raw-record count should not be interpreted as the number of independent animals or clinical cases.
Table 2: Dataset composition by disease class and unique calf–disease combinations.
| Disease/ Dataset measure | Raw records | Unique calf disease combinations |
| Healthy | 7,364 | 106 |
| FMD | 1,723 | 24 |
| LSD | 1,670 | 24 |
| Coccidiosis | 1,499 | 23 |
| Pneumonia | 1,262 | 23 |
| Total disease combinations | 13,518 | 200 |
| Unique calves (Calf_ID) | 13,518 records from 200 calves | 200 |
Multimodal data used in this system consisting of data collected from sensors via ESP32 and labelled disease-image datasets collected from Kaggle, Google, veterinary records and breeders and video data for training and testing the YOLOv8-OBB algorithm. The dataset is divided into training, validation and testing sets with proportions of 70%, 15% and 15%, respectively, using a holdout validation strategy to prevent data leakage.
The image dataset summarized in Table 3 includes diseases with visually observable symptoms, namely Lumpy Skin Disease (LSD), Coccidiosis, Foot-and-Mouth Disease (FMD) and Healthy calves. Pneumonia cases were primarily identified using physiological sensor parameters such as body temperature, heart rate, respiration-related activity and movement patterns collected from wearable IoT devices, as it cannot be reliably identified using image data alone. The proposed system identifies the possibility of pneumonia for early screening.
Table 3: Summary of raw and augmented images with training–testing split.
| Health condition | Image count | Training dataset | Validation dataset | Testing dataset |
| Healthy | 6336 | 4435 | 950 | 951 |
| LSD | 1443 | 1011 | 216 | 216 |
| Coccidiosis | 1037 | 727 | 155 | 155 |
| FMD (Foot) | 2277 | 1595 | 341 | 341 |
| FMD(Mouth) | 2425 | 1697 | 364 | 364 |
| Total | 13518 | 9465 | 2026 | 2027 |
Health condition evaluation
The collected sensor data are analyzed to determine the calf’s health status. The system compares the measured values with threshold values of the physiological parameters (temperature and heart rate) and behavioral conditions (aggression or reduced movement measured via acceleration).
The system checks the following conditions for identifying unhealthy calves:
Temperature > 39.5 °C, Heart Rate > 140 and < 90 BPM, SpO₂ < 90%, X-axis or Y-axis acceleration greater than ±0.2 g, Z-axis acceleration between 0.7 g and 1.1 g. If one or more of these parameters exceed the defined thresholds, the system identifies the calf as unhealthy; otherwise, the calf is considered healthy.
The predefined thresholds were used only as an initial rule-based pre-screening mechanism for identifying potentially abnormal observations, rather than as definitive disease diagnostic criteria. The subsequent machine-learning model performs the final disease classification using the combined physiological, activity, and image-derived features.
Notification to the cattle breeder
when an unhealthy calf is detected, the system automatically generates an alert notification. this notification is sent to the cattle breeder or farm manager through email via the dashboard.
Isolation and further diagnosis
After receiving the alert, the breeder is advised to isolate the affected calf to prevent the spread of disease within the herd. Once isolated, a video of the suspected unhealthy calf is captured and provided as input to the proposed BovisCalfNet framework. The captured video of the unhealthy calf and the corresponding physiological sensor readings are analysed by the model to identify the specific disease affecting the calf.
Proposed BovisCalfNet system architecture
The proposed BovisCalfNet framework consists of two primary stages: training and testing (inference), as illustrated in Figure 4. During training, multimodal data are fused to construct a robust stacking ensemble classifier, while during inference, unseen video frames and real-time sensor readings are processed to generate disease predictions.

System architecture of BovisCalfNet.
Input data processing
The architecture accepts two kinds of data: Visual image data and physiological sensor data.
Tabular sensor input
The corresponding IoT sensor readings synchronized with each image include body temperature (T), heart rate (HR), tri-axial accelerometer measurements (x-, y- and z-axes) and blood oxygen saturation (SpO2). The raw sensor vector is represented as:
(x_base=(T, HR, x_acc, y_acc, z_acc, SpO_2 )) ...(1)
Which forms a six-dimensional physiological feature vector.
Visual input
Image frames of calves are collected under different environmental conditions and camera viewpoints. Since the original images can vary in resolution, they are resized and normalized before feature extraction. Each image is represented as a three-channel RGB tensor.
Tabular feature engineering
To capture the overall movement intensity of the calf, the Euclidean magnitude of the tri-axial acceleration measurements is computed as:
...(2)
The computed acceleration magnitude provides a single measure of the calf’s overall movement intensity and is appended to the original physiological measurements to form the enhanced tabular feature vector as-
...(3)
With a total dimensionality of 7 features.
Visual feature extraction
Visual features are extracted using the ResNet18 convolutional neural network. The final fully connected classification layer is removed, allowing the backbone network to function as a generic feature extractor. Each input image is resized to 224 × 224 × 3 pixels and normalized before being processed by the network. Four anatomically important calf regions are analysed as Mouth, Hoof, Udder and Body. Global average pooling is applied to the output feature maps of each cropped region, producing a 512-dimensional embedding per region. Four anatomically significant calf regions, the mouth, hoof, udder and body, are analysed separately to capture disease-specific visual characteristics.
...(4)
Resulting in a 2048-dimensional visual feature vector.
Multimodal feature fusion
The engineered tabular features and deep visual embeddings are concatenated to form a unified multimodal feature representation:
....(5)
The resulting feature vector contains:

Dimensions and serves as the input to the classification model.
Model training
The complete dataset is divided into 70% training data, 15% validation data and 15% testing data, using calf ID to split the data and avoid data leakage by assigning each calf to only one partition. The training subset is used to optimize the proposed BovisCalfNet stacking ensemble classifier, which integrates multiple heterogeneous machine learning algorithms as base learners, including Random Forest, Extra Trees, XGBoost, LightGBM, LogisticRegression, KNN, SGD and GaussianNB models, with random state set to 42 for all learners. Predictions generated by these base estimators are combined by a meta-learning layer to produce the final classification output. All models were implemented using the documented hyperparameter configurations reported in Table 4, with the same pre-processing, data partitioning, and evaluation protocol applied across classifiers to ensure a consistent comparison.
After optimization, the trained ensemble is stored as BovisCalfNet.joblib for deployment. The validation dataset is used to monitor model generalization and prevent overfitting using evaluation metrics such as classification accuracy, precision, recall and F1-score.
Testing (Inference) phase
In the testing phase, the BovisCalfNet model is fed with unseen video and sensor data for performance evaluation.
Video and sensor acquisition
The input video is converted into one frame per second from a 30 FPS stream to reduce computational complexity. Simultaneously, physiological parameters are acquired from an IoT-enabled wearable neckband providing the six primary sensor variables.
Table 4: Hyperparameters of base models and meta-model in BovisCalfNet framework.
| Learner | Hyperparameter(s) |
| Random forest | n_estimators=100, criterion='gini', max_depth=None, min_samples_split=2, min_samples_leaf=1, bootstrap=True |
| Extra trees | n_estimators=100, criterion='gini', max_depth=None, min_samples_split=2, min_samples_leaf=1, bootstrap=False |
| XGBoost | n_estimators=100, max_depth=6, learning_rate=0.3, subsample=1.0, colsample_bytree=1.0, objective='multi:softprob', eval_metric='mlogloss' |
| LightGBM | n_estimators=100, learning_rate=0.1, num_leaves=31, max_depth=-1, subsample=1.0, colsample_bytree=1.0, objective='multiclass' |
| Logistic regression | penalty='l2', C=1.0, solver='lbfgs', max_iter=100, multi_class='auto' |
| KNN | n_neighbors=5, weights='uniform', algorithm='auto', leaf_size=30, p=2 |
| SGD | loss='hinge', penalty='l2', alpha=0.0001, learning_rate='optimal', max_iter=1000, tol=1e-3 |
| GaussianNB | var_smoothing=1e-9 |
| Logistic regression (Meta-Model) | penalty='l2', C=1.0, solver='lbfgs', max_iter=1500, multi_class='auto' |
Object detection and region extraction
Sampled image frames are processed using a YOLOv8-OBB algorithm to find lesions in the calf. The detector outputs bounding box coordinates corresponding to detected calf body parts. Each detected anatomical region is cropped, resized to 224 × 224 pixels, normalized and passed through the ResNet18 feature extractor to obtain a 512-dimensional embedding. If any target region is unavailable or cannot be detected, a zero-filled 512-dimensional vector is substituted to maintain a consistent feature size.
The YOLOv8-OBB detector was configured and trained using the parameters summarized in Table 5. These settings define the detector training configuration, whereas the detected anatomical regions were subsequently resized to 224 × 224 pixels for ResNet18-based feature extraction, as described above.
The validation performance of the YOLOv8-OBB detector was evaluated at the best-performing checkpoint and the final training epoch, as shown in Table 6. The best checkpoint at epoch 27 was selected for deployment based on its superior validation performance, achieving 96.8% precision, 97.5% recall, 99.0% mAP@50, and 74.1% mAP@50–95. The final checkpoint at epoch 32 showed slightly lower performance across all metrics. These results demonstrate the effectiveness of the selected YOLOv8-OBB model for detecting the predefined anatomical regions. YOLOv8l-OBB Training Loss Across Epochs are shown in Figure 5.
Table 5: YOLOv8-OBB training configuration.
| Parameter | Value |
| Base architecture | YOLOv8l-OBB (oriented bounding box) |
| Pretrained weights | yolov8l-obb.pt |
| Detection classes | 4 (Body, Hoof, Mouth, Udder) |
| Input image size | 640 × 640 |
| Batch size | 16 |
| Maximum/ actual epochs | 50 (maximum); stopped at 32 via early stopping |
| Best checkpoint | Epoch 27 |
| Training images | 7,600 |
| Validation images | 558 |
| Total images | 8,158 |
Table 6: YOLOv8-OBB validation performance: best vs. final training epoch.
| Checkpoint | Precision | Recall | mAP@50 | mAP@50-95 |
| Best (Epoch 27, deployed) | 96.8% | 97.5% | 99.0% | 74.1% |
| Final (Epoch 32) | 92.75% | 95.79% | 97.27% | 73.87% |
Multimodal feature generation
The processed visual embeddings are concatenated with the physiological feature vector, producing the same 2055-dimensional multimodal representation used during training. This ensures consistency between training and inference pipelines.
Disease classification
The multimodal feature vector is supplied to the trained BovisCalfNet stacking ensemble framework, which computes class probabilities across five health conditions:
Healthy: Normal physiological and visual characteristics with no detectable disease indicators.
Foot-and-Mouth Disease (FMD): Identified by elevated body temperature, increased heart rate, reduced physical activity and lesions primarily observed in hoof regions.
Lumpy Skin Disease (LSD): Identified through visible skin nodules or lesions on body images and abnormal body temperature patterns.
Pneumonia: Predicted by respiratory distress and reduced blood oxygen saturation (SpO₂).
Coccidiosis: Characterized by low activity level, reduced heart beats, increased temperature and weight loss detected from visual images.

YOLOv8I-OBB training loss across epochs.
Mathematical formulation of BovisCalfNet
The mathematical formulation of the model is described as follows.
Base learners
Let the training dataset be defined as in Equation 1:
...(6)
Where xi denotes the input sample, xi ∈ Rd represents the input feature vector (sensor + image features) and yi represents the corresponding class label. Each label yi belongs to the set {0, 1, 2, 3, 4}, indicating the five health conditions: Coccidiosis, Foot and Mouth Disease, Healthy, Lumpy Skin Disease and Pneumonia, as shown in Table 7.
Table 7: Class index and corresponding class labels.
| y | Class label |
| 0 | Coccidiosis |
| 1 | Foot and mouth disease |
| 2 | Healthy |
| 3 | Lumpy skin disease |
| 4 | Pneumonia |
The set of base learners is defined as:
H= {h1, h2, h3, h4, h5, h6, h7, h8}
Where; h1: Random Forest Classifier, h2: Extra Trees Classifier, h3: XGB Classifier, h4: LGBM Classifier, h5: Logistic Regression, h6: K Neighbors Classifier, h7: SGD Classifier, h8: Gaussian NB.
Each base learner is trained on the same dataset D and produces a prediction given in equation 7:
zij=hj(Xi) ….(7)
Where X- Dataset, j=1,2,…,8
Meta-feature construction
The outputs of all base learners are combined to form a new feature space (meta-features) given in Equation 8:
Zi= (zi1, zi2…,zi8) …(8)
Thus, the transformed dataset becomes, given in equation:

Where; Z - Prediction from base learner y - true label
Meta-learner
The logistic regression model computes output in Equation 10:

Proposed system dashboard.
Table 8: The results of the performance BovisCalfNet and classifier models on test dataset.
| Evaluation metrics | BovisCalfNet | XGB classifier | Light GBM | Logistic Regression | Ridge | Random forest | SGD | Bagging | Gausssian NB | Extra trees | KNN |
| Accuracy | 0.9665 | 0.8916 | 0.8916 | 0.8688 | 0.8688 | 0.8343 | 0.8770 | 0.7925 | 0.7444 | 0.7055 | 0.4869 |
| Precision | 0.9669 | 0.8925 | 0.8919 | 0.8684 | 0.8704 | 0.8338 | 0.8908 | 0.8014 | 0.7445 | 0.7040 | 0.4967 |
| Recall | 0.9665 | 0.8916 | 0.8916 | 0.8688 | 0.8688 | 0.8343 | 0.8770 | 0.7925 | 0.7444 | 0.7055 | 0.4869 |
| F1 Score | 0.9666 | 0.8913 | 0.8912 | 0.8683 | 0.8685 | 0.8317 | 0.8810 | 0.7936 | 0.7403 | 0.7046 | 0.4888 |
| ROC AUC | 0.9972 | 0.9835 | 0.9840 | 0.9619 | 0.9660 | 0.9580 | 0.9813 | 0.9556 | 0.9330 | 0.8936 | 0.7705 |

Where; wc - Weight Vector and bc -Bias, c- the class label.
The final prediction is obtained from Equation 11:

To ensure fair comparison and reproducibility, all baseline models and the proposed ensemble framework were implemented under consistent experimental conditions. Missing values were handled using standard imputation techniques and feature scaling was applied where necessary using standardization fitted only on the training data. All models were tuned using a consistent and controlled hyperparameter grid search strategy to ensure fair comparison across classifiers.
The result of the prediction given by the meta-learner is shown in Figure 6, where the highest predicted probability is 82.11% for Lumpy Skin Disease.
Results and discussion
All models were trained and evaluated using a common dataset and pre-processing pipeline to ensure fair comparison. Performance was measured using Accuracy, Precision, Recall, F1-score and ROC-AUC with a one-vs-rest strategy. Results are presented in Table 8 and graphically illustrated in Figure 7.

Comparative performance of BovisCalNet against exiting machine learning algorithms.
To further assess whether the difference in prediction outcomes between BovisCalfNet and the compared classifier was statistically significant, McNemar’s test was performed on the paired test-set predictions. The test resulted in a p-value of 0.314063, indicating that there was no statistically significant difference between the prediction outcomes of the two models at the 0.05 significance level.
Complete system evaluation
The threshold-based screening stage was treated as the first-stage classifier before downstream machine-learning prediction. Its performance was evaluated independently using the threshold confusion matrix. As shown in Table 9, the threshold system achieved 97.30% accuracy, 96.94% precision, 96.69% sensitivity, 97.75% specificity, and 96.81% F1-score. The false-positive rate (FPR) was 2.25%, while the false-negative rate (FNR) was 3.31%, corresponding to 38 unhealthy cases that were missed by the threshold rules before reaching the ML classifier.
Table 9: Performance metrics of the threshold-based screening system.
| Threshold metric | Actual result |
| Accuracy | 97.30% |
| Precision | 96.94% |
| Sensitivity/ Recall | 96.69% |
| Specificity | 97.75% |
| FPR | 2.25% |
| FNR | 3.31% |
| F1 | 96.81% |
| Unhealthy missed before ML | 38 |
Method validation
The proposed method was validated using a leakage-safe, animal-wise data partitioning strategy. All records associated with a unique Calf_ID were assigned exclusively to the training (70%), validation (15%) and testing (15%) subset as shown in Table 10, ensuring zero overlap of calves across splits and preventing subject-level information leakage. The training set showed class imbalance, which was addressed using a k-nearest-neighbor-based oversampling method (k = 5), Synthetic Minority Oversampling Technique (SMOTE) is applied to training data, increasing it from 9,447 to 50,340 samples. Validation and test sets are kept unchanged. For validation of multimodal fusion three models are trained under identical data splits and hyperparameter settings: (i) tabular-only Equation 3, (ii) image-only Equation 4, and (iii) fused multimodal features as shown in Equation 5. Table 14 reports overall test-set performance for each class of disease.
Table 10: Distribution of training, validation, and test sets before and after SMOTE
| Dataset | Before resampling | After SMOTE |
Resampling |
| Main training | 9,447 | 50,340 | Yes |
| Validation | 1,997 | 1,997 | No |
| Test | 2,074 | 2,074 | No |
| Temporal training | 10,814 | 58,070 | Yes |
| Temporal test | 2,704 | 2,704 | No |
Table 11: End-to-end performance of the proposed framework on the temporal test population
| End-to-end metric | Actual result |
| Temporal test population | 2,704 |
| Accuracy | 92.94% |
| Macro Precision | 89.21% |
| Macro Recall | 88.86% |
| Macro F1 | 88.99% |
| Weighted F1 | 92.95% |
Test performance by feature setting (Sensor-only vs Image only vs Fused) is shown in Figure 8.

Test performance by feature setting (sensor-only vs image only vs fused).
Temporal validation
Full five-class end-to-end evaluation combining the threshold-based screening stage with the machine-learning disease classification stage was performed on the temporal test population of 2,704 samples for 10-month training and 2-month testing data. The resulting performance is summarized in Table 11. The proposed framework achieved an overall accuracy of 92.94%. The macro-averaged precision, recall, and F1-score were 89.21%, 88.86%, and 88.99%, respectively, while the weighted F1-score was 92.95%. The macro-averaged metrics indicate the model’s performance across all five classes without allowing the larger classes to dominate the evaluation, whereas the higher weighted F1-score reflects the contribution of class frequency to the overall performance.
Table 12: Five-fold cross-validation performance of the proposed model.
| Metric | Mean ± SD |
| Accuracy | 92.00% ± 0.52% |
| Precision | 91.94% ± 0.51% |
| Recall | 92.00% ± 0.52% |
| F1 | 91.91% ± 0.53% |
K- Fold cross validation
Five-fold cross-validation was performed exclusively within the training set for model development, hyperparameter tuning, and robustness assessment. The validation set was kept independent for model selection, and the test set was used only once for the final performance evaluation.
5-fold results are: Accuracy 92.00% ± 0.52%; Precision 91.94% ± 0.51%; Recall 92.00% ± 0.52%; F1 91.91% ± 0.53%. Accuracy 95% CI = 91.36%–92.64% as shown in Table 12, the system uses row-wise StratifiedKFold.
Ablation analysis
The ablation analysis was conducted to quantify the individual and combined contributions of the tabular physiological features and image-derived features, As shown in Table 13, the tabular-only configuration achieved a test accuracy of 74.88%, indicating that physiological and activity-related features provide substantial information for disease classification. The image-only configuration achieved 58.65% accuracy, suggesting that visual features alone were less effective under the heterogeneous field-image conditions. In contrast, the fused multimodal configuration substantially improved performance, achieving 95.87% accuracy, 95.91% precision, 95.87% recall, 95.88% F1-score, and 99.65% ROC-AUC. This improvement demonstrates the complementary nature of physiological and visual information and supports the effectiveness of multimodal feature fusion in BovisCalfNet. The corresponding comparison is illustrated in Figure 8.
Table 13: Ablation of feature modality on test-set performance.
| Feature setting | Test accuracy | Test precision | Test recall | Test f1 score | Test roc auc |
| Tabular-only | 0.7488 | 0.7485 | 0.7488 | 0.7483 | 0.9311 |
| Image-only | 0.5865 | 0.5895 | 0.5865 | 0.5879 | 0.8452 |
| Fused | 0.9587 | 0.9591 | 0.9587 | 0.9588 | 0.9965 |
Table 14: Per-class test recall by feature setting.
| Class | Tabular-only | Image-only | Fused |
| Coccidiosis | 0.683 | 0.981 | 0.969 |
| Foot and mouth disease | 0.615 | 0.341 | 0.911 |
| Healthy | 0.942 | 0.309 | 0.961 |
| Lumpy skin disease | 0.521 | 0.968 | 0.968 |
| Pneumonia | 0.978 | 0.324 | 0.983 |
Per-class recall as shown in Table 14, clarifies how each modality contributes across disease categories. Physiological and behavioural features (tabular-only) were most informative for Healthy and Pneumonia, achieving recall values of 0.942 and 0.978, respectively, whereas visual features (image-only) were most effective for Coccidiosis and Lumpy Skin Disease, with recall values of 0.981 and 0.968, reflecting their characteristic external lesions. Foot-and-Mouth Disease showed relatively low recall with either tabular-only (0.615) or image-only (0.341) inputs but improved substantially to 0.911 with multimodal fusion. Overall, the fused model achieved consistently high recall across all disease classes (0.911–0.983), demonstrating that combining physiological, behavioural and visual information provides complementary diagnostic evidence and improves classification performance.
The SHAP analysis
To further interpret the contribution of the multimodal features, SHAP-based feature contribution analysis was performed on the final fused model. The analysis was used to quantify the relative contribution of the physiological, behavioural, and visual features to the model predictions. The resulting SHAP values provide an interpretable assessment of which input features contribute most strongly to disease classification and complement the modality-level ablation results presented in Tables 13 and 14.
The SHAP analysis further indicates the relative importance of the physiological and behavioural measurements and the visual features extracted from the detected anatomical regions. This analysis provides additional interpretability for the observed performance improvement of the fused model and helps determine whether the visual modality contributes complementary information beyond the sensor-derived features.
Confusion matrix for validation
The confusion matrix of the fused model on the independent test is shown in Figure 10. Residual misclassifications are concentrated around Foot-and-Mouth Disease being predicted as Healthy or Coccidiosis, consistent with FMD’s comparatively weaker single-modality separability observed in the ablation above and is the primary target for additional labelled data or improved lesion imagery in future deployments of the method.

SHAP-based feature contribution analysis of the fused multimodal model.

Confusion matrix for BovisCalNet.
Limitation
Despite the promising performance of BovisCalfNet, several limitations remain. The study included 200 calves from a single geographic region, which may limit generalizability across breeds, farms, and regions. The number of unique calves–disease combinations was also limited for individual diseases. The 10-minute sensing interval and periodic data retrieval may not capture short-duration physiological abnormalities. The predefined physiological thresholds may be influenced by breed, age, activity, diurnal variation, and environmental conditions. The threshold-based screening stage missed 38 unhealthy observations, highlighting the need for further improvement of the initial screening process. The complete threshold-plus-BovisCalfNet pipeline achieved 92.94% end-to-end accuracy on the temporal test population. The image dataset was obtained from multiple sources, resulting in variability in image quality and acquisition conditions. Source-level metadata were not systematically retained for every image, limiting detailed analysis of source-specific effects. Although augmentation and SMOTE were applied only to the training data, synthetic samples do not increase the underlying biological diversity of the dataset. Region-specific YOLOv8l-OBB missed-detection and zero-vector substitution rates were not retrospectively available. The 5-fold validation provided additional robustness estimates, although future studies can further strengthen validation using animal-grouped temporal cross-validation. Exhaustive hyperparameter optimization across all baseline models was not performed. Modern multimodal transformer- or attention-based architectures were not evaluated in the present study. Future work should focus on larger multi-farm and multi-breed datasets, extended field validation, adaptive thresholds, and comprehensive clinical and computational evaluation.
Future scope
Future work may focus on adapting the framework for other livestock species, such as buffalo, sheep, goats, and poultry, by retraining the models with species-specific physiological and behavioural data. The system can also be expanded to support wildlife health monitoring, particularly for biodiversity conservation and endangered species, Additionally, the current machine learning framework can be enhanced by exploring advanced deep learning and hybrid algorithms.
Conclusion
This work presents an IoT-enabled and machine learning-based novel algorithm, BovisCalfNet, for real-time calf disease detection using wearable sensors and image data. The system monitors vital physiological parameters such as temperature and heart rate and behavioral parameters such as movement through an ESP32-based neckband and applies a hybrid ML model with ensemble stacking. The system uses logistic regression as the meta-learner, providing accurate and reliable predictions as compared to traditional models like Random Forest and SGD. The system shows a classification accuracy of 96.65%, with a precision of 96.69%, a recall of 96.65%, an F1 score of 96.66% and an ROC AUC of 99.72%, with four major calf diseases. Thus, BovisCalfNet provides a practical and efficient solution for smart livestock monitoring, contributing to improved animal health management and supporting automated farming practices.
Acknowledgement
We would like to express our sincere gratitude to Amity University Mumbai for providing the infrastructure and academic support necessary for this research. We also extend our heartfelt thanks to the Assistant Commissioner of Animal Husbandry, Taluka Mini Veterinary Polyclinic, Karjat, Raigad District, for their valuable cooperation and assistance in field-level insights and data collection.
Novelty Statement
BovisCalfNet introduces a multimodal IoT-enabled framework that integrates physiological and activity signals from a wearable neckband with calf image data for automated detection of four major calf diseases. Its original contribution is the fusion of heterogeneous sensor and visual features with a hybrid stacking ensemble to provide a unified, non-invasive approach to calf health assessment. The framework offers a reproducible and extensible methodology that combines continuous physiological monitoring with visual disease indicators within a single disease-classification system.
Authors Contribution
PM: Conceptualization, methodology, investigation, resources, data collection, experimentation, writing original draft. RI: Conceptualization, review and editing, supervision.
Ethics statements
This study was conducted in accordance with relevant animal welfare regulations. The research involved is non-invasive monitoring of calves using a wearable IoT-based neckband, and no surgical, pharmacological, or invasive procedures were performed. The study ensured animal welfare, caused no distress, and informed consent was obtained from animal owners prior to data collection.
Declaration of competing interests
The authors declare no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.
Funding declaration
This research did not receive any specific grant from funding agencies in the public, commercial, or not-for-profit sectors.
Data availability statement
The data that support the findings of this study are available from the corresponding author upon reasonable request. The sensor dataset generated and analysed in this study is publicly available at the following repository: Sensor data: https://drive.google.com/file/d/1UGGd0jsOlQ2jwjP4uzqRHPAmFMUmez-O/view?usp=sharing
Generative AI and AI-assisted technology statement
During the preparation of this work, the author(s) used Open AI ChatGPT (GPT-5.5) to assist with language editing, grammar improvement, manuscript organization, and formatting. The author(s) critically reviewed, verified, and edited all AI-generated content and take full responsibility for the content of the published article.
Conflict of interest
The authors have declared that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this manuscript.
References
- Abdallah F, Hassan AA, El-Bayomi KM (2025). Bovine coronavirus in diarrheic pre-weaned calves. Trop. Anim. Health Prod., 57: 143.
- Cantor MC, Costa JHC, Bewley JM, Dohoo IR (2021). Precision technologies for monitoring health and welfare of dairy calves. J. Dairy Sci., 104(10): 10923–10940.
- Cantor MC, Costa JHC (2022). Daily behavioral measures recorded by precision technology devices may indicate bovine respiratory disease status in preweaned dairy calves. J. Dairy Sci., 105: 6070–6082. [CrossRef]
- Claesen E, Cantor MC, Setser MW, Silvestri S, Costa JHC (2023). A machine learning and optimization framework for early diagnosis of bovine respiratory disease. IEEE Access, 11: 73144–73156.
- Cole JB, Wiggans GR, Ma L (2025). Improving dairy calf health through genetic evaluation of diarrhea and respiratory traits. J. Dairy Sci., 108(4): 3211–3223.
- Gao Y, Li J, Wang S (2023). Wearable sensor-based cattle health monitoring using machine learning and time-series analysis. Comput. Electron. Agric., 205: 107656.
- Griffin D, Chengappa MM, Kuszak J (2025). A comprehensive review of bovine respiratory disease. Vet. Sci., 12(8): 778.
- Jaiswal V, Brar APS, Sandhu BS, Singla LD (2023). Faecal prevalence and histopathological evaluation of coccidiosis in bovine calves. J. Parasit. Dis., 47(3): 550–555. [CrossRef]
- Kaur D, Virk AK (2025). An IoT-Driven hybrid AI model for health monitoring of cows. Discover Artif. Intellig., 5: 346. [CrossRef]
- Keles Ö, Sayar E, Kim Y (2025). Molecular characterization of viral pathogens causing calf diarrhea using next-generation sequencing. BMC Vet. Res., 21: 464.
- Kim S-J, Jin X-C, Bharanidharan R, Kim N-Y (2024). Monitoring multiple behaviors in beef calves raised in cow–calf contact systems using a machine learning approach. Animals, 14(22), 3278. https://doi.org/10.3390/ani14223278. [CrossRef]
- Li J, Zhao Q, Wang H, Sun Y (2023). Detection of calf abnormal respiratory behavior based on frame difference and improved YOLOv5 method. Comput. Electron. Agric., 213: 108248. [CrossRef]
- Madureira FM, Santos B, Skarbek A, Mills C, Thom H, Prentice D, McConnel C, Leal Yepes FA (2024). Bovine respiratory disease in post-weaning calves under different prevention strategies. Animals, 14(19): 2807.
- Moreira DM, Rocha C, Aguirre R, Ballou MA, Machado VS (2026). Associations of diarrhea and bovine respiratory disease with growth, feed intake, and mortality during the preweaning period of Holsteins and beef-on-dairy calves. J. Dairy Sci., 109(2): 1831–1842. [CrossRef]
- Neethirajan S (2020). Recent advances in wearable sensors for animal health management. Sens. Bio-Sens. Res., 27: 100305.
- Neethirajan S, Kemp B (2024). Artificial intelligence and sensor technologies in smart livestock farming: A review. Comput. Electron. Agric., 214: 108264.
- O’Neill M (2021). A systematic review of automatic health monitoring in calves: Glimpsing the future from current practice. Prevent. Vet. Med., 193: 105398.
- Rahman MA, Islam MS, Hossain MJ (2024). IoT-based health monitoring system for livestock using machine learning techniques. Sensors, 24(5): 1987.
- Sedky D, Ghazy AA, Abou-Zeina HAA (2025). Advances in diagnosis of diseases causing diarrhea in newborn calves. https://doi.org/10.1007/s11259-025-10855-0. [CrossRef]
- Sprygin A, Pestova Y, Prutnikov P, Kononov A (2024). Lumpy skin disease virus isolation and experimental infection in calves. Sci. Rep., 14: 10987.
- Sun D, Webb L, van der Tol PPJ, van Reenen CG (2021). Automatic health monitoring in calves: A systematic review. Front. Vet. Sci., 8: 761468.
- Svensson C, Hultgren J, Olsson SO (2023). Longitudinal study of calf morbidity and mortality and associated risk factors. BMC Vet. Res., 19: 87.
- Tanush Tambea (n.d.). Calf coccidiosis dataset. Kaggle. https://www.kaggle.com/datasets/tanushtambea/calf-coccidiosis
- Wolfger B, Timsit E, White BJ, Orsel K (2025). Machine learning approaches for prediction of bovine respiratory disease in feedlot cattle. Comput. Electron. Agric., 222: 108123.
- Yu Z, Han Y, Cha L, Chen S, Wang Z, Zhang Y (2024). Design of an intelligent wearable device for real-time cattle health monitoring. Front. Robotics AI, 11: 1441960. [CrossRef]

Services
Article usage statistics
Loading…
Related articles
- Automated Detection of Lumpy Skin Disease in Cattle Using Augmented Local Binary Patterns, Gabor Wavelets and Ensemble LearningJournal of Animal Health and Production · 2026
- IoT-SIWM: IoT Enabled Smart Irrigation System Based on Water Meter Using Mathematical ModelsJournal of Engineering and Applied Sciences · 2025
- A Video Surveillance-Based Framework for Early Detection of Lumpy Skin Disease in Cattle Using Haar Cascade and Ensemble LearningPakistan Journal of Zoology · 2026
- Towards Sustainable Living: IoT Enabled Predictive Approach for Domestic SolutionJournal of Engineering and Applied Sciences · 2026
- Development and Validation of Internet of Things (IoT) based Automated System for Controlling the Environmental Factors in Tunnel FarmingSarhad Journal of Agriculture · 2021
- Ranking of Internet of Things (IOT) Applications in Dairy Cattle Industry Productivity: A Multi Criteria Decision Making Approach and Thematic AnalysisPakistan Journal of Zoology · 2023
