Abstract
Groundwater level prediction is important for effective water management. Accurately predicting groundwater levels allows decision-makers to make informed decisions about water allocation, groundwater abstraction rates, and groundwater recharge strategies. This study presents a novel model, the self-attention (SA) temporal convolutional network (SATCN)-long short-term memory neural network (SATCN-LSTM), for groundwater level prediction. The SATCN-LSTM model combines the advantages of the SATCN and LSTM models to overcome the limitations of the LSTM model. By utilizing skip connections and self-attention mechanisms, the SATCN model addresses the vanishing gradient problem, identifies relevant data, and captures both short- and long-term dependencies in time series data. By demonstrating the improved performance of the SATCN-LSTM model in terms of mean absolute error and root mean square error (RMSE), and by comparing these results with those reported in previous papers, we have highlighted the advancements and contributions of the proposed model. By improving prediction accuracy, the SATCN-LSTM model enables decision-makers to make informed choices regarding water allocation, groundwater abstraction rates, and drought preparedness. The SATCN-LSTM model contributes to the sustainable and efficient use of groundwater resources by providing reliable information for decision-making processes. The SATCN-LSTM model combines the temporal convolutional network (TCN) architecture with LSTM. TCN is known for its ability to capture short-term dependencies in time series data, while LSTM is effective at capturing long-term dependencies. By integrating both architectures, the SATCN-LSTM model can capture the complex temporal relationships at different scales, leading to improved prediction accuracy. Meteorological data were used to predict GWL. The SATCN-LSTM model outperformed the other models. The SATCN-LSTM model had the lowest mean absolute error (MAE) of 0.09, followed by the self-attention (SA) temporal convolutional network (SATCN) model with an MAE of 0.12. The SALSTM model had an MAE of 0.16, while the TCN-LSTM, temporal convolutional network (TCN), and LSTM models had MAEs of 0.17, 0.22, and 0.23, respectively. The SATCN-LSTM model had the lowest root mean square error of 0.14, followed by SATCN with an RMSE of 0.15. The study results indicated that the SATCN-LSTM model was a robust tool for predicting groundwater level.
Similar content being viewed by others
Data availability
Data will be made available on request.
References
Adibimanesh B, Polesek-Karczewska S, Bagherzadeh F, Szczuko P, Shafighfard T (2023) Energy consumption optimization in wastewater treatment plants: Machine learning for monitoring incineration of sewage sludge. Sustainable Energy Technol Assess. https://doi.org/10.1016/j.seta.2023.103040
Afshari Nia M, Panahi F, Ehteram M (2023) Convolutional neural network-ANN-E (Tanh): a new deep learning model for predicting rainfall. Water Resour Manage 37(4):1785–1810
Al-Janabi S, Al-Barmani Z (2023) Intelligent multi-level analytics of soft computing approach to predict water quality index (IM12CP-WQI). Soft Comput. https://doi.org/10.1007/s00500-023-07953-z
Al-Janabi S, Alkaim AF (2020) A nifty collaborative analysis to predicting a novel tool (DRFLLS) for missing values estimation. Soft Computing 24(1):555–569. https://doi.org/10.1007/s00500-019-03972-x
Al-Janabi S, Mohammad M, Al-Sultan A (2020) A new method for prediction of air pollution based on intelligent computation. Soft Comput. https://doi.org/10.1007/s00500-019-04495-1
Al-Janabi ZK, Al-Janabi S (2023) An Efficient Predictor of Renewable Energy Based on Deep Learning Technique (DGBM) and Multi-Objectives Optimization Function. https://doi.org/10.1109/iiccit55816.2022.10010380
Bagherzadeh F, Mehrani MJ, Basirifard M, Roostaei J (2021) Comparative study on total nitrogen prediction in wastewater treatment plant and effect of various feature selection methods on machine learning algorithms performance. Journal of Water Process Engineering. https://doi.org/10.1016/j.jwpe.2021.102033
Bala R, Singh RP (2022) AA dual-stage advanced deep learning algorithm for long-term and long-sequence prediction for multivariate financial time series. Appl Soft Comput 126:109317
Banadkooki FB, Ehteram M, Ahmed AN et al (2020) Enhancement of groundwater-level prediction using an integrated machine learning model optimized by Whale Algorithm. Nat Resour Res 29:3233–3252. https://doi.org/10.1007/s11053-020-09634-2
Bowes BD, Sadler JM, Morsy MM, Behl M, Goodall JL (2019) Forecasting groundwater table in a flood prone coastal city with long short-term memory and recurrent neural networks. Water (switzerland). https://doi.org/10.3390/w11051098
Cai P, Zhang C, Chai J (2023) Forecasting hourly PM2.5 concentrations based on decomposition-ensemble-reconstruction framework incorporating deep learning algorithms. Data Science and Management. https://doi.org/10.1016/j.dsm.2023.02.002
de Almeida BA, Mostafavi A (2016) Resilience of infrastructure systems to sea-level rise in coastal areas: Impacts, adaptation measures, and implementation challenges. Sustainability 8(11):1115. https://doi.org/10.3390/su8111115
Ehtearm M, Ghayoumi Zadeh H, Seifi A, Fayazi A, Dehghni M (2023) Predicting hydropower production using deep learning CNN-ANN hybridized with gaussian process regression and salp algorithm. Water Resour Manage. https://doi.org/10.1007/s11269-023-03521-0
Ghanbari-Adivi E, Ehteram M, Farrokhi A, Sheikh Khozani Z (2022) Combining radial basis function neural network models and inclusive multiple models for predicting suspended sediment loads. Water Resour Manage 36(11):4313–4342
Ghasemlounia R, Gharehbaghi A, Ahmadi F, Saadatnejadgharahassanlou H (2021) Developing a novel framework for forecasting groundwater level fluctuations using Bi-directional Long Short-Term Memory (BiLSTM) deep neural network. Comput Electron Agric. https://doi.org/10.1016/j.compag.2021.106568
Gholami M, Ghanbari-Adivi E, Ehteram M, Singh VP, Ahmed AN, Mosavi A, El-Shafie A (2023) Predicting longitudinal dispersion coefficient using ensemble models and optimized multi-layer perceptron models. Ain Shams Eng J p. 102223. https://doi.org/10.1016/j.asej.2023.102223
Jalil-Masir H, Fattahi R, Ghanbari-Adivi E et al (2022) An inclusive multiple model for predicting total sediment transport rate in the presence of coastal vegetation cover based on optimized kernel extreme learning models. Environ Sci Pollut Res 29:67180–67213. https://doi.org/10.1007/s11356-022-20472-y
Kadhuim ZA, Al-Janabi S (2023a) Intelligent deep analysis of DNA sequences based on FFGM to enhancement the performance and reduce the computation. Egyptian Informatics Journal. https://doi.org/10.1016/j.eij.2023.02.004
Kadhuim ZA, Al-Janabi S (2023b) Codon-mRNA prediction using deep optimal neurocomputing technique (DLSTM-DSN-WOA) and multivariate analysis. Results Eng. https://doi.org/10.1016/j.rineng.2022.100847
Khan J, Lee E, Balobaid AS, Kim K (2023) A Comprehensive Review of Conventional, Machine Leaning, and Deep Learning Models for Groundwater Level (GWL) Forecasting. In Applied Sciences (switzerland). https://doi.org/10.3390/app13042743
Khozani ZS, Banadkooki FB, Ehteram M, Ahmed AN, El-Shafie A (2022) Combining autoregressive integrated moving average with Long Short-Term Memory neural network and optimisation algorithms for predicting ground water level. J Clean Prod 348:131224
Kim D, Jang C, Choi J, Kwak J (2023) A Case Study: Groundwater Level Forecasting of the Gyorae Area in Actual Practice on Jeju Island Using Deep-Learning Technique. Water (switzerland). https://doi.org/10.3390/w15050972
Le XH, Ho HV, Lee G, Jung S (2019) Application of Long Short-Term Memory (LSTM) neural network for flood forecasting. Water (Switzerland). https://doi.org/10.3390/w11071387
Lee T, Shin JY, Kim JS, Singh VP (2020) Stochastic simulation on reproducing long-term memory of hydroclimatological variables using deep learning model. J Hydrol. https://doi.org/10.1016/j.jhydrol.2019.124540
Li W, Qi F, Tang M, Yu Z (2020) Bidirectional LSTM with self-attention mechanism and multi-channel features for sentiment classification. Neurocomputing. https://doi.org/10.1016/j.neucom.2020.01.006
Liang J, Jia G (2022) China futures price forecasting based on online search and information transfer. Data Sci Manag. https://doi.org/10.1016/j.dsm.2022.09.002
Liang C, Li H, Lei M, Du Q (2018) Dongting Lake water level forecast and its relationship with the Three Gorges Dam based on a long short-term memory network. Water (switzerland). https://doi.org/10.3390/w10101389
Ling H, Qian C, Kang W, Liang C, Chen H (2019) Combination of Support Vector Machine and K-Fold cross validation to predict compressive strength of concrete in marine environment. Constr Build Mater. https://doi.org/10.1016/j.conbuildmat.2019.02.071
Luo F, Poslad S, Bodanese E (2020) Temporal Convolutional Networks for Multiperson Activity Recognition Using a 2-D LIDAR. IEEE Internet Things J. https://doi.org/10.1109/JIOT.2020.2984544
Mehrani MJ, Bagherzadeh F, Zheng M, Kowal P, Sobotka D, Mąkinia J (2022) Application of a hybrid mechanistic/machine learning model for prediction of nitrous oxide (N2O) production in a nitrifying sequencing batch reactor. Process Saf Environ Prot. https://doi.org/10.1016/j.psep.2022.04.058
Mozaffari S, Javadi S, Moghaddam HK, Randhir TO (2022) Forecasting Groundwater Levels using a Hybrid of Support Vector Regression and Particle Swarm Optimization. Water Resour Manage. https://doi.org/10.1007/s11269-022-03118-z
Noor F, Haq S, Rakib M, Ahmed T, Jamal Z, Siam ZS, Hasan RT, Adnan MSG, Dewan A, Rahman RM (2022) Water Level Forecasting Using Spatiotemporal Attention-Based Long Short-Term Memory Network. Water (switzerland). https://doi.org/10.3390/w14040612
Pham QB, Kumar M, Di Nunno F, Elbeltagi A, Granata F, Islam ARMT, Talukdar S, Nguyen XC, Ahmed AN, Anh DT (2022) Groundwater level prediction using machine learning algorithms in a drought-prone area. Neural Comput Appl. https://doi.org/10.1007/s00521-022-07009-7
Poojary R, Pai A (2019) Comparative study of model optimization techniques in fine-tuned CNN models. In 2019 International Conference on Electrical and Computing Technologies and Applications (ICECTA) (pp. 1–4). IEEE. https://doi.org/10.1109/ICECTA48151.2019.8959681
Rasel HM, Al Mamun MA, Hasnat A, Alam S, Hossain I, Mondal RK, Good RZ, Alsukaibi AKD, Awual MR (2023) Sustainable futures in agricultural heritage: Geospatial exploration and predicting groundwater-level variations in Barind tract of Bangladesh. Sci Total Environ. https://doi.org/10.1016/j.scitotenv.2022.161297
Samani S, Vadiati M, Azizi F, Zamani E, Kisi O (2022) Groundwater Level Simulation Using Soft Computing Methods with Emphasis on Major Meteorological Components. Water Resour Manage. https://doi.org/10.1007/s11269-022-03217-x
Sammen SS, Ehteram M, Sheikh Khozani Z, Sidek LM (2023) Binary Coati Optimization Algorithm-Multi-Kernel Least Square Support Vector Machine-Extreme Learning Machine Model (BCOA-MKLSSVM-ELM): A New Hybrid Machine Learning Model for Predicting Reservoir Water Level. Water 15(8):1593
Saud S, Jamil B, Upadhyay Y, Irshad K (2020) Performance improvement of empirical models for estimation of global solar radiation in India: A k-fold cross-validation approach. Sustainable Energy Technol Assess. https://doi.org/10.1016/j.seta.2020.100768
Shafighfard T, Bagherzadeh F, Rizi RA, Yoo DY (2022) Data-driven compressive strength prediction of steel fiber reinforced concrete (SFRC) subjected to elevated temperatures using stacked machine learning algorithms. J Market Res. https://doi.org/10.1016/j.jmrt.2022.10.153
Shao Z, Han J, Zhao W, Zhou K, Yang S (2022) Hybrid model for short-term wind power forecasting based on singular spectrum analysis and a temporal convolutional attention network with an adaptive receptive field. Energy Convers Manage 269:116138
Tang X, Chen H, Xiang W, Yang J, Zou M (2022) Short-term load forecasting using channel and temporal attention based temporal convolutional network. Electric Power Systems Research 205:107761
Tao H, Hameed MM, Marhoon HA, Zounemat-Kermani M, Heddam S, Sungwon K, Sulaiman SO, Tan ML, Sa’adi Z, Mehr AD, Allawi MF, Abba SI, Zain JM, Falah MW, Jamei M, Bokde ND, Bayatvarkeshi M, Al-Mukhtar M, Bhagat SK., … Yaseen ZM (2022) Groundwater level prediction using machine learning models: a comprehensive review. In Neurocomputing. https://doi.org/10.1016/j.neucom.2022.03.014
Tian C, Ma J, Zhang C, Zhan P (2018) A deep neural network model for short-term load forecast based on long short-term memory network and convolutional neural network. Energies. https://doi.org/10.3390/en11123493
Vu HL, Ng KTW, Richter A, An C (2022) Analysis of input set characteristics and variances on k-fold cross validation for a Recurrent Neural Network model on waste disposal rate estimation. J Environ Manage. https://doi.org/10.1016/j.jenvman.2022.114869
Wang K, Ma C, Qiao Y, Lu X, Hao W, Dong S (2021) A hybrid deep learning model with 1DCNN-LSTM-Attention networks for short-term traffic flow prediction. Physica A: Statistical Mechanics and Its Applications. https://doi.org/10.1016/j.physa.2021.126293
Xiang L, Liu J, Yang X, Hu A, Su H (2022) Ultra-short term wind power prediction applying a novel model named SATCN-LSTM. Energy Convers Manage. https://doi.org/10.1016/j.enconman.2021.115036
Zhang J, Zhu Y, Zhang X, Ye M, Yang J (2018) Developing a Long Short-Term Memory (LSTM) based model for predicting water table depth in agricultural areas. J Hydrol. https://doi.org/10.1016/j.jhydrol.2018.04.065
Zheng Y, Chen C, Wang R, Meng F (2022) Stability analysis of rock slopes subjected to block-flexure toppling failure using adaptive moment estimation method (Adam). Rock Mech Rock Eng 55(6):3675–3686
Author information
Authors and Affiliations
Contributions
Contribution: formal analysis: Elham Ghanbari Adivi Moahammad Ehteram, writing, review, and editing: Elham Ghanbari Adivi, Mohammad Ehteram.
Corresponding author
Ethics declarations
Consent to participate
All of authors agree to participate in the article.
Consent to publish
All of authors stated consent to publish.
Competing interests
There is no Competing Interests.
Additional information
Responsible Editor: Marcus Schulz
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
About this article
Cite this article
Ehteram, M., Ghanbari-Adivi, E. Self-attention (SA) temporal convolutional network (SATCN)-long short-term memory neural network (SATCN-LSTM): an advanced python code for predicting groundwater level. Environ Sci Pollut Res 30, 92903–92921 (2023). https://doi.org/10.1007/s11356-023-28771-8
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11356-023-28771-8