Optimizing water quality index using machine learning: a six-year comparative study in riverine and reservoir systems
摘要
Human activities and climate change are intensifying threats to water quality, necessitating scientifically robust assessments to strengthen water resource management and ensure safe drinking water. However, the global application of WQI has increased significantly while facing persistent uncertainties in parameter weighting, aggregation functions, and model transparency. In this study, a comparative optimization framework using three machine learning algorithms, five weighting methods, and eight aggregation functions, was proposed for water quality index (WQI) model improvement. Two typical surface water systems, i.e., riverine and reservoir water bodies, were analyzed using six-year monthly data (2017–2022) from 31 sites in a typical mega hydro-engineering, the Danjiangkou Reservoir (DJKR) of China. Key findings include: (1) The Extreme Gradient Boosting (XGBoost) model achieved superior performance, and 97% accuracy for river sites (logarithmic loss: 0.12), which is excellent in scoring. (2)A new proposed WQI model, i.e., the Bhattacharyya mean WQI model (BMWQI) coupling with the Rank Order Centroid (ROC) weighting method, can significantly outperform other WQI models in reducing uncertainty, showing eclipsing rates for rivers and reservoirs at 17.62% and 4.35%, respectively. (3) For the case DJKR, key indicators included total phosphorus (TP), permanganate index, and ammonia nitrogen were effectively selected by the developed WQI model for rivers, and TP and water temperature were identified in reservoir area, respectively. This study improved surface water quality assessment methodology by integrating machine learning techniques and innovative aggregation functions. The framework demonstrates practical value for water quality policy formulation by enabling targeted identification of critical pollutants and optimizing monitoring efficiency through feature selection. Its adaptability to diverse aquatic systems underscores broad applicability across geographical regions.