Next Article in Journal
Strength Properties and Water-Blocking Stability of Hydrophobically Modified Silty Clay
Previous Article in Journal
Macrophytes and Phytoplankton, Two Primary Antithetical Producers in Degraded Water Systems
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Empowering Regional Rainfall-Runoff Modeling Through Encoder–Decoder Based on Convolutional Neural Networks

School of Information Engineering, North China University of Water Resources and Electric Power, Zhengzhou 450046, China
*
Author to whom correspondence should be addressed.
Water 2025, 17(3), 339; https://doi.org/10.3390/w17030339
Submission received: 16 December 2024 / Revised: 20 January 2025 / Accepted: 23 January 2025 / Published: 25 January 2025

Abstract

:
Regional rainfall-runoff modeling is a classic and significant research topic in hydrological sciences. Currently, the predominant modeling approach is developing data-driven models. This study proposes a rainfall-runoff model named ED-TimesNet (Encoder–Decoder-based TimesNet), which consists of convolutional neural networks. It transforms a one-dimensional time series into a two-dimensional matrix based on frequency-domain partitioning rules and subsequently employs a two-dimensional visual backbone to learn both local and global features of the hydrological time series. Compared to LSTM-based models and Transformer models, this model learns both intra-period and inter-period variations in hydrological series, simultaneously focusing on the relationships between adjacent and non-adjacent time points. It alleviates the temporal ambiguity problem inherent in attention mechanisms. This research validates the performance of the ED-TimesNet model in regional rainfall-runoff modeling tasks using the Catchment Attributes and Meteorology for Large-sample Studies (CAMELS) dataset. The model achieves a median and mean NSE of 0.8049 and 0.7808, respectively, across 448 basins, outperforming the benchmark LSTM, VIC, and mHM models, and achieving comparable performance to the Transformer model. This paper does not address the model’s performance on ungauged basins. The method of predicting runoff based on the periodic features of hydrological data provides a novel perspective for hydrological sciences.

1. Introduction

Rainfall-runoff modeling is a longstanding and critical problem in the hydrological sciences. It refers to the essential task of forecasting runoff values using rainfall values, other meteorological forcings, and auxiliary information. Traditional rainfall-runoff modeling methods primarily involve conceptual and process-based hydrological models [1,2,3,4,5,6]. The most accurate runoff predictions using these methods typically require calibration of long-term data records in individual basins [7]. When modeling multiple basins, this often necessitates calibrating each one individually, which can be cumbersome and time-consuming. Recently, with the accumulation of data and the rise of deep learning, data-driven approaches have gained considerable attention. Deep learning-based hydrological models are trained on data from multiple basins, effectively learning the entire mapping from meteorological inputs and auxiliary data to runoff or other output fluxes directly in a useful way [8]. Auxiliary data, such as catchment attributes, can help deep learning models distinguish between diverse basin response behaviors, enabling a single model to predict regional runoff across multiple basins. Meteorological and runoff sequences are typical time series, and certain types of time series modeling strategies are popular in rainfall-runoff modeling, such as LSTM and Transformer [9,10,11,12,13,14]. These models have achieved significant advancements in the field of rainfall-runoff modeling.
By conceptualizing the rainfall-runoff modeling problem as a time series forecasting problem, we can analyze the inherent properties of a time series, including continuity, periodicity, and trend, to tackle the diverse runoff changes that arise from complex temporal patterns [15,16,17]. This paper attempts to explore the variation patterns of meteorological and runoff data from the perspectives of periodicity and trends, aiming to achieve more accurate predictions of runoff sequences. Firstly, it is commonly observed that time series data used in rainfall-runoff modeling usually present multi-periodicity, such as daily and annual variations in precipitation and runoff data, as well as quarterly variations in temperature observations (e.g., Figure 1). Secondly, we find that the variations in meteorological and runoff data at each time point are not only influenced by the temporal patterns of adjacent areas but are also highly correlated with the changes in their adjacent periods.
This paper aims to develop rainfall-runoff models to provide runoff prediction across regional areas. We use the time series model TimesNet [18] to capture the periodic variation relationships between meteorological data and runoff observations, and we utilize meteorological data along with catchment attribute data to estimate runoff. Furthermore, we explore the structural aspect of the model, proposing a novel rainfall-runoff model named ED-TimesNet: Encoder–Decoder-based TimesNet, to further improve runoff prediction performance.

2. Related Approaches of Rainfall–Runoff Modelling

Rainfall-runoff modeling, as a classic problem in hydrological sciences, has been extensively studied by numerous scholars in the field. Overall, the research methods for rainfall-runoff modeling can be categorized into two main types: traditional methods based on prior hydrological knowledge, and data-driven methods that learn the mapping relationships directly from data.
Traditional rainfall-runoff forecasting methods, such as conceptual hydrological models, are constructed based on the physical processes underlying runoff generation. These methods have a long history, resulting in a wide variety of approaches currently available. The Sacramento Soil Moisture Accounting Model (SAC-SMA) [19] is a conceptual hydrological model characterized by lumped parameters and continuous computations. It is comprehensive in function and has had a profound impact on the hydrological sciences. The SAC-SMA model still has issues, such as insufficiently comprehensive assumptions, for example, not considering the impact of soil freezing and thawing on the runoff generation process [20]. The Soil and Water Assessment Tool (SWAT) [21] is a conceptual, continuous physical model that aids water resource managers in evaluating the impacts of management on water supplies and non-point source pollution in watersheds and large river basins. The Variable Infiltration Capacity model (VIC) [22] is a time-stepping conceptual model that allows for physical benchmarking of indicators relating one variable to another (e.g., runoff ratio). The mesoscale hydrological model (mHM) [23] is a widely used and continuously updated hydrological model, previously demonstrated to provide robust hydrological simulation capabilities. However, it is relatively more suitable for hydrological modeling in medium-sized watersheds. The HBV model [24,25] is one of the commonly utilized conceptual models in watershed hydrology, using daily rainfall, air temperature, and monthly potential evaporation estimates as inputs to simulate daily discharge. While traditional approaches offer clear interpretability and can often deliver relatively accurate predictions in individual basins, their reliance on prior knowledge of the hydrological system can lead to significant accuracy declines when applied to other basins [26]. Additionally, these methods face challenges such as insufficient parameter count, inaccurate model assumptions, and limited predictive capacity for regional runoff sequences [27], which further restrict their development.
As observational data accumulate and deep learning advances, data-driven methods have gained significant attention in recent years. These methods do not rely on prior knowledge of hydrological systems but instead learn the mapping relationships between meteorological data, auxiliary data (e.g., catchment attributes), and basin runoff directly from the data itself [8]. Recent studies have consistently demonstrated that data-driven approaches yield effective runoff predictions in both single-basin and regional rainfall-runoff modeling.
For instance, Kratzert et al. [8] employed LSTM and its variant, Entity-Aware LSTM (EA-LSTM), for regional runoff prediction. Both methods utilized meteorological time series and static catchment attributes as inputs to forecast runoff for the first day ahead, ultimately outperforming traditional hydrological models. Xiang et al. [10] developed an LSTM-seq2seq model using LSTM and sequence-to-sequence (seq2seq) modeling techniques. Their research in two Midwestern watersheds in Iowa demonstrated the model’s sufficient predictive capability and its potential to enhance the accuracy of short-term flood forecasting. Zhang et al. [28] employed Principal Component Analysis (PCA) in conjunction with deep Recurrent Neural Networks (RNNs), including LSTM and GRU (Gated Recurrent Unit) models, to predict daily runoff. The experiments demonstrated that appropriately processing the input variables can enhance the model’s performance. Yao et al. [12] proposed a hybrid model based on CNN-LSTM and GRU-ISSA, where the CNN-LSTM model is used for long-term runoff time series prediction, the GRU model for short-term forecasting, and the ISSA for hyperparameter optimization, demonstrating superior performance in single-basin modeling. Zhang et al. [29] introduced an Encoder-Decoder-Based Double-Layer Long Short-Term Memory (ED-DLSTM) model, which achieved regional modeling across more than 2000 catchments worldwide. The average Nash-Sutcliffe Efficiency coefficient (NSE) from the experiments was 0.75, demonstrating the potential of machine learning models in large-scale rainfall-runoff modeling.
In addition, CNN models have also been applied in hydrological sciences. Van et al. [30] developed a runoff model using CNN and compared it with an LSTM model, with the CNN model yielding slightly better results. Therefore, the authors suggest that CNN is also suitable for regression problems. Song [31] used CNN to propose a daily runoff prediction model that can learn watershed topographic features, and the results showed that this model outperforms both LSTM and ANFIS models in runoff prediction. However, extensive experiments have demonstrated that LSTM models are particularly well-suited for rainfall-runoff modeling [8], and CNN models are relatively less common in time series analysis. As a result, CNN models have not received widespread attention, with methods based on Long Short-Term Memory (LSTM) networks being particularly prevalent in rainfall-runoff modeling.
However, the LSTM model is not necessarily the best model for rainfall-runoff modeling. The LSTM-based models cannot connect two positions in a time series process directly, let alone strengthen the connection of two arbitrary positions [14]. In rainfall-runoff modeling, non-adjacent time points may have significant relationships, and overlooking these connections could result in the loss of valuable information. Consequently, researchers have applied the Transformer model to rainfall-runoff modeling tasks, leading to the development of the RR-Former model [14]. The Transformer model enhances or diminishes connections between any two locations, allowing for a more comprehensive examination of the relationships among sample data points. This capability facilitates the extraction of more useful information and supports multi-step runoff forecasting. However, the attention mechanism within the Transformer model struggles to reliably identify dependencies from scattered time points, as temporal relationships may become deeply obscured in complex time patterns [32]. To facilitate understanding, we summarize previous studies on rainfall-runoff modeling in Table 1, which will provide clearer insights for the readers.
To fully leverage the temporal dependencies and periodic trends inherent in meteorological and runoff sequences, this study aims to employ TimesNet [18] to develop a rainfall-runoff model. The model exclusively utilizes convolutional neural networks (CNNs) to learn the patterns of hydrological time series. It segments and rearranges the one-dimensional time series into a two-dimensional format based on frequency-domain partitioning rules, and then employs a visual backbone to capture both short-term and long-term relationships within the time series data. In contrast to LSTM and Transformer models, this approach considers direct connections between adjacent and non-adjacent time points while avoiding the temporal dependency ambiguities associated with attention mechanisms. Furthermore, to mitigate unnecessary interactions between the target sequence and auxiliary information [33], the study introduces the ED-TimesNet model, which employs an encoder–decoder structure [34]. This model extracts features from meteorological information and the target sequence independently, while retaining its core capability to capture the two-dimensional temporal change patterns, thereby enhancing the accuracy of target sequence predictions. The structural modifications render the model more suitable for tasks involving a single target sequence and multiple input variables in rainfall-runoff modeling.

3. Methods

This section primarily introduces and discusses the architectures of TimesNet and ED-TimesNet, as well as how the model’s core component, TimesBlock, extracts the two-dimensional variation patterns of hydrological time series.

3.1. TimesBlock

From Figure 1, we observe that both meteorological and runoff data exhibit seasonal variability. Additionally, the data at each time point are influenced by two types of variations: those associated with adjacent time points and those related to adjacent periods, which are intra-period and inter-period variations. However, the original one-dimensional time series can only reflect changes between consecutive time points. To facilitate the learning of the inter-period relationships in the time series, we need to extract the primary periods of the data, subsequently reconstructing the one-dimensional time series into a two-dimensional format based on these periods. This is followed by employing convolutional neural networks to extract features related to data variations both intra-period and inter-period, as illustrated in Figure 2.
Specifically, for the l-th layer of the model, the original 1 D input is X 1 D l 1 R T × C , where T denotes the length and C denotes the number of variables. The feature extraction process is divided into four steps: period discovery, tensor reconstruction, feature capture, and adaptive aggregation.
To represent the variations between periods, the first step is to discover these periods. Technically, TimesBlock employs Fast Fourier Transform (FFT) to analyze the time series in the frequency domain, as described in Equation (1). In the equation, F F T ( · ) and A m p ( · ) represent the computations of the FFT and amplitude values, respectively. The average amplitude values across C dimensions are calculated using the A v g ( · ) , resulting in the computed amplitude A R T for each frequency. The period length corresponding to amplitude A j is T j . To mitigate the impact of meaningless high-frequency noise from the frequency domain on the model’s learning process [35], TimesBlock selects only the top-k amplitude values that exert the greatest influence. These selected amplitudes correspond to the most significant frequencies { f 1 , , f k } and period lengths { p 1 , , p k } , where k is the hyperparameter.
A l 1 = A v g A m p F F T ( X 1 D l 1 ) , { f 1 , , f k } = argTopk f * { 1 , , [ T 2 ] } ( A l 1 ) , p i = T f i , i { 1 , , k } ,
The next step involves tensor reconstruction. Based on the frequencies { f 1 , , f k } and their corresponding period lengths { p 1 , , p k } , we reconstruct the one-dimensional time series X 1 D l 1 R T × C into multiple two-dimensional tensors X 2 D l , i R p i × f i × C , i { 1 , , k } . The specific process is outlined in Equation (2). Here, P a d d i n g ( · ) refers to zero-padding the time series along the temporal dimension to address potential mismatches in the total length of the two-dimensional transformations. R e s h a p e p i , f i ( · ) transforms the expanded time series into X 2 D i R p i × f i × C , where p i and f i represent the number of rows and columns of the transformed two-dimensional tensor, respectively. X 2 D l , i denotes the i-th reconstructed time series based on frequency f i , with its columns and rows representing the intra-period variations and the inter-period variations within the period length p i . Ultimately, within the l-th TimesBlock, we can derive a set of k distinct two-dimensional tensors { X 2 D l , 1 , , X 2 D l , k } derived from different periods.
X 2 D l , i = R e s h a p e p i , f i P a d d i n g ( X 1 D l 1 ) , i { 1 , , k } ,
The third step is featuring extraction. We employ a two-dimensional convolutional kernel to extract both intra-period and inter-period variations from the two-dimensional tensor { X 2 D l , 1 , , X 2 D l , k } , as demonstrated in Equation (3). For the transformed two-dimensional tensor X 2 D l , i R p i × f i × C , the TimesBlock employs a Convolutional Neural Network block (CNN Block) to extract features denoted as X ^ 2 D l , i R p i × f i × C . Here, an Inception Block serves as an example, but it may be substituted with other visual backbones, such as ResNeXt [36] or ConvNeXt [37]. To enhance computational efficiency, the TimesBlock utilizes shared convolutional kernels for tensors of varying shapes, thereby mitigating changes in model size resulting from the selection of hyperparameter k. Subsequently, the learned 2 D features are transformed back into one-dimensional space using R e s h a p e 1 , ( p i × f i ) ( · ) , yielding X ^ 1 D l , i R T × C . The feature sequence of length p i × f i is then truncated to the original length T using T r u n c ( · ) to facilitate the aggregation of different features, as shown in Equation (4).
X ^ 2 D l , i = I n c e p t i o n ( X 2 D l , i ) , i { 1 , , k } ,
X ^ 1 D l , i = T r u n c R e s h a p e 1 , ( p i × f i ) ( X ^ 2 D l , i ) , i { 1 , , k } ,
The final step is adaptive aggregation. The input format for the next layer of TimesBlock is X 1 D l R T × C . To achieve this, it is necessary to integrate k distinct one-dimensional features, { X ^ 1 D l , 1 , , X ^ 1 D l , k } , as outlined in Equation (5). For the k two-dimensional tensors, { X 2 D l , 1 , , X 2 D l , k } , the amplitudes { A f 1 l 1 , , A f k l 1 } reflect the relative significance of the selected frequencies and periods, corresponding to the importance of each transformed two-dimensional tensor’s features { X ^ 1 D l , 1 , , X ^ 1 D l , k } . Therefore, during the feature fusion process, a weighted summation is performed based on the importance of the corresponding features, resulting in an integrated feature.
X 1 D l = i = 1 k A ^ f i l 1 × X ^ 1 D l , i , A ^ f 1 l 1 , , A ^ f k l 1 = S o f t m a x ( A f 1 l 1 , , A f k l 1 ) .
It is worth noting that for time series without obvious periodicity (such as when the sequence length is insufficient to fully capture periodic characteristics), the FFT can still represent variations in the time series. In such cases, the analysis primarily captures intra-period patterns (localized patterns) rather than inter-period patterns due to the limited length of the sequence. It can also occur when the data are inherently non-periodic.

3.2. TimesNet

The original structure of the TimesNet model consists of a straightforward linear architecture that includes an embedding layer, l a y e r s feature extraction blocks of TimesBlock, and a final projection layer, where l a y e r s is a hyperparameter. To ensure that the input data aligns with the model’s dimensions, it must first be transformed through the embedding layer before feature extraction. The embedding layer converts the information carried by each time point in the time series, comprising C-dimensional feature variables and the position of the input series, into a vector of input dimensions d i n for TimesBlocks. This vector represents specific features relevant to the corresponding time point, while the distances between vectors reflect the similarities between time points [38]. The resulting embeddings are then fed into the TimesBlocks for feature extraction.
Between each TimesBlock, residual connections are employed [39]. Specifically, for an input time series X 1 D R T × C of length T, the first five variables represent meteorological features, the intermediate variables concatenate catchment attributes, and the final variable consists of the known runoff series of length T l a b e l followed by the unknown runoff of length T p r e d , where the unknown runoff is replaced by zeros. Additionally, T l a b e l + T p r e d = T . Our goal is to predict the unknown runoff for the T p r e d -length period. We initially project the raw input through the embedding layer X 1 D 0 = Embed ( X 1 D ) into enriched features X 1 D 0 R T × d i n . For the l-th layer of TimesNet, the input is X 1 D l 1 R T × d i n . The output of feature extraction, denoted by T i m e s B l o c k ( X 1 D l 1 ) , is then combined with the input itself, followed by L a y e r N o r m ( · ) to normalize the combined data and mitigate issues related to gradient vanishing or gradient explosion. The final result of the l-th layer is X 1 D l . This process can be formalized as:
X 1 D l = L a y e r N o r m T i m e s B l o c k ( X 1 D l 1 ) + X 1 D l 1 .
The features extracted by TimesNet undergo a linear transformation to adjust the feature dimensions to the target dimensions, followed by truncating the necessary days for prediction to obtain the forecast results. The linear transformation refers to the operation where input data are transformed using a matrix multiplication followed by an (optional) addition of a bias vector. Linear transformation is one of the commonly used methods for dimensional transformation and feature extraction in deep learning. The canonical TimesNet has demonstrated commendable predictive performance across multiple publicly available time series datasets; however, the model fails to differentiate the significance of different channels. During the prediction process, the canonical TimesNet model treats input variables (meteorological time series and static catchment attributes) and the target variable (runoff time series) as an integral input, neglecting to distinguish between the target variable and the other variables. This equal treatment of target variables and the other variable not only introduces significant complexity regarding time and memory but also leads to unnecessary interactions between the target sequence X ( C ) and the auxiliary information { X ( 1 ) , , X ( C 1 ) } [33]. Consequently, the TimesNet model is more suited for multivariate prediction tasks X ^ ( 1 ) , , X ^ ( C ) = f ( X ( 1 ) , , X ( C ) ) , as depicted in Figure 3b, showing disadvantages when applied to rainfall-runoff modeling.
Through experimental validation (detailed discussion will be presented in Section 5.1), the canonical TimesNet model exhibits limitations when tasked with multivariable input and univariable output (MS) scenarios. Inspired by the Transformer model [14], this study employs an encoder–decoder architecture to reorganize the TimesNet, enabling the runoff sequence to receive enhanced attention. This approach facilitates the covariate prediction X ^ ( 1 ) = f ( X ( 1 ) , Z ( 1 ) , , Z ( C ) ) , where runoff data serves as the target variable X ( 1 ) and meteorological and attribute data are treated as auxiliary variables { Z ( 1 ) , , Z ( C ) } , as illustrated in Figure 3c.

3.3. ED-TimesNet

Specifically, the modifications made in this study involve the utilization of an encoder–decoder architecture to extract features from both auxiliary information and the target sequence. These two sets of features are subsequently integrated to achieve accurate predictions of the target sequence. The overall structure of the model is illustrated in Figure 4b.
The encoder component is primarily responsible for the feature extraction of meteorological time series and catchment attributes. The component maintains the same structure as the canonical TimesNet. The output of the final TimesBlock, denoted as Z 1 D C R T e n c × d i n , is transmitted to the decoder as meteorological features.
The decoder component primarily focuses on learning the variation in past runoff observations, excluding the forecast days. For the input to the decoder, X 1 D R T d e c × 1 , the time length- T d e c used is consistent with the known runoff length in Section 3.2, corresponding to the first T l a b e l days. Since only known runoff observation values are utilized, the embedded input for the target data, X 1 D 0 R T d e c × d i n , is not aligned with the meteorological feature Z 1 D C in the temporal dimension. Therefore, before extracting features from the target data, a linear transformation in the temporal dimension is applied, such that X 1 D 0 = Transfer T ( X 1 D 0 ) , mapping the input X 1 D 0 to the same temporal space R T e n c × d i n as the meteorological features. Within the l-th TimesBlock of the decoder, the input is X 1 D l 1 R T e n c × d i n ; after extracting the periodicity of the runoff observations, this input is fused with the auxiliary features Z 1 D C using the Hadamard product. Subsequently, convolutional neural networks are employed to extract features, leading to the reformulation of the TimesBlock equation in the decoder as follows:
X 2 D l , i = R e s h a p e p i , f i P a d d i n g ( X 1 D l 1 Z 1 D C ) , i { 1 , , k } .
For the output of the decoder, X 1 D C R T e n c × d i n , a linear transformation is applied to convert the feature dimension d i n to the target dimension C, similar to the approach used in TimesNet. The necessary forecast duration is then extracted to obtain the predicted results. In this context, the model generates the required length of predictions in a single step through a linear layer, eliminating the need for multi-step forecasting and thereby reducing the cumulative errors associated with such an approach.

3.4. Evaluation Metrics

We utilize the following four metrics to evaluate the performance of the models: Nash–Sutcliffe Efficiency (NSE), Root Mean Squared Error (RMSE), Absolute Top-2% Prediction Error (ATPE-2%), and Kling–Gupta Efficiency (KGE).
The Nash–Sutcliffe Efficiency (NSE) is one of the commonly used metrics in hydrology for assessing model performance [40]. The definition of NSE is provided in Equation (8), where y i represents the observed value at time i, y ^ i denotes the predicted value, and y ¯ is the mean of N observed values. The range of NSE is ( , 1 ] , with values closer to 1 indicating a higher degree of fit.
NSE = 1 i = 1 N ( y i y ^ i ) 2 i = 1 N ( y i y ¯ ) 2 ,
The root mean square error (RMSE) is relatively insensitive to bias and is utilized to assess the overall performance of a model. The definition of RMSE is provided in Equation (9), where y i and y ^ i have the same meaning as in Equation (8), and N indicates the number of observations. The range of RMSE is [ 0 , + ) , with smaller RMSE values indicating better model performance.
RMSE = i = 1 N ( y i y ^ i ) 2 ) N ,
The Absolute Top-2% Prediction Error (ATPE-2%) is utilized to measure the accuracy of peak flow predictions, with its definition provided in Equation (10). Here, y ( 1 ) y ( 2 ) y ( H ) , where y ( j ) represents the j-th largest observed runoff value, and y ^ j denotes the predicted result for y ( j ) . The parameter H indicates the number of peaks within the top 2%. The range of ATPE-2% is [ 0 , + ) , with smaller values indicating superior model performance.
ATPE - 2 % = j = 1 H y ^ j y ( j ) j = 1 H y ( j ) ,
The Kling–Gupta Efficiency (KGE) is also a composite metric used to evaluate the performance of hydrological models. It combines the three components of model errors (i.e., correlation, bias, and coefficients of variation) in a more balanced way than the NSE, and it has been widely used in recent years. The definition of KGE is given by Equation (11), where cov ( · ) is the covariance between the predicted ( y ^ ) and observed (y) values, while μ ( · ) and σ ( · ) represent the means and standard deviations, respectively. Its range is consistent with that of the NSE, which is ( , 1 ] , with values closer to 1 indicating better performance.
KGE = 1 ( r 1 ) 2 + ( α 1 ) 2 + ( β 1 ) 2 , w h e r e : r = cov ( y , y ^ ) σ ( y ) · σ ( y ^ ) , α = σ ( y ^ ) σ ( y ) , β = μ ( y ^ ) μ ( y ) .

4. Experimental Setup

This section primarily discusses the dataset utilized for model training, the benchmark models of rainfall-runoff modeling, and the hyper-parameter configurations of the model.

4.1. The NCAR CAMELS Dataset

To evaluate the rainfall-runoff modeling capability of our proposed ED-TimesNet model, we will use the Catchment Attributes and Meteorology for Large-sample Studies (CAMELS) dataset [41,42]. The CAMELS dataset, curated by the National Center for Atmospheric Research (NCAR), encompassing daily meteorological forcings, catchment attributes, and runoff observations from 671 basins across the Continental United States (CONUS), spanning from 1 October 1980 to 31 December 2014. The catchment attributes are categorized into five major groups: soil, climate, vegetation, topography, and geology. For comparative analysis with other models, this study employs the Maurer meteorological forcing data along with 27 static catchment attributes to construct the regional rainfall-runoff model. The meteorological data utilized includes: (i) daily cumulative precipitation, (ii) daily minimum temperature, (iii) daily maximum temperature, (iv) average shortwave radiation, and (v) vapor pressure, with catchment attributes detailed in Table 2. Here, we take the basin numbered 01022500 as an example to present meteorological and runoff data from the CAMELS dataset in Figure 1. Furthermore, to facilitate comparison, we select 448 basins consistent with the deep learning model RR-Former for modeling and evaluate the model’s performance across these basins. It is important to note that this study does not evaluate the model’s performance in ungauged basins.

4.2. Benckmark Models

The primary focus of this study is the development of a regional rainfall-runoff model, which utilizes a single set of shared parameters to establish mappings for selected basins within the dataset. To demonstrate the modeling efficacy of our proposed model, we will compare it against a selection of existing hydrological models, including both deep learning and traditional hydrological approaches. These models have been configured and calibrated, and they were constructed in prior experiments within the basins of the CAMELS dataset. The models under comparison are: (i) RR-Former [14], (ii) LSTM [8,9], (iii) VIC [43], and (iv) mHM [44]. We will evaluate the performance of these models based on those established in prior research, thereby mitigating potential biases in training outcomes caused by variations in equipment, software environments, or parameter settings, which could otherwise skew benchmark testing in favor of our own model. The benchmark models utilize the same daily Maurer forcing data as ED-TimesNet and are validated over the same test set. According to the technical approaches of the models, these benchmark models can be categorized into two distinct groups:
  • Deep Learning Models: These models have emerged prominently in recent years, demonstrating exceptional performance and serving as the primary comparative targets of this study. This group includes the LSTM model [8] and the RR-Former model [14].
  • Traditional Hydrological Models: To enhance the credibility of our proposed model, traditional hydrological models have been included for comparative analysis. These models are VIC [45] and mHM [46]. Both models have been developed as individual basin models as well as regional rainfall-runoff models, with a primary focus in this study on evaluating their regional modeling capabilities.

4.3. Regional Rainfall-Runoff Modeling

The Maurer measurement data from the CAMELS dataset were employed for regional rainfall-runoff modeling. The training period spans from 1 October 2001 to 30 September 2008; the validation period runs from 1 October 1999 to 30 September 2001; and the testing period covers 1 October 1989 to 30 September 1999. This is consistent with all benchmark models.
Two primary experiments are conducted in this research. The first experiment focuses on comparisons between the TimesNet and the ED-TimesNet model, while the second compares ED-TimesNet with the benchmark models. Our benchmark models—VIC, mHM, and RR-Former—are trained and evaluated on the same 448 basins from the CAMELS dataset. While the LSTM model is trained on 531 basins from the same dataset (including but not limited to those used by the other benchmark models), its performance on the 448 basins is also presented in their paper. To ensure a fair comparison with other benchmark models, our model’s training, validation, and testing datasets also use the same 448 basins. The training set includes all samples from these 448 basins, indicating that a single model trained on this dataset can be applied across all basins. In contrast, the testing set distinguishes samples from different basins, resulting in independent test results for each basin within the model.
The model employs N S E * loss [8] as its loss function, as represented by Equation (12). During the training process, the Adam optimization algorithm is used to update the model parameters. To facilitate comparison with the benchmark model [14], we set the sequence length to 22, the label length to 15, and the prediction length to 7. We determined the other hyperparameters through experimentation because of computational costs, with hyperparameter configurations detailed in Table 3. Our model is implemented using the PyTorch framework, and the data-processing libraries utilized include NumPy, Pandas, and Matplotlib. The experiments are conducted on four NVIDIA TITAN Xp 12G GPUs.
N S E * = 1 B b = 1 B n = 1 N ( y ^ n y n ) 2 ( s ( b ) + ϵ ) 2 .
Each experiment is divided into two configurations: rainfall-runoff modeling with catchment attributes (w) and without catchment attributes (w/o). The model inputs vary slightly depending on the experimental setup. In the experiments without catchment attributes, the encoder component of the model utilizes only meteorological forcing data. Conversely, in the experiments with catchment attributes, the encoder’s input comprises both meteorological forcing data and static catchment attributes (as shown in Table 2), which are concatenated before being fed into the model for training or validation. In both experiments, the decoder component of the model uses past runoff observations as input. Figure 5 shows the input samples for the experiments with catchment attributes under the conditions in Table 3. Figure 5a represents the input sample for the TimesNet, consisting of meteorological sequences, catchment attributes, and runoff sequences. The subscript indicates the index of each time point in the time series. The meteorological sequence and catchment attributes contain the full 22 days of data, while the runoff sequence consists of data from the first 15 days of known runoff (gold) combined with 7 days of zero data (gray). Figure 5b shows the input sample for the ED-TimesNet, where the meteorological sequence and catchment attributes are learned by the encoder, and the runoff sequence for the first 15 days is learned by the decoder. The objective of both experiments is to predict the runoff sequence for the indices 15–21.

5. Result and Discussion

In this section, we first discuss how modifications to the model structure optimize the performance of TimesNet. Furthermore, we will evaluate the capability of our ED-TimesNet model in regional rainfall-runoff modeling using the evaluation metrics mentioned in Section 3.4, and we will compare it against other benchmark models.

5.1. Comparison Between TimesNet and ED-TimesNet

The key results comparing the TimesNet method are presented in Table 4. This table primarily compares the regional modeling capabilities of the canonical TimesNet model with the enhanced ED-TimesNet model, using the NSE as the main evaluation metric. The “Failures” metric in the table indicates the number of basins with NSE values less than or equal to zero across the 448 basins studied. Each model was assessed using both catchment attributes and without them, resulting in a total of four models. The 1st-day-ahead data represent the prediction results for the runoff sequence at index 15, the 7th-day-ahead data represent the prediction results for the runoff sequence at index 21, and so on. For the models with catchment attributes, the optimal results are highlighted in bold, while for those without catchment attributes, the optimal results are underscored.
Additionally, Figure 6 illustrates the cumulative density functions (CDFs) of the NSE values for the TimesNet and ED-TimesNet models across 448 basins. The CDF is defined as F X ( x ) = P ( X x ) , where P ( · ) represents the probability and F ( · ) represents the cumulative probability that the NSE values (X) are less than or equal to the constant x ( 0 x 1 , here). This means that the further the curve dips to the right, the greater the number of basins with NSE values approaching 1, indicating better performance.
Combining the results from Figure 6 and Table 4, we can observe the following:
(i) The experimental results with catchment attributes outperformed those without such attributes. We posit that the inclusion of catchment characteristics aids the model in distinguishing the source basin of meteorological and runoff data, thereby enabling a more accurate mapping of rainfall to runoff within a high-dimensional space. However, it remains to be validated whether the 27 catchment attributes discussed in this paper are indeed optimal; other catchment attributes may also have significant correlations with rainfall-runoff behavior. Furthermore, there are varying degrees of correlation among catchment attributes; some are significantly associated with rainfall-runoff behavior, while others are less so. Identifying those catchment attributes with a greater correlation to rainfall-runoff behavior and increasing their weights, while simultaneously decreasing the weights of less correlated attributes, could enhance the model’s accuracy even further.
(ii) Compared to the canonical TimesNet, the modifications made in ED-TimesNet have indeed improved the model’s performance. Our hypothesis is that by separately extracting features from meteorological-related variables (meteorological sequences and static attributes) and runoff sequences, we can reduce the complex interactions between deep features and highlight the importance of runoff sequences, thereby enhancing runoff prediction capabilities. Experimental results show that, whether in models with catchment attributes (ED-TimesNet with static inputs and TimesNet with static inputs) or in models without catchment attributes (ED-TimesNet without static inputs and TimesNet without static inputs), the NSE scores of our improved ED-TimesNet are higher than those of the canonical TimesNet, with statistically significant differences in the prediction results. Furthermore, we take the basin numbered 06623800 as an example to show the advantages of ED-TimesNet (see Figure 7). We can see that the ED-TimesNet has a better performance than the TimesNet intuitively. As shown in Figure 7, both models developed in this section are able to predict runoff variations to some extent, but the predictions from the ED-TimesNet model are closer to the observed values. This demonstrates that the modifications we made have indeed improved the model’s runoff prediction ability, confirming our hypothesis.

5.2. Modeling Capabilities of ED-TimesNet for Rainfall-Runoff

In this section, we compare the rainfall-runoff models applied to the CAMELS dataset. It is noteworthy that the prediction time steps differ among these models. The LSTM, VIC regional calibration, and mHM regional calibration benchmark models are designed for short-term runoff predictions for one day ahead, whereas the RR-Former model focuses on medium- to long-term runoff predictions for seven days ahead. The performance of the short-term runoff prediction models is validated using pre-trained models provided by their respective research groups, without retraining these models. The results are presented in Table 5.
For the LSTM model, since all other models in this paper are single models trained with a specific random seed, we employed only a single LSTM model trained with a single random seed to assess the model’s rainfall-runoff modeling capabilities, rather than using the ensemble model mentioned in Kratzert et al. [8]. Regarding the RR-Former model, since the research group did not provide a pre-trained parameter set, we will train an RR-Former in our software environment for evaluation. This may introduce some discrepancies. In this paper, we adopt a comparative methodology consistent with that of RR-Former to evaluate the performance of our model.
From Table 5, on the 1st-day-ahead prediction, we observed that ED-TimesNet with catchment attributes significantly outperforms the VIC, mHM and LSTM (with catchment attributes) models across various evaluation metrics. And it also shows a certain level of advantage over the RR-Former with the catchment attributes model. Furthermore, its performance in predicting runoff for the 7th-day-ahead also exceeds that of the VIC and mHM models for 1st-day-ahead predictions. For multi-day-ahead runoff predictions, our ED-TimesNet with static inputs continues to demonstrate competitive performance with the RR-Former model, significantly outperforming the RR-Former model in terms of average NSE, while exhibiting competitive results in RMSE, ATPE-2%, and KGE metrics. These findings demonstrate the effective capabilities of ED-TimesNet in regional rainfall-runoff modeling.
Figure 8 presents the CDFs of NSE for the 7-day-ahead runoff predictions made by our ED-TimesNet model and other benchmark models. It primarily displays the results from Table 4 as a curve plot. As shown in Figure 8, our ED-TimesNet with catchment attributes model demonstrates significantly better performance in 1st-day-ahead predictions compared to the LSTM, VIC, and mHM models. Notably, even the ED-TimesNet model without static catchment attribute training outperforms two traditional hydrological models and is comparable to the LSTM model. Across all nth-day-ahead performances, the ED-TimesNet trained with static catchment attributes slightly surpasses the corresponding RR-Former, while the version of ED-TimesNet without attributes performs marginally worse than its counterpart. However, overall, the differences in performance between the two models are minimal. Our CNN-based approach has achieved experimental results comparable to the advanced rainfall-runoff model RR-Former, offering a novel perspective for the field of hydrological sciences.

5.3. Limitations of Our Model

As a data-driven model based on deep learning, ED-TimesNet shares a common challenge prevalent among most deep learning models: a lack of interpretability [47]. Although we have endeavored to correlate various terms within ED-TimesNet with hydrological interpretations, physical explanations remain somewhat elusive. The auxiliary features extracted in the encoder component encapsulate complex, high-dimensional characteristics that integrate meteorological time series and catchment attributes, making their interpretation particularly challenging. Additionally, the features merged in the decoder component further complicate the interpretative process. If we are unable to elucidate the internal workings of the model or what it has learned, conducting hypothesis tests using deep learning approaches could prove quite challenging [48]. Therefore, in future work, we aim to introduce minor modifications to enhance the interpretability of our proposed model, thereby combining the advantages of both physical and deep learning models.

6. Conclusions

This paper presents the ED-TimesNet model, a rainfall-runoff model composed entirely of convolutional neural networks (CNNs) and based on TimesNet. The primary objective of the model is to provide runoff predictions across regional areas, using meteorological and catchment attribute data from the CAMELS dataset.
The first significant contribution of this study is the exploration and utilization of both intra-period and inter-period variations in hydrological time series, providing a new perspective for rainfall-runoff modeling. By effectively capturing the periodic features of these time series, the proposed ED-TimesNet model offers a more comprehensive understanding of the temporal variations in the rainfall-runoff process. The results confirm that ED-TimesNet outperforms the VIC, mHM, and LSTM models, achieving results comparable to the advanced rainfall-runoff model RR-Former.
The second contribution of this study is the validation of the role of catchment attributes in CNN-based rainfall-runoff modeling. The comparison between models with and without static catchment attributes as inputs demonstrates that the information contained in catchment attributes can help CNN models distinguish the different rainfall-runoff relationships across various basins.
The third contribution of this study is the discovery that complex interactions between different variables, such as meteorological data, catchment attributes, and runoff data, can influence runoff predictions. The ED-TimesNet, utilizing an encoder–decoder architecture, achieves superior predictive performance compared to the canonical TimesNet by separately extracting features from meteorological data (with or without catchment attributes) and target sequence data. This indicates that considering the relationships between different variables in hydrological modeling may lead to improved performance in runoff prediction tasks.
Moreover, since ED-TimesNet is entirely composed of CNNs, its performance further highlights the competitive potential of CNN-based structures in rainfall-runoff modeling tasks. In future work, we plan to enhance the interpretability of the ED-TimesNet model to facilitate more reliable applications of our models. Additionally, we will continue to explore deep learning models that demonstrate improved performance in rainfall-runoff modeling tasks.

Author Contributions

Conceptualization, W.J. and X.D.; methodology, W.J. and X.D.; software, X.D.; validation, W.J. and X.D.; formal analysis, W.J. and X.D.; investigation, W.J. and X.D.; resources, W.J.; data curation, X.D.; writing—original draft preparation, W.J. and X.D.; writing—review and editing, W.J. and X.D.; visualization, X.D.; supervision, W.J. and R.Z.; project administration, W.J. and R.Z.; funding acquisition, W.J. and R.Z. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the National Natural Science Foundation of China (42371466) and the Key Research Projects of Henan Higher Education Institutions (23A520031 and 24A520020).

Data Availability Statement

Data in this study are accessible from public resources. The meteorological data, catchment attributes and streamflow observations are derived from CAMELS (Catchment Attributes and Meteorology for Large-sample Studies) dataset (https://ral.ucar.edu/solutions/products/camels, accessed on 5 December 2024). The original Maurer data included in the CAMELS data set only include daily mean temperature. The updated Maurer forcing we used contains daily minimum and maximum temperatures. You can find the updated forcings at https://www.hydroshare.org/resource/17c896843cf940339c3c3496d0c1c077/, accessed on 5 December 2024.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Clark, M.P.; Nijssen, B.; Lundquist, J.D.; Kavetski, D.; Rupp, D.E.; Woods, R.A.; Freer, J.E.; Gutmann, E.D.; Wood, A.W.; Brekke, L.D.; et al. A Unified Approach for Process-Based Hydrologic Modeling: 1. Modeling Concept. Water Resour. Res. 2015, 51, 2498–2514. [Google Scholar] [CrossRef]
  2. Clark, M.P.; Slater, A.G.; Rupp, D.E.; Woods, R.A.; Vrugt, J.A.; Gupta, H.V.; Wagener, T.; Hay, L.E. Framework for Understanding Structural Errors (FUSE): A Modular Framework to Diagnose Differences between Hydrological Models. Water Resour. Res. 2008, 44, W00B02. [Google Scholar] [CrossRef]
  3. Zhao, R.J. The Xinanjiang Model Applied in China. J. Hydrol. 1992, 135, 371–381. [Google Scholar]
  4. Fenicia, F.; Kavetski, D.; Savenije, H.H.G.; Clark, M.P.; Schoups, G.; Pfister, L.; Freer, J. Catchment Properties, Function, and Conceptual Model Representation: Is There a Correspondence? Hydrol. Process. 2014, 28, 2451–2467. [Google Scholar] [CrossRef]
  5. Jehanzaib, M.; Ajmal, M.; Achite, M.; Kim, T.-W. Comprehensive Review: Advancements in Rainfall-Runoff Modelling for Flood Mitigation. Climate 2022, 10, 147. [Google Scholar] [CrossRef]
  6. Prieto, C.; Le Vine, N.; Kavetski, D.; García, E.; Medina, R. Flow Prediction in Ungauged Catchments Using Probabilistic Random Forests Regionalization and New Statistical Adequacy Tests. Water Resour. Res. 2019, 55, 4364–4392. [Google Scholar] [CrossRef]
  7. Kratzert, F.; Gauch, M.; Klotz, D.; Nearing, G. HESS Opinions: Never Train a Long Short-Term Memory (LSTM) Network on a Single Basin. Hydrol. Earth Syst. Sci. 2024, 28, 4187–4201. [Google Scholar] [CrossRef]
  8. Kratzert, F.; Klotz, D.; Shalev, G.; Klambauer, G.; Hochreiter, S.; Nearing, G. Towards Learning Universal, Regional, and Local Hydrological Behaviors via Machine Learning Applied to Large-Sample Datasets. Hydrol. Earth Syst. Sci. 2019, 23, 5089–5110. [Google Scholar] [CrossRef]
  9. Kratzert, F.; Klotz, D.; Brenner, C.; Schulz, K.; Herrnegger, M. Rainfall–runoff modelling using Long Short-Term Memory (LSTM) networks. Hydrol. Earth Syst. Sci. 2018, 22, 6005–6022. [Google Scholar] [CrossRef]
  10. Xiang, Z.; Yan, J.; Demir, I. A Rainfall-Runoff Model With LSTM-Based Sequence-to-Sequence Learning. Water Resour. Res. 2020, 56, e2019WR025326. [Google Scholar] [CrossRef]
  11. Xu, Y.; Hu, C.; Wu, Q.; Jian, S.; Li, Z.; Chen, Y.; Zhang, G.; Zhang, Z.; Wang, S. Research on Particle Swarm Optimization in LSTM Neural Networks for Rainfall-Runoff Simulation. J. Hydrol. 2022, 608, 127553. [Google Scholar] [CrossRef]
  12. Yao, Z.; Wang, Z.; Wang, D.; Wu, J.; Chen, L. An Ensemble CNN-LSTM and GRU Adaptive Weighting Model Based Improved Sparrow Search Algorithm for Predicting Runoff Using Historical Meteorological and Runoff Data as Input. J. Hydrol. 2023, 625, 129977. [Google Scholar] [CrossRef]
  13. Yin, H.; Zhang, X.; Wang, F.; Zhang, Y.; Xia, R.; Jin, J. Rainfall-Runoff Modeling Using LSTM-Based Multi-State-Vector Sequence-to-Sequence Model. J. Hydrol. 2021, 598, 126378. [Google Scholar] [CrossRef]
  14. Yin, H.; Guo, Z.; Zhang, X.; Chen, J.; Zhang, Y. RR-Former: Rainfall-Runoff Modeling Based on Transformer. J. Hydrol. 2022, 609, 127781. [Google Scholar] [CrossRef]
  15. Luo, D.; Wang, X. ModernTCN: A Modern Pure Convolution Structure for General Time Series Analysis. In Proceedings of the Twelfth International Conference on Learning Representations, Vienna, Austria, 7–11 May 2024. [Google Scholar]
  16. Nourani, V.; Behfar, N. Multi-Station Runoff-Sediment Modeling Using Seasonal LSTM Models. J. Hydrol. 2021, 601, 126672. [Google Scholar] [CrossRef]
  17. Zeng, A.; Chen, M.; Zhang, L.; Xu, Q. Are Transformers Effective for Time Series Forecasting? In Proceedings of the 37th AAAI Conference on Artificial Intelligence, Washington, DC, USA, 7–14 February 2023; pp. 1121–11128. [Google Scholar] [CrossRef]
  18. Wu, H.; Hu, T.; Liu, Y.; Zhou, H.; Wang, J.; Long, M. TimesNet: Temporal 2D-Variation Modeling for General Time Series Analysis. In Proceedings of the Eleventh International Conference on Learning Representations, Kigali, Rwanda, 1–5 May 2023. [Google Scholar]
  19. Finnerty, B.D.; Smith, M.B.; Seo, D.-J.; Koren, V.; Moglen, G.E. Space-Time Scale Sensitivity of the Sacramento Model to Radar-Gage Precipitation Inputs. J. Hydrol. 1997, 203, 21–38. [Google Scholar] [CrossRef]
  20. Koren, V.; Smith, M.; Cui, Z. Physically-Based Modifications to the Sacramento Soil Moisture Accounting Model. Part A: Modeling the Effects of Frozen Ground on the Runoff Generation Process. J. Hydrol. 2014, 519, 3475–3491. [Google Scholar] [CrossRef]
  21. Arnold, J.G.; Srinivasan, R.; Muttiah, R.S.; Williams, J.R. Large Area Hydrologic Modeling and Assessment Part I: Model Development1. JAWRA J. Am. Water Resour. Assoc. 1998, 34, 73–89. [Google Scholar] [CrossRef]
  22. Newman, A.J.; Mizukami, N.; Clark, M.P.; Wood, A.W.; Nijssen, B.; Nearing, G. Benchmarking of a Physically Based Hydrologic Model. J. Hydrometeor. 2017, 18, 2215–2225. [Google Scholar] [CrossRef]
  23. Mizukami, N.; Rakovec, O.; Newman, A.J.; Clark, M.P.; Wood, A.W.; Gupta, H.V.; Kumar, R. On the Choice of Calibration Metrics for “High-Flow” Estimation Using Hydrologic Models. Hydrol. Earth Syst. Sci. 2019, 23, 2601–2614. [Google Scholar] [CrossRef]
  24. Seibert, J.; Vis, M.J.P. Teaching Hydrological Modeling with a User-Friendly Catchment-Runoff-Model Software Package. Hydrol. Earth Syst. Sci. 2012, 16, 3315–3325. [Google Scholar] [CrossRef]
  25. Seibert, J.; Vis, M.J.P.; Lewis, E.; Van Meerveld, H.J. Upper and Lower Benchmarks in Hydrological Modelling. Hydrol. Process. 2018, 32, 1120–1125. [Google Scholar] [CrossRef]
  26. Nearing, G.S.; Kratzert, F.; Sampson, A.K.; Pelissier, C.S.; Klotz, D.; Frame, J.M.; Prieto, C.; Gupta, H.V. What Role Does Hydrological Science Play in the Age of Machine Learning? Water Resour. Res. 2021, 57, e2020WR028091. [Google Scholar] [CrossRef]
  27. Kratzert, F.; Klotz, D.; Herrnegger, M.; Sampson, A.K.; Hochreiter, S.; Nearing, G.S. Toward Improved Predictions in Ungauged Basins: Exploiting the Power of Machine Learning. Water Resour. Res. 2019, 55, 11344–11354. [Google Scholar] [CrossRef]
  28. Zhang, J.; Chen, X.; Khan, A.; Zhang, Y.; Kuang, X.; Liang, X.; Taccari, M.L.; Nuttall, J. Daily Runoff Forecasting by Deep Recursive Neural Network. J. Hydrol. 2021, 596, 126067. [Google Scholar] [CrossRef]
  29. Zhang, B.; Ouyang, C.; Cui, P.; Xu, Q.; Wang, D.; Zhang, F.; Li, Z.; Fan, L.; Lovati, M.; Liu, Y.; et al. Deep Learning for Cross-Region Streamflow and Flood Forecasting at a Global Scale. Innovation 2024, 5, 100617. [Google Scholar] [CrossRef]
  30. Van, S.P.; Le, H.M.; Thanh, D.V.; Dang, T.D.; Loc, H.H.; Anh, D.T. Deep Learning Convolutional Neural Network in Rainfall–Runoff Modelling. J. Hydroinform. 2020, 22, 541–561. [Google Scholar] [CrossRef]
  31. Song, C.M. Data Construction Methodology for Convolution Neural Network Based Daily Runoff Prediction and Assessment of Its Applicability. J. Hydrol. 2022, 605, 127324. [Google Scholar] [CrossRef]
  32. Wu, H.; Xu, J.; Wang, J.; Long, M. Autoformer: Decomposition Transformers with Auto-Correlation for Long-Term Series Forecasting. In Proceedings of the 35th International Conference on Neural Information Processing Systems, New York, NY, USA, 6–14 December 2021; Volume 34, pp. 22419–22430. [Google Scholar]
  33. Wang, Y.; Wu, H.; Dong, J.; Liu, Y.; Qiu, Y.; Zhang, H.; Wang, J.; Long, M. TimeXer: Empowering Transformers for Time Series Forecasting with Exogenous Variables. arXiv 2024, arXiv:2402.19072. [Google Scholar]
  34. Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, Ł.; Polosukhin, I. Attention Is All You Need. In Proceedings of the 31st International Conference on Neural Information Processing Systems, New York, NY, USA, 4–9 December 2017; pp. 6000–6010. [Google Scholar]
  35. Zhou, T.; Ma, Z.; Wen, Q.; Wang, X.; Sun, L.; Jin, R. FEDformer: Frequency Enhanced Decomposed Transformer for Long-Term Series Forecasting. In Proceedings of the 39th International Conference on Machine Learning, Baltimore, MD, USA, 17–23 July 2022; pp. 27268–27286. [Google Scholar]
  36. Xie, S.; Girshick, R.; Dollar, P.; Tu, Z.; He, K. Aggregated Residual Transformations for Deep Neural Networks. In Proceedings of the 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Honolulu, HI, USA, 21–26 July 2017; pp. 1492–1500. [Google Scholar]
  37. Liu, Z.; Mao, H.; Wu, C.-Y.; Feichtenhofer, C.; Darrell, T.; Xie, S. A ConvNet for the 2020s. In Proceedings of the 2022 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), New Orleans, LA, USA, 19–23 June 2022; pp. 11976–11986. [Google Scholar]
  38. Press, O.; Wolf, L. Using the Output Embedding to Improve Language Models. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics, Valencia, Spain, 3–7 April 2017; pp. 157–163. [Google Scholar]
  39. He, K.; Zhang, X.; Ren, S.; Sun, J. Deep Residual Learning for Image Recognition. In Proceedings of the 29th IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Las Vegas, NV, USA, 26 June–1 July 2016; pp. 770–778. [Google Scholar]
  40. Nash, J.E.; Sutcliffe, J.V. River Flow Forecasting through Conceptual Models Part I—A Discussion of Principles. J. Hydrol. 1970, 10, 282–290. [Google Scholar] [CrossRef]
  41. Addor, N.; Newman, A.J.; Mizukami, N.; Clark, M.P. The CAMELS Data Set: Catchment Attributes and Meteorology for Large-Sample Studies. Hydrol. Earth Syst. Sci. 2017, 21, 5293–5313. [Google Scholar] [CrossRef]
  42. Newman, A.J.; Clark, M.P.; Sampson, K.; Wood, A.; Hay, L.E.; Bock, A.; Viger, R.J.; Blodgett, D.; Brekke, L.; Arnold, J.R.; et al. Development of a Large-Sample Watershed-Scale Hydrometeorological Data Set for the Contiguous USA: Data Set Characteristics and Assessment of Regional Variability in Hydrologic Model Performance. Hydrol. Earth Syst. Sci. 2015, 19, 209–223. [Google Scholar] [CrossRef]
  43. Liang, X.; Lettenmaier, D.P.; Wood, E.F.; Burges, S.J. A Simple Hydrologically Based Model of Land Surface Water and Energy Fluxes for General Circulation Models. J. Geophys. Res. 1994, 99, 14415–14428. [Google Scholar] [CrossRef]
  44. Samaniego, L.; Kumar, R.; Attinger, S. Multiscale Parameter Regionalization of a Grid-Based Hydrologic Model at the Mesoscale. Water Resour. Res. 2010, 46, W05523. [Google Scholar] [CrossRef]
  45. Mizukami, N.; Clark, M.P.; Newman, A.J.; Wood, A.W.; Gutmann, E.D.; Nijssen, B.; Rakovec, O.; Samaniego, L. Towards Seamless Large-Domain Parameter Estimation for Hydrologic Models. Water Resour. Res. 2017, 53, 8020–8040. [Google Scholar] [CrossRef]
  46. Rakovec, O.; Mizukami, N.; Kumar, R.; Newman, A.J.; Thober, S.; Wood, A.W.; Clark, M.P.; Samaniego, L. Diagnostic Evaluation of Large-Domain Hydrologic Models Calibrated Across the Contiguous United States. J. Geophys. Res. 2019, 124, 13991–14007. [Google Scholar] [CrossRef]
  47. Xu, T.; Liang, F. Machine Learning for Hydrologic Sciences: An Introductory Overview. WIREs Water 2021, 8, e1533. [Google Scholar] [CrossRef]
  48. De la Fuente, L.A.; Ehsani, M.R.; Gupta, H.V.; Condon, L.E. Toward Interpretable LSTM-Based Modeling of Hydrological Systems. Hydrol. Earth Syst. Sci. 2024, 28, 945–971. [Google Scholar] [CrossRef]
Figure 1. Variations in hydrological data: (a) daily average short-wave radiation, (b) daily minimum and maximum air temperature, (c) vapor pressure and (d) daily cumulative precipitation and streamflow. All data are from 1 January 2005 to 31 December 2007.
Figure 1. Variations in hydrological data: (a) daily average short-wave radiation, (b) daily minimum and maximum air temperature, (c) vapor pressure and (d) daily cumulative precipitation and streamflow. All data are from 1 January 2005 to 31 December 2007.
Water 17 00339 g001
Figure 2. An example to illustrate the 2 D structure in time series. By discovering the periodicity, we can transform the original 1 D time series into structured 2 D tensors, which can be processed by 2 D kernels conveniently.
Figure 2. An example to illustrate the 2 D structure in time series. By discovering the periodicity, we can transform the original 1 D time series into structured 2 D tensors, which can be processed by 2 D kernels conveniently.
Water 17 00339 g002
Figure 3. Comparisonbetween different forecasting paradigms. The inputs of forecasting with exogenous variables include multiple external variables { Z ( 1 ) , Z ( 2 ) , , Z ( C ) } , which serve as auxiliary information and are not required for forecasting.
Figure 3. Comparisonbetween different forecasting paradigms. The inputs of forecasting with exogenous variables include multiple external variables { Z ( 1 ) , Z ( 2 ) , , Z ( C ) } , which serve as auxiliary information and are not required for forecasting.
Water 17 00339 g003
Figure 4. Comparison of the model structures between TimesNet (a) and ED-TimesNet (b). TimesNet exhibits a linear structure, whereas ED-TimesNet employs an encoder–decoder architecture.
Figure 4. Comparison of the model structures between TimesNet (a) and ED-TimesNet (b). TimesNet exhibits a linear structure, whereas ED-TimesNet employs an encoder–decoder architecture.
Water 17 00339 g004
Figure 5. The input samples in the experiments with catchment attributes: (a) TimesNet and (b) ED-TimesNet.
Figure 5. The input samples in the experiments with catchment attributes: (a) TimesNet and (b) ED-TimesNet.
Water 17 00339 g005
Figure 6. TheNSE CDFs of the ED-TimesNet and TimesNet models for 7-day-ahead runoff predictions on 448 basins. The seven panels represent (ag) the 1st-day-ahead to the 7th-day-ahead runoff prediction results. Experimental results with catchment attributes are shown in solid lines, while those without catchment attributes are shown in dashed lines.
Figure 6. TheNSE CDFs of the ED-TimesNet and TimesNet models for 7-day-ahead runoff predictions on 448 basins. The seven panels represent (ag) the 1st-day-ahead to the 7th-day-ahead runoff prediction results. Experimental results with catchment attributes are shown in solid lines, while those without catchment attributes are shown in dashed lines.
Water 17 00339 g006
Figure 7. An illustration of the comparison between ED-TimesNet (with catchment attributes) and TimesNet (with catchment attributes) from 1 September 1998 to 1 September 1999. ED-TimesNet-i refers to the ith-day-ahead runoff predictions provided by ED-TimesNet.
Figure 7. An illustration of the comparison between ED-TimesNet (with catchment attributes) and TimesNet (with catchment attributes) from 1 September 1998 to 1 September 1999. ED-TimesNet-i refers to the ith-day-ahead runoff predictions provided by ED-TimesNet.
Water 17 00339 g007
Figure 8. TheNSE CDFs of the ED-TimesNet model and four regionally calibrated benchmark models (RR-Former, LSTM, VIC, and mHM) for 7-day-ahead runoff predictions. The seven panels represent (ag) the 1st-day-ahead to the 7th-day-ahead runoff prediction results. Among them, the LSTM, VIC, and mHM models only have performances for the (a) 1st-day-ahead prediction, while our model and the RR-Former model provide predictions for all 7 days (ag).
Figure 8. TheNSE CDFs of the ED-TimesNet model and four regionally calibrated benchmark models (RR-Former, LSTM, VIC, and mHM) for 7-day-ahead runoff predictions. The seven panels represent (ag) the 1st-day-ahead to the 7th-day-ahead runoff prediction results. Among them, the LSTM, VIC, and mHM models only have performances for the (a) 1st-day-ahead prediction, while our model and the RR-Former model provide predictions for all 7 days (ag).
Water 17 00339 g008
Table 1. Thesummary of rainfall-runoff models mentioned in this article.
Table 1. Thesummary of rainfall-runoff models mentioned in this article.
CategoriesCharacteristicsModelsStrengthsWeaknesses
Traditional methods
  • Parameters are derived from calibration and field data.
  • Requires large hydro-meteorological data.
  • Requires prior knowledge of hydrological systems.
  • Requires data about the initial state of model and morphology of catchment.
SAC-SMA, SWAT, VIC, mHM, HBV
  • A large amount of practical experience.
  • Clear interpretability.
  • Limited capacity for regional modeling.
  • Large number of data and calibration needed.
Data-driven methods
  • Data-based.
  • Requires hydrological and meteorological data.
  • Derives value from available time series.
  • Little consideration of features and processes of the hydrological system.
CNNs, LSTMs, Transformers
  • Proven effectiveness in large-scale (regional, continental, global) modeling [8].
  • Better performance in ungauged catchments [6].
  • No need for explicit physical assumptions or complex parameterization.
  • Black-box model.
  • Lack of interpretability.
Table 2. Table of catchment attributes used in the experiment. Description taken from the dataset [42].
Table 2. Table of catchment attributes used in the experiment. Description taken from the dataset [42].
CategoryAttributeDescription
Climatep-meanMean daily precipitation.
pet-meanMean daily potential evapotranspiration.
aridityRatio of mean PET to mean precipitation. Seasonality and timing of precipitation. Estimated by representing annual precipitation and temperature as sin waves. Positive (negative) values.
p-seasonalitySeasonality and timing of precipitation. The positive (negative) values indicate that precipitation peaks in summer (winter), values close to 0 indicate uniform precipitation throughout the year.
frac-snow-dailyFraction of precipitation falling on days with temperatures below 0 °C
high-prec-freqFrequency of high precipitation days (⩾5 times mean daily precipitation).
high-prec-durAverage duration of high precipitation events (number of consecutive days with ⩾5 times mean daily precipitation).
low-prec-freqFrequency of dry days (<1 mm/day).
low-prec-durAverage duration of dry periods (number of consecutive days with precipitation < 1 mm/day).
Topographyelev_meanCatchment mean elevation.
slope-meanCatchment mean slope.
area-gages2Catchment area.
Vegetationforest-fracForest fraction.
lai-maxMaximum monthly mean of leaf area index.
lai-diffDifference between the max. and min. mean of the leaf area index.
gvf-maxMaximum monthly mean of green vegetation fraction.
gvf-diffDifference between the maximum and minimum monthly mean of the green vegetation fraction.
Soilsoil-depth-pelletierDepth to bedrock (maximum 50 m).
soil-depth-statsgoSoil depth (maximum 1.5 m).
soil-porosityVolumetric porosity.
soil-conductivitySaturated hydraulic conductivity.
max-water-contentMaximum water content of the soil.
sand-fracFraction of sand in the soil.
silt-fracFraction of silt in the soil.
clay-fracFraction of clay in the soil.
Geologycarb-rocks-fracFraction of the catchment area characterized as “Carbonate sedimentary rocks”.
geol-permeabilitySurface permeability (log10).
Table 3. Experimental setup of TimesNet and ED-TimesNet.
Table 3. Experimental setup of TimesNet and ED-TimesNet.
HyperparametersValue
K3
Epoch30
Batch size512
Dropout rate0.1
Initial learning rate0.001
Sequence length (Meteorology)22
Label length (Streamflow)15
Predict length (Streamflow)7
Dimension of the model inputs32
Dimension of the hidden layers64
Number of encoder and decoder layers2
Number of inception blocks’ kernels6
Table 4. Performance of TimesNet and ED-TimesNet.
Table 4. Performance of TimesNet and ED-TimesNet.
Evaluation Metric1st-day-ahead2nd-day-ahead3rd-day-ahead
E1 1E2 2T1 3T2 4E1E2T1T2E1E2T1T2
Mean of NSE0.781  60.700  70.7510.6770.7400.6360.7200.6130.7240.6080.6870.581
Median of NSE0.8050.7290.7870.7210.7590.6710.7460.6510.7430.6550.7170.637
Failures  5020618110111112
4td-day-ahead5td-day-ahead6td-day-ahead7td-day-ahead
E1E2T1T2E1E2T1T2E1E2T1T2E1E2T1T2
0.7110.5970.6820.5670.7060.5880.6770.5640.6990.5950.6730.5560.6910.5800.6610.550
0.7350.6370.7070.6220.7280.6390.7010.6160.7250.6270.6980.6060.7140.6130.6860.599
281103111104611228110
1 ED-TimesNet with catchment attributes. 2 ED-TimesNet without catchment attributes. 3 TimesNet with catchment attributes. 4 TimesNet without catchment attributes. 5 No. of basins with NSE ⩽ 0. 6 The optimal results for the models with catchment attributes are highlighted in bold. 7 The optimal results for the models without catchment attributes are underlined.
Table 5. Comparison of the ED-TimesNet to the full set of benchmark models. All data presented in the table have been subject to rounding.
Table 5. Comparison of the ED-TimesNet to the full set of benchmark models. All data presented in the table have been subject to rounding.
Nth-Day-AheadAttributesModelNSERMSEATPE-2%KGE
Mean Median Mean Median Mean Median Mean Median
1withED-TimesNet0.781  20.8051.3061.1050.3110.3080.8120.844
RR-Former0.7690.8081.3101.1080.3230.3110.7680.832
LSTM0.6920.7301.4981.2800.3870.3580.7200.770
VIC 10.1680.3062.4032.0710.6700.6810.1400.256
mHM 10.4410.5271.9931.7020.5650.5500.4020.468
withoutED-TimesNet0.700  30.7291.5001.3150.3780.3760.7370.765
RR-Former0.6870.7521.4171.2400.3540.3450.7490.818
2withED-TimesNet0.7400.7591.4161.2160.3570.3530.7640.796
RR-Former0.7170.7581.4211.2250.3560.3430.7590.807
withoutED-TimesNet0.6360.6711.6231.4510.4270.4280.7650.717
RR-Former0.6070.6971.5471.3630.4030.3970.6990.761
3withED-TimesNet0.7240.7431.4581.2550.3780.3750.7440.771
RR-Former0.7020.7451.4501.2530.3640.3530.7390.793
withoutED-TimesNet0.6080.6551.6641.4880.4390.4360.6820.707
RR-Former0.5680.6861.5951.4120.4190.4100.6810.747
4withED-TimesNet0.7110.7351.4861.2840.3870.3770.7400.770
RR-Former0.6930.7331.4861.2880.3740.3630.7280.778
withoutED-TimesNet0.5970.6371.6991.4980.4490.4480.6750.702
RR-Former0.5230.6681.6301.4350.4250.4070.6790.752
5withED-TimesNet0.7060.7281.4981.3020.3840.3750.7400.778
RR-Former0.6940.7321.5011.2850.3850.3730.7040.755
withoutED-TimesNet0.5880.6391.7191.5050.4600.4540.6630.691
RR-Former0.5230.6651.6471.4590.4320.4130.6700.743
6withED-TimesNet0.6990.7251.5181.3150.3940.3870.7280.761
RR-Former0.6900.7301.4971.3040.3800.3630.7270.778
withoutED-TimesNet0.5950.6271.7351.5450.4700.4700.6490.668
RR-Former0.5000.6571.6651.4830.4440.4280.6400.718
7withED-TimesNet0.6910.7141.5421.3200.3990.3870.7230.760
RR-Former0.6820.7251.5201.3210.3730.3560.7140.766
withoutED-TimesNet0.5800.6131.7631.5590.4700.4710.6440.672
RR-Former0.4630.6401.6941.5200.4500.4340.6360.719
1 The performance of both the VIC model and the mHM model reflects that of regional rainfall-runoff models, specifically VIC(CONUS) and mHM(CONUS). 2 The optimal results for the models with catchment attributes are highlighted in bold. 3 The optimal results for the models without catchment attributes are underlined.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Jiang, W.; Dang, X.; Zhang, R. Empowering Regional Rainfall-Runoff Modeling Through Encoder–Decoder Based on Convolutional Neural Networks. Water 2025, 17, 339. https://doi.org/10.3390/w17030339

AMA Style

Jiang W, Dang X, Zhang R. Empowering Regional Rainfall-Runoff Modeling Through Encoder–Decoder Based on Convolutional Neural Networks. Water. 2025; 17(3):339. https://doi.org/10.3390/w17030339

Chicago/Turabian Style

Jiang, Wei, Xupeng Dang, and Rui Zhang. 2025. "Empowering Regional Rainfall-Runoff Modeling Through Encoder–Decoder Based on Convolutional Neural Networks" Water 17, no. 3: 339. https://doi.org/10.3390/w17030339

APA Style

Jiang, W., Dang, X., & Zhang, R. (2025). Empowering Regional Rainfall-Runoff Modeling Through Encoder–Decoder Based on Convolutional Neural Networks. Water, 17(3), 339. https://doi.org/10.3390/w17030339

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop