Rapid and reliable approach for detecting milk spoilage
Srushti Jamewar, Ritika Patki, Nishad Gharote, Tanika Mathur, Mridula Korde
Abstract
Milk spoilage poses a major challenge to food safety, public health, and sustainability, often resulting in unnecessary waste across households and dairy supply chains. Traditional detection methods, such as smelling or boiling, are subjective, delay early identification, and frequently lead to misjudgment. This study proposes a machine learning (ML)–based spoilage detection framework that integrates real-time pH and carbon monoxide (CO) sensor data to classify milk as fresh, not fresh, or spoiled. multiple supervised learning models, including random forest, eXtreme gradient boosting (XGBoost), support vector machine (SVM), and decision tree, were trained and evaluated using datasets collected from raw and boiled milk samples under varying conditions. Performance was assessed using coefficient of determination (R²), mean squared error (MSE), root mean squared error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE) metrics to identify the most reliable model for shelf-life prediction. Experimental results show that random forest and XGBoost outperform traditional threshold-based approaches, with random forest demonstrating superior consistency and operational efficiency. The findings highlight the potential of intelligent, low-cost sensor–ML systems to significantly enhance early spoilage detection, strengthen food safety, and reduce milk wastage across domestic and industrial environments.
Keywords
Carbon monoxide measurement; Machine learning; Milk quality prediction; Milk spoilage; pH measurement
DOI:
https://doi.org/10.11591/eei.v15i3.11094
Refbacks
There are currently no refbacks.
This work is licensed under a
Creative Commons Attribution-ShareAlike 4.0 International License .
<div class="statcounter"><a title="hit counter" href="http://statcounter.com/free-hit-counter/" target="_blank"><img class="statcounter" src="http://c.statcounter.com/10241695/0/5a758c6a/0/" alt="hit counter"></a></div>
Bulletin of EEI Stats
Bulletin of Electrical Engineering and Informatics (BEEI) ISSN: 2089-3191 , e-ISSN: 2302-9285 This journal is published by the Institute of Advanced Engineering and Science (IAES) in collaboration with Intelektual Pustaka Media Utama (IPMU) .