journal article·2023-11-14Open access

Portable Protein and Fat Detector in Milk Based on Multi-Spectral Sensor and Machine Learning

Yanyan Wang, Kaikai Zhang, Shengzhe Shi, Qingqing Wang, Sheng Liu

Applied Sciences· Volume 13· Issue 22

Abstract

To address the challenges of a long measurement period, high testing cost, and environmental pollution of traditional milk composition detection methods, a portable detection instrument was developed by combining multi-spectral sensors, machine learning algorithms, and an embedded system to rapidly detect the main components of milk. A broadband near-infrared (NIR) LED constant-current driver circuit and multi-spectral sensor module were designed to obtain six NIR features of milk samples. Based on a comparison of several machine learning algorithms, the XGBoost model was selected for training, and the trained model was ported to a Raspberry Pi unit for sample detection. The validation results showed that the coefficients of determination (R2) for the investigated protein and fat models were 0.9816 and 0.9978, respectively, and the corresponding mean absolute errors (MAE) were 0.0086 and 0.0079. Accurate measurement of protein and fat contents of milk can be facilitated in a short time interval by using the proposed low-cost portable instrument.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Advanced Chemical Sensor Technologies · Spectroscopy and Chemometric Analyses · Meat and Animal Product Quality

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

School of Computer Science and Technology, Huaibei Normal University, Huaibei 235000, China

Engineering Research Center of Cognitive Behavioral Intelligent Computing and Application, Huaibei 235000, China

Funding

2022 Graduate Innovation Fund of Huaibei Normal University · 2022 New Era Education Provincial Quality Engineering Project (Graduate Education)

References (43)

Show source-provided references
1. Trend analysis and prediction of seasonal changes in milk composition from a pasture-based dairy research herd10.3168/jds.2021-21483 ↗
2. Shim, H.W., Lee, W.Y., Kim, H.W., Park, J.K., Cho, K., Yeo, J.M., and Park, H.J. (2023). Physiological Effects of Hydrolyzed Skim Milk and Probiotics on Osteoporosis Models. Appl. Sci., 13.10.3390/app131810424 ↗
3. Milk and health10.1056/NEJMra1903547 ↗
4. Porous silicon Fabry–Pérot interferometer for N-acetyl-β-d-glucosaminidase biomarker monitoring10.1021/acssensors.0c00348 ↗
5. Measurement of casein in milk by Kjeldahl and sodium dodecyl sulfate–polyacrylamide gel electrophoresis10.3168/jds.2020-18794 ↗
6. Determination of fats, oils and greases in food service establishment wastewater using a modification of the Gerber method10.1111/wej.12431 ↗
7. Applications of liquid chromatography-mass spectrometry for food analysis10.1016/j.chroma.2012.04.023 ↗
8. Quantification of bovine milk protein composition and coagulation properties using infrared spectroscopy and chemometrics: A result of collinearity among reference variables10.3168/jds.2015-10840 ↗
9. Use of near and mid infra-red spectroscopy for analysis of protein, fat, lactose and total solids in raw cow and camel milk10.1016/j.foodchem.2020.127436 ↗
10. Mid-infrared prediction of bovine milk fatty acids across multiple breeds, production systems, and countries10.3168/jds.2010-3408 ↗
11. Genetic parameters of measures and population-wide infrared predictions of 92 traits describing the fine composition and technological properties of milk in Italian Simmental cattle10.3168/jds.2016-11667 ↗
12. Broadband laser-based mid-infrared spectroscopy employing a quantum cascade detector for milk protein analysis10.1016/j.snb.2021.130873 ↗
13. Zhao, X., Song, Y., Zhang, Y., Cai, G., Xue, G., Liu, Y., Chen, K., Zhang, F., Wang, K., and Zhang, M. (2023). Predictions of milk fatty acid contents by mid-infrared spectroscopy in Chinese Holstein cows. Molecules, 28.10.3390/molecules28020666 ↗
14. Online milk composition analysis with an on-farm near-infrared sensor10.1016/j.compag.2020.105734 ↗
15. Invited review: Use of infrared technologies for the assessment of dairy products—Applications and perspectives10.3168/jds.2018-15202 ↗
16. The recent advances of near-infrared spectroscopy in dairy production—A review10.1080/10408398.2020.1829540 ↗
17. Mancini, M., Mazzoni, L., Gagliardi, F., Balducci, F., Duca, D., Toscano, G., Mezzetti, B., and Capocasa, F. (2020). Application of the non-destructive NIR technique for the evaluation of strawberry fruits quality parameters. Foods, 9.10.3390/foods9040441 ↗
18. Nondestructive Evaluation of Banana Maturity Using NIR AS7263 Sensor10.1007/s10921-023-00943-z ↗
19. Comparison and optimization of models for determination of sugar content in pear by portable Vis-NIR spectroscopy coupled with wavelength selection algorithm10.1007/s12161-018-1326-7 ↗
20. Prediction of milk fatty acid composition by near infrared reflectance spectroscopy10.1016/j.idairyj.2009.11.003 ↗
21. Uusitalo, S., Diaz-Olivares, J., Sumen, J., Hietala, E., Adriaens, I., Saeys, W., Utriainen, M., Frondelius, L., Pastell, M., and Aernouts, B. (2021). Evaluation of MEMS NIR Spectrometers for On-Farm Analysis of Raw Milk Composition. Foods, 10.10.3390/foods10112686 ↗
22. System design for non-destructive near infrared analyses of chemical components and total aerobic bacteria count of raw milk10.1255/jnirs.807 ↗
23. Muñoz-Salinas, F., Andrade-Montemayor, H.M., De la Torre-Carbot, K., Duarte-Vázquez, M.Á., and Silva-Jarquin, J.C. (2022). Comparative analysis of the protein composition of goat milk from French Alpine, Nubian, and Creole breeds and Holstein Friesian cow milk: Implications for early infant nutrition. Animals, 12.10.3390/ani12172236 ↗
24. Detection of fat concentration in milk using ternary photonic crystal10.1007/s12633-021-01379-8 ↗
25. Almawgani, A.H., Daher, M.G., Taya, S.A., Mashagbeh, M., and Colak, I. (2022). Optical detection of fat concentration in milk using MXene-based surface plasmon resonance structure. Biosensors, 12.10.3390/bios12070535 ↗
26. A portable detector on main compositions of raw and homogenized milk10.1016/j.compag.2020.105668 ↗
27. Effectively predict the solar radiation transmittance of dusty photovoltaic panels through Lambert-Beer law10.1016/j.renene.2018.02.046 ↗
28. Chen, T., and Guestrin, C. (2016, January 13–17). Xgboost: A scalable tree boosting system. Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, San Francisco, CA, USA.10.1145/2939672.2939785 ↗
29. A review on linear regression comprehensive in machine learning10.38094/jastt1457 ↗
30. Ketkar, N., and Ketkar, N. (2017). Deep Learning with Python: A Hands-on Introduction, Apress.10.1007/978-1-4842-2766-4 ↗
31. Rozos, E., Dimitriadis, P., Mazi, K., and Koussis, A.D. (2021). A multilayer perceptron model for stochastic synthesis. Hydrology, 8.10.3390/hydrology8020067 ↗
32. Wang, L., Zhang, Y., Yao, Y., Xiao, Z., Shang, K., Guo, X., Yang, J., Xue, S., and Wang, J. (2021). Gbrt-based estimation of terrestrial latent heat flux in the haihe river basin from satellite and reanalysis datasets. Remote Sens., 13.10.3390/rs13061054 ↗
34. Selecting the most informative mid-infrared spectra wavenumbers to improve the accuracy of prediction models for detailed milk protein content10.3168/jds.2015-10318 ↗
35. Near-infrared spectroscopic sensing system for online monitoring of milk quality during milking10.1007/s11694-006-9001-x ↗
36. Determination of fat and total protein content in milk using conventional digital imaging10.1016/j.talanta.2013.12.055 ↗
37. Gastélum-Barrios, A., Soto-Zarazúa, G.M., Escamilla-García, A., Toledano-Ayala, M., Macías-Bobadilla, G., and Jauregui-Vazquez, D. (2020). Optical Methods Based on Ultraviolet, Visible, and Near-Infrared Spectra to Estimate Fat and Protein in Raw Milk: A Review. Sensors, 20.10.3390/s20123356 ↗
38. Simultaneous determination of goat milk adulteration with cow milk and their fat and protein contents using NIR spectroscopy and PLS algorithms10.1016/j.lwt.2020.109427 ↗
39. Methods to avoid over-fitting and under-fitting in supervised machine learning (comparative study)
40. Visible and near-infrared bulk optical properties of raw milk10.3168/jds.2015-9630 ↗
41. Dielectric properties of raw milk as functions of protein content and temperature10.1007/s11947-014-1440-5 ↗
42. The effect of storage temperature and duration on the microbial quality of bulk tank milk10.3168/jds.2015-10495 ↗
43. Biofilm formation in milk production and processing environments; influence on milk quality and safety10.1111/j.1541-4337.2011.00183.x ↗