Authors: Daniel L. Weller | Tanzy Love | Martin Wiedmann
Source: Frontiers in Environmental Science (article, 2021-06-30)
Field: Chemistry — Analytical Chemistry

Comparison of Resampling Algorithms to Address Class Imbalance when Developing Machine Learning Models to Predict Foodborne Pathogen Presence in Agricultural Water Recent studies have shown that predictive models can supplement or provide alternatives to <i>E. coli</i>-testing for assessing the potential presence of food safety hazards in water used for produce production. However, these studies used balanced training data and focused on enteric pathogens. As such, research is needed to determine 1) if predictive models can be used to assess <i>Listeria</i> contamination of agricultural water, and 2) how resampling (to deal with imbalanced data) affects performance of these models. To address these knowledge gaps, this study developed models that predict nonpathogenic <i>Listeria</i> spp. (excluding <i>L. monocytogenes</i>) and <i>L. monocytogenes</i> presence in agricultural water using various combinations of learner (e.g., random forest, regression), feature type, and resampling method (none, oversampling, SMOTE). Four feature types were used in model training: microbial, physicochemical, spatial, and weather. "Full models" were trained using all four feature types, while "nested models" used between one and three types. In total, 45 full (15 learners*3 resampling approaches) and 108 nested (5 learners*9 feature sets*3 resampling approaches) models were trained per outcome. Model performance was compared against baseline models where <i>E. coli</i> concentration was the sole predictor. Overall, the machine learning models outperformed the baseline <i>E. coli</i> models, with random forests outperforming models built using other learners (e.g., rule-based learners). Resampling produced more accurate models than not resampling, with SMOTE models outperforming, on average, oversampling models. Regardless of resampling method, spatial and physicochemical water quality features drove accurate predictions for the nonpathogenic <i>Listeria</i> spp. and <i>L. monocytogenes</i> models, respectively. Overall, these findings 1) illustrate the need for alternatives to existing <i>E. coli</i>-based monitoring programs for assessing agricultural water for the presence of potential food safety hazards, and 2) suggest that predictive models may be one such alternative. Moreover, these findings provide a conceptual framework for how such models can be developed in the future with the ultimate aim of developing models that can be integrated into on-farm risk management programs. For example, future studies should consider using random forest learners, SMOTE resampling, and spatial features to develop models to predict the presence of foodborne pathogens, such as <i>L. monocytogenes</i>, in agricultural water when the training data is imbalanced. Resampling ; Machine learning ; Random forest ; Artificial intelligence ; Oversampling ; Feature (linguistics) ; Computer science ; Listeria monocytogenes ; Algorithm ; Biology Spectroscopy and Chemometric Analyses ; Food Safety and Hygiene ; Listeria monocytogenes in Food Safety