Elsevier

Journal of Hydrology

Volume 599, August 2021, 126353
Journal of Hydrology

Research papers
A novel deep neural network architecture for real-time water demand forecasting

https://doi.org/10.1016/j.jhydrol.2021.126353Get rights and content

Highlights

  • A DNN structure based on GRU and k-means achieves a remarkable performance for WDF.

  • With help of k-means method, WDF accuracy is preserved with low cost of complexity.

  • Extending the data linearly reduces the prediction error at the extreme points.

Abstract

Short-term water demand forecasting (StWDF) is the foundation stone in the derivation of an optimal plan for controlling water supply systems. Deep learning (DL) approaches provide the most accurate solutions for this purpose. However, they suffer from complexity problem due to the massive number of parameters, in addition to the high forecasting error at the extreme points. In this work, an effective method to alleviate the error at these points is proposed. It is based on extending the data by inserting virtual data within the actual data to relieve the nonlinearity around them. To our knowledge, this is the first work that considers the problem related to the extreme points. Moreover, the water demand forecasting model proposed in this work is a novel DL model with relatively low complexity. The basic model uses the gated recurrent unit (GRU) to handle the sequential relationship in the historical demand data, while an unsupervised classification method, k-means, is introduced for the creation of new features to enhance the prediction accuracy with less number of parameters. Real data obtained from two different water plants in China are used to train and verify the model proposed. The prediction results and the comparison with the state-of-the-art illustrate that the method proposed reduces the complexity of the model six times of what achieved in the literature while conserving the same accuracy. Furthermore, it is found that extending the data set significantly reduces the error by about 30%. However, it increases the training time.

Introduction

Water scarcity has become a threat to humankind in recent decades. Many efforts in all possible directions are being made to compensate for this growing problem (Northey et al., 2016, González-Zeas et al., 2019). The major reliable strategies for that include water treatment (Zinatloo-Ajabshir et al., 2020), water desalination, and optimization of water management systems. Nanotechnology is the most powerful technology employed for water treatment, where researchers have done impressive work (Zinatloo-Ajabshir et al., 2020, Zinatloo-Ajabshir et al., 2017, Moshtaghi et al., 2016). On the other hand, StWDF is the foundation stone of the optimization of water management systems. Therefore, numerous researchers have directed their efforts towards this problem. Nowadays, deep learning (DL) is the most dominant approach, which provides the most promising solutions to a myriad of critical problems. To mention a few examples, Zhou (2020) has proposed deep learning method for forecasting the water quality in the presence of missing data. Friedel et al. (2020) have compared four machine learning methods to predict groundwater redox status in the agriculturally dominated regions of New Zealand. Wang et al. (2020) have used a deep belief network to forecast the depth of snow over in Alaska. Flood prediction is another crucial problem that utilizes deep learning approaches. An Encoder-Decoder based on Long Short-term-memory (LSTM) is proposed by Kao et al. (2020) for multi-step-ahead flood forecasting. While flood susceptibility modeling using deep learning is investigated in many studies, such as (Pham et al., 2021, Bui et al., 2020). LSTM is also used by Ni et al. (2020) for streamflow and rainfall prediction where two LSTM-based models are built, one combined wavelet network with LSTM and the other combined convolutional network with LSTM to achieve better performance.

StWDF is one of these problems that benefit most from DL to develop effective methods. However, some challenges might impede the success of DL-based solutions. Model complexity, the accumulative error when forecasting multi-steps, and the significant prediction error at the extreme points are some of these challenges that still need investigation. Model complexity and the size of the model in particular, become serious constraints when using federated learning approach, and bring some extra challenges to knowledge transformation technologies. Model complexity includes two types, time complexity and space complexity. Time complexity is brought on by the time required to train the model and by the data size required for training. The place complexity problem usually comes to the surface when the model has a massive number of parameters, which increases the model size, as well as the training time.

The second challenge is the accumulative error problem, which affects the multi-step prediction of water demand. When relying on the historical data of water demand for StWDF, the predicted values are involved in predicting the following values. Thus, the prediction error is compounded by the use of inaccurate values of the predicted water demand.

The third challenge is the significant error at the extreme points, which occur as a normal reflection of the nonlinearity of daily water demand. These points are recognized as periods where water demand is dramatically different from the average demand in the adjacent periods, making it difficult for the model to approximate the demand at these points. A few examples of extreme points are illustrated in Fig. 7, Fig. 8. The error at these points is usually unacceptable and may lead to severe problems in the distribution system.

In literature, complexity problem was not a critical issue when statistical methods such as Auto-regression integrated moving average (ARIMA) method and the seasonal version of it (SARIMA), in addition to Markov Chain, are used for StWDF (Pandey et al., 2021). However, their accuracy is not sufficiently satisfactory. Caiado (2010) has achieved 11% of mean square percentage error for one-day prediction and 13.2% for 7 -days ahead prediction by combining SARIMA with the generalized autoregressive conditional heteroscedasticity method for daily WDF. Arandia et al. (2016) also have achieved 4.21% of mean absolute percentage error (MAPE) for 15-min prediction of water demand in Dublin Spain by involving some data assimilation technique to improve the performance of SRIMA method. However, their proposal does not work well with hourly prediction, where the best MAPE they have got is 38.12%. Brentan et al. (2017) have built their prediction model based on SVR and Fourier methods for on-line prediction of hourly water demand. Their model achieves MAPE of 3.41%for one-step prediction.

With the expansion in the application of machine learning (Zhou et al., 2020, He et al., 2019) and artificial neural networks (ANNs) (Salloom et al., 2020, Yu et al., 2020, He et al., 2017), several studies have proved that machine learning methods outdo the stochastic and the probabilistic models for WDF. Gagliardi et al. (2017) has proved the ANNs overcome Markov Chain-based models in terms of forecasting accuracy. Herrera et al. (2010) and Bai et al. (2015) have proved the efficiency of support vector regression method for hourly WDF. Guo et al. (2018) has compared statistical methods and conventional ANNs with deep learning method and proved that the DL methods give more accurate results when predicting water demand for short-horizon.

In fact, most researchers focus on improving prediction accuracy without paying too much attention to model complexity. Furthermore, a new trend that exacerbates this problem has started looming on the horizon recently, where some researchers comprise many machine-learning models in one system. Then, they chose a different one for different prediction periods based on probabilistic methods. Ambrosio et al. (2019) have used a combination of multilayer perceptron, SVM, ELM, random forests and adaptive neural fuzzy inference systems for hourly WDF. Antunes et al. (2018) have investigated combining SVR, ANN, k-nearest-neighbours, and random forest regression for real-time WDF. This strategy is meant to use the most accurate model in the most suitable prediction period. However, it requires a massive amount of computations and memory to save the parameters of all models and system configuration setting.

The error at extreme points also contributes to the worsening of the prediction accuracy; however, It has not attracted researchers’ attention. Guo et al. (2018) are the first to point out this problem in their work, but they have not provided any solution.

The accumulative error problem may occur when predicting several steps ahead based on the historical data of water demand. Some researchers tried to solve this problem individually by building a new neural network model and train it to make the predicted values approach the real ones. Obviously, this method increases the parameter of the system dramatically.

In fact, the accumulative error problem can be mitigated by involving several factors besides the historical data (Papageorgiou et al., 2015, Kley-Holsteg and Ziel, 2020), so the impact of the predicted values in the input can be reduced efficiently. Many factors influence water demand level (Dias et al., 2018), but only factors such as meteorological conditions and day type, which have weekly or daily distinguishable changes, have real impacts on StWDF (Romano and Kapelan, 2014). However, managers still rely on the historical data of water demand for StWDF, and ignore the other possible factors because of the difficulties of gathering data about them in real time, particularly in the 15-min interval. Moreover, some available information about some factors, such as meteorological information, are not sufficiently accurate for short time prediction (Rayner et al., 2005), making them unreliable.

In this work, we propose a novel DL model for StWDF. It is built based on the gated recurrent unit (GRU), and unsupervised classification method k-means. Involving data classification as a prior step has two major benefits, (i) it helps with creating new features to compensate for the leak of reliable features, which reflects positively on the prediction accuracy and the accumulative error. (ii) It creates a relationship between data of different days, which an ANN can be easily approximated with a small number of parameters, which in turn enhances the space complexity of the models.

Additionally, we investigate using a novel technique to alleviate the nonlinearity at the extreme points and reduce the error. It depends on inserting virtual data between the actual data so that the nonlinearity at these points is drastically declined.

The contribution of this paper can be summarized as follows:

  • A novel DL model that provides a high prediction accuracy for both one step (15-min) and multi-step (96 steps ahead) prediction is proposed. It is built based on GRU neural network, supported by an unsupervised classification step to enhance the accuracy.

  • A new technique for mitigating the prediction error at extreme points is proposed and investigated.

  • The accumulative error problem, which occurs in multi-step prediction, is mitigated by means of classification step, which establishes new features to rely on in the prediction.

  • A comparison with the state-of-the-art is carried out to show the effectiveness of our proposed methods in terms of accuracy and model complexity.

The rest of this paper is organized as follows: Section 2 describe the equipment used to carry out this research. Section 3 explains the research methodology and the methods proposed in this work. Section 4 clarifies the results of this research, including the structure of the prediction model and the evaluation results. While Section 5 provide an intensive discussion to illustrate the underlying cause of these results. Section 6 illustrates the significance of the results. Section 7 includes the conclusion and the planned future works.

Section snippets

Research equipment and tools

The machine used to carry out this research including classification step, training the DL models, prediction process, and verification and evaluation of the proposed method is an ASUS laptop with an Intel Core i7 processor, four real cores, with a speed of 2.6 GHz each. The installed RAM is 16 GB. All models are built using Python 3.6 programming language over Anaconda platform. Keras library and Tensorflow backend are used to build the DL models due to their availability and convenience, so

Methodology

Firstly, the water demand is collected every 15 min from the water distributing system, and the database is updated every 24 h. One-step prediction scenario and multi-step prediction scenario are considered as described in Section 3.2. k-means method is applied to classify the data based on their numerical distance into mclasses as described in Section 3.3. The number mis determined using Elbow method. Then, demand readings and the classes are organized in vectors, (Vt,C1,C2,,Cm), each vector

DCGRU model structure

Fig. 3 shows the distortion of water demand data in terms of the number of classes. It is clear that 4 is the most suitable number of classes for both data sets of DMA1 and DMA2.

Based on what described in the methodology Section 3.2, the resulted model consists of two blocks as shown in Fig. 4, (i) Dense block contains an input layer with a shape of (96, 5, 1) and two hidden layers. All layers are of type “Time-distributed dense.” The input layer and the two hidden layers contain 50, 10, and 1

Discussion

In this work, a new ANN structure for StWDF is investigated, aiming at minimising the number of the trainable parameters while maintaining a level of forecasting accuracy not less than that reported in the previous works.

The proposed DCGRU model achieves this goal successfully, as shown in the results. The complexity of our model is reduced effectively compared to what achieved in the state-of-the-art. This is attributable to two factors; (i) using GRU cell instead of LSTM cell as done in some

Significance of results

The prediction models proposed in this research provide accurate forecasting of water demand, where the MAE of both CDGRU and ECDGRU does not exceed 1m3/15min in Scenario 1, and 1.2m3/15min is Scenario 2. Such an accuracy guarantees accurate pumping, which in turn secures a satisfactory service while reducing the risk of sabotaging the pipes by high pressure and reduce the cost of maintenance.

Additionally, water demand data are confidential data because they are rich with private information.

Conclusion

This research investigates a novel DL model for StWDF and proposes a novel strategy for mitigating the error at the extreme points. The main goal of the new design is to minimize the place complexity of the model while keeping high accuracy levels in two forecasting scenarios, one-step and multi-step forecasting scenarios, in addition to reducing the accumulative error problem in multi-step forecasting scenario.

To enhance the performance of the model, the historical data of water demand is

CRediT authorship contribution statement

Tony Salloom: Conceptualization, Formal analysis, Investigation, Software, Writing - original draft. Okyay Kaynak: Data curation, Methodology, Validation, Writing - review & editing, Supervision. Wei He: Funding acquisition, Writing - review & editing, Resources, Supervision.

Declaration of Competing Interest

The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.

Acknowledgments

The authors would like to acknowledge the helpful comments of Prof. Shuming Liu of Tsinghua University, China throughout our research and sharing their data set with us.

This work was supported by the National Natural Science Foundation of China under Grant 62073031, 62061160371, and the Fundamental Research Funds for the China Central Universities of USTB under Grant FRF-TP-19-001C2.

Tony Salloom received the B.Eng. degree in electronics and computer engineering from Aleppo University, Aleppo, Syria, in 2008, and the M.Eng. degree in information and telecommunication engineering from the University of Science and Technology Beijing, Beijing, China, in 2016. From 2009 to 2013, he served as a Database Engineer at the Syrian Telecommunication Company, Aleppo, Syria. He is currently pursuing the Ph.D. degree with the School of Automation and Electrical Engineering, University

References (50)

  • M. Romano et al.

    Adaptive water demand forecasting for near real-time management of smart water distribution systems

    Environ. Model. Softw.

    (2014)
  • J. Wang et al.

    Estimating snow depth by combining satellite data and ground-based observations over Alaska: A deep learning approach

    J. Hydrol.

    (2020)
  • R. Zhang et al.

    Physics-informed multi-LSTM networks for metamodeling of nonlinear structures

    Comput. Methods Appl. Mech. Eng.

    (2020)
  • Y. Zhou

    Real-time probabilistic forecasting of river water quality under data missing situation: Deep learning plus post-processing techniques

    J. Hydrol.

    (2020)
  • S. Zinatloo-Ajabshir et al.

    Sonochemical synthesis and characterization of silver tungstate nanostructures as visible-light-driven photocatalyst for waste-water treatment

    Sep. Purif. Technol.

    (2020)
  • S. Zinatloo-Ajabshir et al.

    Green synthesis of dysprosium stannate nanoparticles using ficus carica extract as photocatalyst for the degradation of organic pollutants under visible irradiation

    Ceram. Int.

    (2020)
  • S. Zinatloo-Ajabshir et al.

    Facile preparation of Nd_2Zr_2O_7-ZrO_2 nanocomposites as an effective photocatalyst via a new route

    J. Energy Chem.

    (2017)
  • J.K. Ambrosio et al.

    Committee machines for hourly water demand forecasting in water supply systems

    Math. Prob. Eng.

    (2019)
  • A. Antunes et al.

    Short-term water demand forecasting using machine learning techniques

    J. Hydroinform.

    (2018)
  • E. Arandia et al.

    Tailoring seasonal time series models to forecast short-term water demand

    J. Water Resour. Plann. Manage.

    (2016)
  • Y. Bai et al.

    Dynamic forecast of daily urban water consumption using a variable-structure support vector regression model

    J. Water Resour. Plann. Manage.

    (2015)
  • J. Caiado

    Performance of combined double seasonal univariate time series models for forecasting water demand

    J. Hydrol. Eng.

    (2010)
  • A. Candelieri

    Clustering and support vector regression for water demand forecasting and anomaly detection

    Water

    (2017)
  • Chung, J., Gulcehre, C., Cho, K., Bengio, Y., 2014. Empirical evaluation of gated recurrent neural networks on sequence...
  • Y. Deng et al.

    A sequence-to-sequence deep learning architecture based on bidirectional GRU for type recognition and time location of combined power quality disturbance

    IEEE Trans. Industr. Inf.

    (2019)
  • Cited by (42)

    View all citing articles on Scopus

    Tony Salloom received the B.Eng. degree in electronics and computer engineering from Aleppo University, Aleppo, Syria, in 2008, and the M.Eng. degree in information and telecommunication engineering from the University of Science and Technology Beijing, Beijing, China, in 2016. From 2009 to 2013, he served as a Database Engineer at the Syrian Telecommunication Company, Aleppo, Syria. He is currently pursuing the Ph.D. degree with the School of Automation and Electrical Engineering, University of Science and Technology Beijing, Beijing, China. His current research interests include Deep learning, intelligent control systems, and robotics.

    Okyay Kaynak received the B.Sc. degree with first class honors and Ph.D. degrees in electronic and electrical engineering from the University of Birmingham, UK, in 1969 and 1972 respectively. From 1972 to 1979, he held various positions within the industry. In 1979, he joined the Department of Electrical and Electronics Engineering, Bogazici University, Istanbul, Turkey, where he is currently a Professor Emeritus, holding the UNESCO Chair on Mechatronics. He is also a 1000 People Plan Professor at University of Science & Technology Beijing, China. He has hold long-term (near to or more than a year) Visiting Professor/Scholar positions at various institutions in Japan, Germany, U.S., Singapore and China. His current research interests are in the fields of intelligent control and mechatronics. He has authored three books, edited five and authored or co-authored more than 450 papers that have appeared in various journals and conference proceedings. Dr. Kaynak has served as the Editor in Chief of IEEE Trans. on Industrial Informatics and IEEE/ASME Trans. on Mechatronics as well as Co-Editor in Chief of IEEE Trans. on Industrial Electronics. Additionally, he is on the Editorial or Advisory Boards of a number of scholarly journals. In 2016, He received the Chinese Governments Friendship Award and Humboldt Research Prize. Most recently he was awarded the Academy Price of Turkish Academy of Sciences (2020). Dr. Kaynak is active in international organizations, has served on many committees of IEEE and was the president of IEEE Industrial Electronics Society during 2002–2003. He was elevated to IEEE fellow status in 2003.

    Wei He (S’09-M’12-SM’16) received his B.Eng. in automation and his M.Eng. degrees in control science and engineering from College of Automation Science and Engineering, South China University of Technology (SCUT), China, in 2006 and 2008, respectively, and his Ph.D. degree in control science and engineering from Department of Electrical & Computer Engineering, the National University of Singapore (NUS), Singapore, in 2011. e is currently working as a full professor in School of Automation and Electrical Engineering, University of Science and Technology Beijing, Beijing, China. He has co-authored 2 books published in Springer and published over 100 international journal and conference papers. He was awarded a Newton Advanced Fellowship from the Royal Society, UK in 2017. He was a recipient of the IEEE SMC Society Andrew P. Sage Best Transactions Paper Award in 2017. He is serving the Chair of IEEE SMC Society Beijing Capital Region Chapter. He is serving as an Associate Editor of IEEE Transactions on Robotics, IEEE Transactions on Neural Networks and Learning Systems, IEEE Transactions on Control Systems Technology, IEEE Transactions on Systems, Man, and Cybernetics: Systems, IEEE/CAA Journal of Automatica Sinica, Neurocomputing, and an Editor of Journal of Intelligent & Robotic Systems. His current research interests include robotics, distributed parameter systems and intelligent control systems.

    View full text