Related Experiment Video
Updated: Jun 10, 2026

Evaluation of Microbial Safety of Dairies using Bacterial Proteomic Profiling via MALDI Approach
Published on: October 7, 2025
Evaluating machine learning algorithms based on thermal imaging and milk-based parameters to identify subclinical
Sushil Paudyal1, Rajesh Neupane1, Bhuwan Shrestha1
1Texas A&M University, College Station, Texas, USA.
Insights
Machine learning effectively identifies subclinical mastitis (SCM) in dairy cows using thermal imaging and milk analysis. Combining both data types significantly improves SCM prediction accuracy.
Area of Science:
- Veterinary Medicine
- Animal Science
- Machine Learning Applications
Background:
- Subclinical mastitis (SCM) is a prevalent udder infection in dairy cows, impacting milk production and quality.
- Early detection of SCM is crucial for effective herd management and economic viability.
- Current diagnostic methods can be labor-intensive and may not always provide timely results.
Purpose of the Study:
- To evaluate the efficacy of machine learning algorithms for identifying SCM in dairy cows.
- To assess the combined potential of thermal imaging and milk-based parameters for SCM detection.
- To compare the performance of different machine learning classifiers in this diagnostic context.
Main Methods:
- Utilized data from 194 Holstein dairy cows, collecting 776 quarter-level milk samples and thermal images.
- Analyzed milk for parameters and extracted skin temperatures from infrared images.
- Applied Random Forest Classifier (RFC), Logistic Regression, AdaBoost Classifier (ABC), and Naïve Bayes algorithms to identify SCM (defined as SCC > 200,000 cells/mL).
Main Results:
- RFC models integrating milk and thermal features achieved high accuracy (0.88), precision (0.88), and AUC (0.90), with lactose and SNF as key predictors.
- The AdaBoost Classifier using only thermal imaging data showed lower performance (accuracy 0.82, precision 0.67, AUC 0.56).
- Milk lactose and solids-not-fat (SNF) were identified as highly important features for SCM prediction.
Conclusions:
- Machine learning models integrating thermal imaging and milk-based parameters offer a promising approach for accurate SCM detection in dairy cows.
- Combining diverse data sources enhances diagnostic performance compared to using thermal imaging alone.
- Further research with larger datasets and refined imaging techniques is recommended to validate these findings and improve SCM management strategies.
Abstract:
The objective was to evaluate the potential of machine learning algorithms utilizing thermal imaging and/or milk-based parameters for the identification of subclinical mastitis(SCM) in dairy cows. Holstein dairy cows (n = 194) were enrolled, and milk samples were collected from each quarter separately (n = 776 quarter-level samples) and analyzed for milk-based parameters. Four images per cow, representing all four quarters, were captured using a handheld infrared camera. Skin temperatures were extracted using Fluke Connect software, yielding 776 images for analysis. SCM was defined at the quarter level as SCC > 200,000 cells/mL, identifying 139 infected and 637 healthy quarters. The data were analyzed to test Random Forest Classifier(RFC), Logistic Regression Classifier, AdaBoost Classifier(ABC), and Naïve Bayes Classifier algorithms. The RFC models using milk features and temperature features achieved accuracy and precision scores of 0.88 and 0.88, respectively, yielding 0.90 AUC values, with high feature importance for milk lactose and SNF. Using only thermal imaging features, the ABC model yielded accuracy and precision of 0.82 and 0.67, respectively, with 0.56 AUC. We conclude that SCM prediction using machine learning algorithms is most promising when combined with thermal images and milk-based parameters. Future studies with larger datasets and refined methods for thermal image capture and analysis are warranted to validate these findings.

