Deep learning-driven multiclass groundwater water quality index assessment using attention mechanisms

Assessing groundwater quality is essential for sustainable water resource management in arid regions, where hydrochemical processes are complex and monitoring resources are often limited. This study proposes a hybrid deep learning framework that integrates convolutional neural networks (CNNs) with transformer-based self-attention mechanisms for multiclass water quality index (WQI) classification. A dataset comprising 621 groundwater samples from the Bechar region in southwestern Algeria was analyzed using 12 hydrochemical parameters. To evaluate model robustness under different monitoring conditions, 12 feature combinations representing distinct hydrochemical groups were tested using both CNN and CNN–Transformer architectures. Model performance was assessed using accuracy, precision, recall, F1-score, the area under the receiver operating characteristic (ROC) curve (AUC), and an error-overlap Venn diagram. The CNN–Transformer consistently outperformed the conventional CNN across most configurations. The highest performance was achieved using the full hydrochemical profile, with an accuracy of 92.5% and a micro-AUC of 0.99. Because the WQI target was deterministically calculated from the same hydrochemical variables used as model inputs, the proposed framework should be interpreted as a surrogate WQI classification model rather than as an independent predictor of groundwater quality. Accordingly, the SHAP importance patterns partly reflect the adopted WQI formulation, including its parameter weights, regulatory limits, and class thresholds. Importantly, several reduced models based on only four to five commonly measured parameters also achieved strong predictive performance, with accuracies of up to approximately 0.85, demonstrating the potential of the proposed framework for streamlined groundwater monitoring when comprehensive laboratory analyses are unavailable.

Authors

Institutions

Publication Details

Journal
Environmental Earth Sciences
Published
2026-11-10
DOI
https://doi.org/10.1007/s12665-026-13130-w
Primary Topic
Water Quality and Pollution Assessment
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

Deep learning-driven multiclass groundwater water quality index assessment using attention mechanisms

Bilel Zeroualı, Sherif S. M. Ghoneim, Youssef M. Youssef, A. Derdour et al.
Environmental Earth Sciences
Water Quality and Pollution Assessment
article

Deep learning-driven multiclass groundwater water quality index assessment using attention mechanisms

Bilel Zeroualı, Sherif S. M. Ghoneim, Youssef M. Youssef, A. Derdour, Nadjem Bailek, Yong Jie Wong, Celso Augusto Guimarães Santos, Touhami Merzouguı, Tayyib Moussaoui
article en

Abstract

Assessing groundwater quality is essential for sustainable water resource management in arid regions, where hydrochemical processes are complex and monitoring resources are often limited. This study proposes a hybrid deep learning framework that integrates convolutional neural networks (CNNs) with transformer-based self-attention mechanisms for multiclass water quality index (WQI) classification. A dataset comprising 621 groundwater samples from the Bechar region in southwestern Algeria was analyzed using 12 hydrochemical parameters. To evaluate model robustness under different monitoring conditions, 12 feature combinations representing distinct hydrochemical groups were tested using both CNN and CNN–Transformer architectures. Model performance was assessed using accuracy, precision, recall, F1-score, the area under the receiver operating characteristic (ROC) curve (AUC), and an error-overlap Venn diagram. The CNN–Transformer consistently outperformed the conventional CNN across most configurations. The highest performance was achieved using the full hydrochemical profile, with an accuracy of 92.5% and a micro-AUC of 0.99. Because the WQI target was deterministically calculated from the same hydrochemical variables used as model inputs, the proposed framework should be interpreted as a surrogate WQI classification model rather than as an independent predictor of groundwater quality. Accordingly, the SHAP importance patterns partly reflect the adopted WQI formulation, including its parameter weights, regulatory limits, and class thresholds. Importantly, several reduced models based on only four to five commonly measured parameters also achieved strong predictive performance, with accuracies of up to approximately 0.85, demonstrating the potential of the proposed framework for streamlined groundwater monitoring when comprehensive laboratory analyses are unavailable.

Environmental Earth SciencesVol. 85(17)
Suez University (EG), University of Bechar (DZ), Universidade Federal da Paraíba (BR), Taif University (SA), Ahmed Draia University (DZ), Jadara University (JO), Ziane Achour University of Djelfa (DZ), Hassiba Benbouali University of Chlef (DZ), Al-Ayen Iraqi University (IQ), Centre de recherche en Agropastoralisme (CRAPast) (DZ), Kyoto University of Advanced Science (JP)
Water Quality and Pollution Assessment
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon