# Water Level Prediction Model Applying a Long Short-Term Memory (LSTM)–Gated Recurrent Unit (GRU) Method for Flood Prediction

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Methodology

#### 2.1. Study Area

#### 2.2. Meteorological Dataset and Water Level Dataset

#### 2.3. LSTM (Long Short-Term Memory)

#### 2.4. GRU (Gated Recurrent Units)

#### 2.5. Performance Indicators

## 3. Experiment and Model Design

#### 3.1. Preliminary Experiment

#### 3.1.1. Model Composition Experiment for Selecting a Performance Comparison Model

#### 3.1.2. Comparative Experiment according to the Size of the Number of Units in the LSTM-GRU Model

#### 3.1.3. Comparative Experiment according to Input Data Size

#### 3.2. Experimental Design

#### 3.3. Model Structures

## 4. Results

#### 4.1. Training and Validation Result

#### 4.2. Test Result

## 5. Discussion

## 6. Conclusions

## Author Contributions

## Funding

## Institutional Review Board Statement

## Informed Consent Statement

## Data Availability Statement

## Acknowledgments

## Conflicts of Interest

## References

- Intergovernmental Panel on Climate Change (IPCC). Special Report on Managing the Risks of Extreme Events and Disasters to Advance Climate Change Adaptation; IPCC: Geneva, Switzerland, 2012. [Google Scholar]
- IPCC. Special Report on the Ocean and Cryosphere in a Changing Climate; IPCC: Geneva, Switzerland, 2019. [Google Scholar]
- Centre for Research on the Epidemiology of Disasters(CRED); United Nations Office for Disaster Risk Reduction (UNDRR). The Human Cost of Disasters: An Overview of the Last 20 Years (2000–2019); CRED: Brussels, Belgium; UNDRR: Geneva, Switzerland, 2020. [Google Scholar]
- Van Oldenborgh, G.J.; Van Der Wiel, K.; Sebastian, A.; Singh, R.; Arrighi, J.; Otto, F.; Haustein, K.; Li, S.; Vecchi, G.; Cullen, H. Attribution of extreme rainfall from Hurricane Harvey, August 2017. Environ. Res. Lett.
**2017**, 12, 124009. [Google Scholar] [CrossRef] - Lee, J.; Eo, G.; Choi, C.; Jung, J.; Kim, H.S. Development of Rainfall-Flood Damage Estimation Function using Nonlinear Regression Equation. J. Soc. Disaster Inf.
**2016**, 12, 74–88. [Google Scholar] - Flack, D.L.; Skinner, C.J.; Hawkness-Smith, L.; O’Donnell, G.; Thompson, R.J.; Waller, J.A.; Chen, A.S.; Moloney, J.; Largeron, C.; Xia, X.; et al. Recommendations for improving integration in national end-to-end flood forecasting systems: An overview of the FFIR (Flooding From Intense Rainfall) programme. Water
**2019**, 11, 725. [Google Scholar] [CrossRef][Green Version] - Nam, D.H.; Mai, D.T.; Udo, K.; Mano, A. Short-term flood inundation prediction using hydrologic-hydraulic models forced with downscaled rainfall from global NWP. Hydrol. Processes
**2014**, 28, 5844–5859. [Google Scholar] [CrossRef] - Zhao, R.-J. The Xinanjiang model applied in China. J. Hydrol.
**1992**, 135, 371–381. [Google Scholar] [CrossRef] - Pierini, N.A.; Vivoni, E.R.; Robles-Morua, A.; Scott, R.L.; Nearing, M.A. Using observations and a distributed hydrologic model to explore runoff thresholds linked with mesquite encroachment in the Sonoran Desert. Water Resour. Res.
**2014**, 50, 8191–8215. [Google Scholar] [CrossRef][Green Version] - Kabir, M.A.; Dutta, D.; Hironaka, S. Estimating sediment budget at a river basin scale using a process-based distributed modelling approach. Water Resour. Manag.
**2014**, 28, 4143–4160. [Google Scholar] [CrossRef] - Rogger, M.; Viglione, A.; Derx, J.; Blöschl, G. Quantifying effects of catchments storage thresholds on step changes in the flood frequency curve. Water Resour. Res.
**2013**, 49, 6946–6958. [Google Scholar] [CrossRef] - Kaya, C.M.; Tayfur, G.; Gungor, O. Predicting flood plain inundation for natural channels having no upstream gauged stations. J. Water Clim. Chang.
**2019**, 10, 360–372. [Google Scholar] [CrossRef] - Ding, Y.; Zhu, Y.; Feng, J.; Zhang, P.; Cheng, Z. Interpretable spatio-temporal attention LSTM model for flood forecasting. Neurocomputing
**2020**, 403, 348–359. [Google Scholar] [CrossRef] - LeCun, Y.; Bengio, Y.; Hinton, G. Deep learning. Nature
**2015**, 521, 436–444. [Google Scholar] [CrossRef] [PubMed] - Shen, D.; Wu, G.; Suk, H.I. Deep learning in medical image analysis. Annu. Rev. Biomed. Eng.
**2017**, 19, 221–248. [Google Scholar] [CrossRef] [PubMed][Green Version] - Zhao, Y.; Li, J.; Yu, L. A deep learning ensemble approach for crude oil price forecasting. Energy Econ.
**2017**, 66, 9–16. [Google Scholar] [CrossRef] - Nelson, D.M.Q.; Pereira, A.C.M.; de Oliveira, R.A. Stock market’s price movement prediction with LSTM neural networks. In Proceedings of the International Joint Conference on Neural Networks (IJCNN), Anchorage, AK, USA, 14–19 May 2017; pp. 1419–1426. [Google Scholar]
- Qiao, W.; Tian, W.; Tian, Y.; Yang, Q.; Wang, Y.; Zhang, J. The forecasting of PM2.5 using a hybrid model based on wavelet transform and an improved deep learning algorithm. IEEE Access
**2019**, 7, 142814–142825. [Google Scholar] [CrossRef] - Li, Y.; Cao, H. Prediction for tourism flow based on LSTM neural network. Procedia Comput. Sci.
**2018**, 129, 277–283. [Google Scholar] [CrossRef] - Yanjie, D.; Yisheng, L.; Fei-Yue, W. Travel time prediction with LSTM neural network. In Proceedings of the IEEE 19th International Conference on Intelligent Transportation Systems (ITSC), Rio de Janeiro, Brazil, 1–4 November 2016; pp. 1053–1058. [Google Scholar]
- Panigrahi, B.K.; Das, S.; Nath, T.K.; Senapati, M.R. An application of data mining techniques for flood forecasting: Application in rivers Daya and Bhargavi, India. J. Inst. Eng. (India) Ser. B
**2018**, 99, 331–342. [Google Scholar] [CrossRef] - Geem, Z.W.; Kim, J.H.; Loganathan, G.V. A new heuristic optimization algorithm: Harmony search. Simulation
**2001**, 76, 60–68. [Google Scholar] [CrossRef] - Das, S.; Suganthan, P.N. Differential evolution: A survey of the state-of-the-art. IEEE Trans. Evol. Comput.
**2010**, 15, 4–31. [Google Scholar] [CrossRef] - Park, J.; Sandberg, I.W. Universal approximation using radial-basis-function networks. Neural Comput.
**1991**, 3, 246–257. [Google Scholar] [CrossRef] - Gardner, M.W.; Dorling, S.R. Artificial neural networks (the multilayer perceptron)—A review of applications in the atmospheric sciences. Atmos. Environ.
**1998**, 32, 2627–2636. [Google Scholar] [CrossRef] - Bande, S.; Shete, V.V. Smart flood disaster prediction system using IoT & neural networks. In Proceedings of the International Conference on Smart Technologies for Smart Nation (SmartTechCon), Bengaluru, India, 17–19 August 2017; pp. 189–194. [Google Scholar]
- Sahagun, M.A.M.; Cruz, J.C.D.; Garcia, R.G. Wireless sensor nodes for flood forecasting using artificial neural network. In Proceedings of the International Conference on Humanoid, Nanotechnology, Information Technology, Communication and Control, Environment and Management (HNICEM), Manila, Philippines, 1–3 December 2017; pp. 1–6. [Google Scholar]
- Khatibi, R.; Ghorbani, M.A.; Pourhosseini, F.A. Stream flow predictions using nature-inspired Firefly Algorithm Algorithms and Algorithm a Multiple Model strategy–Directions of innovation towards next generation practices. Adv. Eng. Inform.
**2017**, 34, 80–89. [Google Scholar] [CrossRef] - Keong, K.C.; Mustafa, M.; Mohammad, A.J.; Sulaiman, M.H.; Abdullah, N.R.H. Artificial neural network flood prediction for sungai isap residence. In Proceedings of the International Conference on Automatic Control and Intelligent Systems (I2CACIS), Shah Alam, Malaysia, 22 October 2016; pp. 236–241. [Google Scholar]
- Abu Bakar, M.A.; Abdul Aziz, F.A.; Mohd Hussein, S.F.; Abdullah, S.S.; Ahmad, F. Flood water level modeling and prediction using radial basis function neural network: Case study Kedah. In Proceedings of the Asian Simulation Conference, Singapore, 26 August 2017; pp. 225–234. [Google Scholar]
- Maspo, N.A.; Harun, A.N.B.; Goto, M.; Cheros, F.; Haron, N.A.; Nawi, M.N.M. Evaluation of Machine Learning approach in flood prediction scenarios and its input parameters: A systematic review. IOP Conf. Ser. Earth Environ. Sci.
**2020**, 479, 012038. [Google Scholar] [CrossRef] - Liu, C.; Guo, L.; Ye, L.; Zhang, S.; Zhao, Y.; Song, T. A review of advances in China’s flash flood early-warning system. Nat. Hazards
**2018**, 92, 619–634. [Google Scholar] [CrossRef][Green Version] - Govindaraju, R.S. Artificial neural networks in hydrology. I: Preliminary concepts. J. Hydrol. Eng.
**2000**, 5, 115–123. [Google Scholar] - Mijwel, M.M. Artificial Neural Networks Advantages and Disadvantages. Available online: https://www.linkedin.com/pulse/artificial-neural-networks-advantages-disadvantages-maad-m-mijwel (accessed on 27 January 2018).
- Le, X.H.; Ho, H.V.; Lee, G.; Jung, S. Application of long short-term memory (LSTM) neural network for flood forecasting. Water
**2019**, 11, 1387. [Google Scholar] [CrossRef][Green Version] - Nash, J.E.; Sutcliffe, J.V. River flow forecasting through conceptual models Part I—A discussion of principles. J. Hydrol. Eng.
**1970**, 10, 282–290. [Google Scholar] [CrossRef] - Liu, M.; Huang, Y.; Li, Z.; Tong, B.; Liu, Z.; Sun, M.; Jiang, F.; Zhang, H. The applicability of LSTM-KNN model for real-time flood forecasting in different climate zones in China. Water
**2020**, 12, 440. [Google Scholar] [CrossRef][Green Version] - Ding, Y.; Zhu, Y.; Wu, Y.; Jun, F.; Cheng, Z. Spatio-temporal attention LSTM model for flood forecasting. In Proceedings of the International Conference on Internet of Things (IThings) and IEEE Green Computing and Communications (GreenCom) and IEEE Cyber, Physical and Social Computing (CPSCom) and IEEE Smart Data (SmartData), Atlanta, GA, USA, 14–17 July 2019; pp. 458–465. [Google Scholar]
- Song, T.; Ding, W.; Wu, J.; Liu, H.; Zhou, H.; Chu, J. Flash flood forecasting based on long short-term memory networks. Water
**2019**, 12, 109. [Google Scholar] [CrossRef][Green Version] - Gao, S.; Huang, Y.; Zhang, S.; Han, J.; Wang, G.; Zhang, M.; Lin, Q. Short-term runoff prediction with GRU and LSTM networks without requiring time step optimization during sample generation. J. Hydrol.
**2020**, 589, 125188. [Google Scholar] [CrossRef] - Muhammad, A.U.; Li, X.; Feng, J. Using LSTM GRU and hybrid models for streamflow forecasting. In Machine Learning and Intelligent Communications. MLICOM 2019. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering; Zhai, X., Chen, B., Zhu, K., Eds.; Springer: Cham, Switzerland, 2019; Volume 294, pp. 510–524. [Google Scholar]
- Miau, S.; Hung, W.H. River flooding forecasting and anomaly detection based on deep learning. IEEE Access
**2020**, 8, 198384–198402. [Google Scholar] [CrossRef] - Ebtehaj, I.; Sammen, S.S.; Sidek, L.M.; Sihag, P.; Al-Janabi, A.M.S.; Chau, K.W.; Bonakdari, H. Prediction of Daily Water Level Using New Hybridized GS-GMDH and ANFIS-FCM Models. Eng. Appl. Comput. Fluid Mech.
**2021**, 15, 1343–1361. [Google Scholar] [CrossRef] - Fu, M.; Fan, T.; Ding, Z.; Salih, S.Q.; Al-Ansari, N.; Yaseen, Z.M. Deep Learning Data-Intelligence Model Based on Adjusted Forecasting Window Scale: Application in Daily Streamflow Simulation. IEEE Access
**2020**, 8, 32632–32651. [Google Scholar] [CrossRef] - Water Resources Management Information System (WAMIS). Available online: http://www.wamis.go.kr/ (accessed on 10 June 2022).
- Korea Meteorological Administration Weather Data Service. Available online: https://data.kma.go.kr/ (accessed on 10 June 2022).
- Hochreiter, S.; Schmidhuber, J. Long short-term memory. Neural Comput.
**1997**, 9, 1735–1780. [Google Scholar] [CrossRef] - Pascanu, R.; Mikolov, T.; Bengio, Y. On the difficulty of training recurrent neural networks. In Proceedings of the 30th International Conference on Machine Learning, Atlanta, GA, USA, 16–21 June 2013; pp. 1310–1318. [Google Scholar]
- Hochreiter, S. The vanishing gradient problem during learning recurrent neural nets and problem solutions. Int. J. Uncertain. Fuzziness Knowl. -Based Syst.
**1998**, 6, 107–116. [Google Scholar] [CrossRef][Green Version] - Chung, J.; Gulcehre, C.; Cho, K.; Bengio, Y. Empirical evaluation of gated recurrent neural networks on sequence modeling. arXiv
**2014**, arXiv:1412.3555. [Google Scholar]

**Figure 1.**Total disaster events by type: 1980–1999 vs. 2000–2019 from Ref. [3].

**Figure 5.**Automated Synoptic Observing System (ASOS) and Automatic Weather System (AWS) Data Quality Graph.

Stations | Type | Latitude | Longitude | Measurement Variable | Period (Measured Hourly) |
---|---|---|---|---|---|

Yeojubo upstream | Hydrology | 37°19′56 | 127°36′34 | Water level | 2 October 2013~ 9 June 2022 |

Yeojubo downstream | Hydrology | 37°19′12 | 127°36′43 | Water level | |

AWS Yeoju | Meteorology | 37°16′07 | 127°38′22 | Temperature, humidity, precipitation | |

ASOS Icheon | Meteorology | 37°15′50 | 127°29′03 | Temperature, humidity, precipitation |

Model | Case | Details of Input Variable | Meteorology Data Type |
---|---|---|---|

Multi LSTM | S1_LSTM | Upstream water level, downstream water level | ― |

S2_LSTM | Upstream water level, downstream water level, temperature, humidity, rainfall | AWS | |

S3_LSTM | Upstream water level, downstream water level, temperature, humidity, rainfall | ASOS | |

Multi GRU | S1_GRU | Upstream water level, downstream water level | ― |

S2_GRU | Upstream water level, downstream water level, temperature, humidity, rainfall | AWS | |

S3_GRU | Upstream water level, downstream water level, temperature, humidity, rainfall | ASOS | |

LSTM-GRU | S1_LSTM_GRU | Upstream water level, downstream water level | ― |

S2_LSTM_GRU | Upstream water level, downstream water level, temperature, humidity, rainfall | AWS | |

S3_LSTM_GRU | Upstream water level, downstream water level, temperature, humidity, rainfall | ASOS |

Case | Hyperparameter | Training Time | Train MSE (cm) | Validation MSE (cm) |
---|---|---|---|---|

S1_LSTM | 790,785 | 2510.91 s | 0.22 | 0.31 |

S2_LSTM | 793,857 | 2492.76 s | 0.19 | 0.38 |

S3_LSTM | 793,857 | 2606.77 s | 0.18 | 0.34 |

S1_GRU | 594,689 | 2072.76 s | 0.22 | 0.49 |

S2_GRU | 596,993 | 2141.85 s | 0.48 | 1.75 |

S3_GRU | 596,993 | 2305.55 s | 0.39 | 1.80 |

S1_LSTM_GRU | 660,225 | 2331.33 s | 0.60 | 1.74 |

S2_LSTM_GRU | 663,297 | 2343.19 s | 0.17 | 0.28 |

S3_LSTM_GRU | 663,297 | 2493.50 s | 0.15 | 0.19 |

Case | Test MSE (cm) | Test NSE | Test MAE (cm) | Maximum Prediction(cm) | Highest Water Level Prediction Error (cm) |
---|---|---|---|---|---|

S1_LSTM | 5.02 | 0.917 | 2.74 | 3461.11 | 91.27 |

S2_LSTM | 4.73 | 0.834 | 3.32 | 3434.51 | 117.87 |

S3_LSTM | 4.88 | 0.905 | 2.35 | 3458.91 | 93.47 |

S1_GRU | 7.73 | 0.835 | 3.93 | 3467.36 | 85.02 |

S2_GRU | 5.65 | 0.430 | 3.36 | 3457.38 | 95 |

S3_GRU | 5.89 | 0.315 | 6.22 | 3340.61 | 211.77 |

S1_LSTM_GRU | 3.95 | 0.864 | 2.84 | 3466.67 | 85.71 |

S2_LSTM_GRU | 5.02 | 0.920 | 2.88 | 3466.74 | 79.64 |

S3_LSTM_GRU | 3.92 | 0.942 | 2.22 | 3490.36 | 55.49 |

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |

© 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Cho, M.; Kim, C.; Jung, K.; Jung, H.
Water Level Prediction Model Applying a Long Short-Term Memory (LSTM)–Gated Recurrent Unit (GRU) Method for Flood Prediction. *Water* **2022**, *14*, 2221.
https://doi.org/10.3390/w14142221

**AMA Style**

Cho M, Kim C, Jung K, Jung H.
Water Level Prediction Model Applying a Long Short-Term Memory (LSTM)–Gated Recurrent Unit (GRU) Method for Flood Prediction. *Water*. 2022; 14(14):2221.
https://doi.org/10.3390/w14142221

**Chicago/Turabian Style**

Cho, Minwoo, Changsu Kim, Kwanyoung Jung, and Hoekyung Jung.
2022. "Water Level Prediction Model Applying a Long Short-Term Memory (LSTM)–Gated Recurrent Unit (GRU) Method for Flood Prediction" *Water* 14, no. 14: 2221.
https://doi.org/10.3390/w14142221