Water Supply (Jan 2022)

BOD5 prediction using machine learning methods

  • Kai Sheng Ooi,
  • ZhiYuan Chen,
  • Phaik Eong Poh,
  • Jian Cui

DOI
https://doi.org/10.2166/ws.2021.202
Journal volume & issue
Vol. 22, no. 1
pp. 1168 – 1183

Abstract

Read online

Biological oxygen demand (BOD5) is an indicator used to monitor water quality. However, the standard process of measuring BOD5 is time consuming and could delay crucial mitigation works in the event of pollution. To solve this problem, this study employed multiple machine learning (ML) methods such as random forest (RF), support vector regression (SVR) and multilayer perceptron (MLP) to train a best model that can accurately predict the BOD5 values in water samples based on other physical and chemical properties of the water. The training parameters were optimized using genetic algorithm (GA) and feature selection was made using the sequential feature selection (SFS) method. The proposed machine learning framework was first tested on a public dataset (Waterbase). The MLP method produced the best model, with an R2 score of 0.7672791942775417, relative mean squared error (MSE) and relative mean absolute error (MAE) of approximately 15%. Feature importance calculations indicated that chemical oxygen demand (CODCr), ammonium and nitrate are features that highly correlate to BOD5. In the field study with a small private dataset consisting of water samples collected from two different lakes in Jiangsu Province of China, the trained model was found to have a similar range of prediction error (around 15%), a similar relative MAE (around 14%) and achieved about 6% better relative RMSE. Highlights Multiple machine learning (ML) methods used to train a best model to predict the BOD5 values in water samples.; Permutation feature importance (PFI) values calculated indicate that CODCr, ammonium and nitrate are features with the highest correlation with BOD5.; The best model trained using MLP yielded the best performance with an R2 score of 0.7672791942775417 together with relative RMSE and relative MAE of approximately 15%.;

Keywords