Hydrological uncertainty analysis method and system coupled with deep learning under changing environment
Patent Information
- Application Number
- CN202610817149.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-08
- Publication Date
- 2026-08-28
AI Technical Summary
传统水文模型往往仅依赖于物理机制构建,但受制于复杂水文过程的非线性特性以及众多不确定性因素,如参数估计误差、观测数据不准确等,其在复杂变化环境下预报精度有限,难以全面且精准地刻画水文预报的不确定性
[0079] This invention provides a method and system for hydrological uncertainty analysis coupled with deep learning under changing environments. It innovatively integrates deep learning models with physical hydrological models, using the hydrological forecast results of the physical hydrological model as input to the deep learning model. The deep learning model is optimized with a unique loss function guided by physics (covering average bandwidth, coverage, median bandwidth, and observation determinism coefficients, etc.). Under the synergy of the physical architecture, the deep learning model significantly improves its nonlinear fitting ability and significantly reduces the forecast uncertainty of the physical hydrological model, providing a more advanced, accurate, and reliable uncertainty analysis solution for the hydrological field.
Smart Images

Figure CN122654541A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of hydrological forecasting technology in hydrology, specifically to a method and system for analyzing hydrological uncertainties coupled with deep learning under changing environments. Background Technology
[0002] With the continuous changes in climate and the increasing impact of human activities on the natural hydrological environment, the rational allocation and efficient utilization of water resources are becoming increasingly crucial. Accurate hydrological forecasting plays an irreplaceable role in many areas, including ensuring flood control safety, optimizing water resource allocation, guiding agricultural irrigation, and planning urban water supply. For example, accurate hydrological forecasts before heavy rains provide a scientific basis for reservoir operation, allowing for timely flood discharge to avoid disasters; during dry seasons, reliable runoff predictions help to rationally arrange irrigation sequences and reduce agricultural losses.
[0003] However, existing techniques for analyzing uncertainties in hydrological forecasting have many shortcomings. Traditional hydrological models often rely solely on physical mechanisms for construction, but are limited by the nonlinear characteristics of complex hydrological processes and numerous uncertainties, such as parameter estimation errors and inaccurate observation data. Their forecast accuracy is limited under complex and changing environments, making it difficult to comprehensively and accurately characterize the uncertainties in hydrological forecasts. While deep learning methods excel at handling nonlinear problems, their generalization ability is somewhat limited in specific hydrological scenarios if applied in isolation without physical guidance. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention provides a method and system for hydrological uncertainty analysis coupled with deep learning under changing environments, which can effectively solve the aforementioned problems.
[0005] The technical solution adopted in this invention is as follows:
[0006] In a first aspect, the present invention provides a method for analyzing hydrological uncertainties coupled with deep learning under changing environments, comprising:
[0007] Step S1: Construct a physical hydrological model and a spatiotemporal dynamic environmental factor model. Analyze the historical hydrological and meteorological datasets of the target watershed over many years. Through spatiotemporal matching and feature fusion, construct a multi-model feature dataset.
[0008] In each training batch, a time step of length of is selected from the multi-modal feature dataset. Furthermore, the multi-modal feature data sequence is arranged in time sequence, where time steps Multimodal feature data , , For multi-mode state data, For hydrological observation data, For meteorological driving data, The physical hydrological model is driven by meteorological data. As input, hydrological forecast data obtained based on physical mechanisms. The data of changing environmental factors generated using the aforementioned spatiotemporal dynamic environmental factor model;
[0009] Step S2: Construct the generator main network based on the time-series deep learning model. The generator main network Using multi-mode state data sequences as input, the evolution trend of hydrological forecast data sequences is extracted through linear mapping, generating high-dimensional hidden state data sequences containing hydrophysical and environmental context information. The first branch of the output layer outputs a hydrological forecast trend feature sequence. Simultaneously, a causal relationship analysis is performed on the uncertainty of hydrological forecast data sequences caused by changing environmental factors at each time step. The uncertainty of hydrological forecast data caused by changes in environmental factors is adaptively quantified into a preliminary half-bandwidth thickness, and the Softplus activation function is forcibly applied to obtain the half-bandwidth thickness. Then, taking the hydrological forecast trend characteristics as the center, the upper and lower bounds of the uncertainty bandwidth, representing the uncertainty of the hydrological forecast, are symmetrically generated at the half-bandwidth thickness positions above and below them. At each time step, generate the upper limit trajectory of uncertain bandwidth and the lower limit trajectory of uncertain bandwidth;
[0010] Step S3: Design a temporal convolutional network with a weight-sharing dual-branch structure as an adversarial discriminator. Forced generator main network The output trajectory with upper and lower bounds of uncertainty bandwidth exhibits the true fluctuation characteristics of physical hydrological errors.
[0011] Step S4, Joint Generator Main Network Physically guided weighted multi-objective main loss function and adversarial discriminator Physical consistency adversarial constraint loss function Define the global total loss function. ;
[0012] Step S5, based on the global total loss function For the generator main network and adversarial discriminator The constructed deep learning models are jointly trained to obtain the trained generator main network. and adversarial discriminator ;
[0013] Step S6, in the hydrological forecasting stage, the physical hydrological model, the spatiotemporally dynamic environmental factor model, and the trained generator main network are used. A hydrological forecast uncertainty model is constructed. Future meteorological forecast data is input, and the hydrological forecast uncertainty model performs physical forward simulation and gating adaptive parameter mapping of changing environmental factors, and outputs the upper and lower limits of the uncertainty bandwidth of hydrological forecasts at each future time step.
[0014] Furthermore, the physical hydrological model is a parallel coupled model that includes multiple conceptual models; the conceptual models include the SWAT model, the Xin'anjiang model, and the HYMOD model.
[0015] Furthermore, within the target watershed, it was determined that there are The hydrological observation data at each spatial point For each spatial point within the target watershed Hydrological observation data The resulting vector is characterized as , , Transform the matrix to its rank; similarly, for hydrological forecast data... ; For spatial points Hydrological forecast data; data on changing environmental factors For the target watershed as a whole in time step Changes in environmental factors, for each spatial point The uncertainty of hydrological forecasts has an impact.
[0016] Furthermore, the physical hydrological model uses meteorological driving data. As input, hydrological forecast data are obtained based on physical mechanisms. ,include:
[0017] At each spatial point in the target watershed The physical hydrological model adopts the overall target watershed at time step Meteorological driving data Based on pre-calibrated fixed physical parameters At the corresponding spatial point Perform hydrophysical runoff generation and confluence simulation, and output spatial points. In time step Hydrological forecast data The formula is represented as ; Describe spatial points The hydrophysical runoff generation and confluence simulation process; wherein, the hydrological forecast data includes one or both of the runoff forecast data and water level forecast data at the outlet of the target basin; the meteorological driving data This consists of multidimensional meteorological data, including rainfall and temperature data;
[0018] Hydrological forecast data for all spatial points in the target watershed Combined into the target watershed at time step Hydrological forecast data .
[0019] Furthermore, the changed environmental factor data Including the dynamic change rate of precipitation Temperature dynamic change rate Reservoir dynamic regulation coefficient and the dynamic water use ratio for agricultural irrigation Characterized as The spatiotemporal dynamic environmental factor model generates the changing environmental factor data. The method is as follows:
[0020] ① Using formula (1), the dynamic change rate of precipitation is generated. :
[0021] (1)
[0022] Among them: W s The time-series sliding window length; For time step Rainfall at that time ; This represents the multi-year average precipitation; using this time-series sliding window algorithm, short-term data are obtained in conjunction with hydrological forecast data.
[0023] Scale matching, simultaneously characterizing recent long-term precipitation feature changes ;
[0024] ②Use formula (2) to generate the dynamic temperature change rate. :
[0025] (2)
[0026] in: For time step The average temperature at that time; The average temperature over many years;
[0027] ③ Using formula (3), the dynamic regulation coefficient of the reservoir is generated. :
[0028] (3)
[0029] Where: N res V represents the total number of reservoirs within the target basin; i(t) and V i,max These are the real-time water storage and total storage capacity of the i-th reservoir, i=1~N. res Q i,out (t) and Q i,in (t) represents the real-time outflow and inflow, respectively; k1 and k2 are fixed weights; To prevent zero constant;
[0030] ④ Using formula (4), the dynamic water use ratio for agricultural irrigation is generated. :
[0031] (4)
[0032] in: This is for real-time agricultural irrigation water usage. This represents the total runoff of the basin.
[0033] Furthermore, the generator main network At each time step The method for symmetrically generating the upper and lower bounds of the uncertainty bandwidth to characterize the uncertainty of hydrological forecasts is as follows:
[0034] At each time step spatial point , , The number of spatial points within the target watershed will be used to determine the change ring.
[0035] The degree of uncertainty in hydrological forecast data caused by environmental factors is adaptively quantified into the initial half-bandwidth thickness. The half-bandwidth thickness is obtained using the Softplus activation function. : ;
[0036] Using formulas (5) and (6), spatial points are generated. Uncertainty bandwidth limit and uncertainty bandwidth lower limit :
[0037] (5)
[0038] (6)
[0039] in: The hydrological forecast trend characteristics are output by the first branch of the output layer.
[0040] Furthermore, the generator main network Physically guided weighted multi-objective main loss function The construction method is as follows:
[0041] The following six bandwidth performance evaluation metrics are defined:
[0042] ① Average bandwidth (MBW): measures the sharpness of a bandwidth range with uncertainty.
[0043] (7)
[0044] ② Coverage Rate (CR): Measures the reliability of hydrological observation data falling within the uncertainty bandwidth.
[0045] (8)
[0046] in: This is an indicator function; it takes the value 1 if the condition is true, and 0 otherwise. Spatial points of the target watershed In time step Hydrological observation data;
[0047] ③ Coefficient of Determinism (CCE): Measures the accuracy of the fit between the median bandwidth of the uncertainty bandwidth and the hydrological observation data.
[0048] (9)
[0049] in: For spatial points In the current training batch The average of hydrological observation data over a step;
[0050] ④ Discrete Environment Sensitivity (ES): The first-order finite difference is used to measure the bandwidth's response capability to sudden environmental changes.
[0051] (10)
[0052] in: It is an L2 norm; This represents the time difference operation between adjacent time steps; , Indicates time step Changes in environmental factor data With time Changes in environmental factor data Time difference operations; To prevent zero constant;
[0053] ⑤ Physical Continuity PC: Deviation between the dynamic change of the penalty bandwidth and the dynamic response of the physical hydrological model
[0054] (11)
[0055] in: This is the amplitude scaling constant;
[0056] ⑥ Physical Spatial Consistency (PSI): The bandwidth ratio of different spatial points within the target watershed must conform to the magnitude ratio of hydrological forecast data predicted by the physical hydrological model.
[0057] (12)
[0058] in: and They are spatial points Uncertainty bandwidth upper limit and uncertainty bandwidth lower limit; spatial point For different from spatial points Spatial points; For spatial points Hydrological forecast data;
[0059] By linearly weighting the aforementioned bandwidth performance evaluation metrics using fixed hyperparameters, the generator main network is constructed. Physically guided weighted multi-objective main loss function :
[0060] (13)
[0061] in: These are the fixed hyperparameters for the corresponding bandwidth performance evaluation indicators.
[0062] Furthermore, the adversarial discriminator Physical consistency adversarial constraint loss function The construction method is as follows:
[0063] ① Calculate the true absolute physical residual sequence of the physical hydrological model in the current training batch. ; In order to be in time step The true absolute physical residual, ;
[0064] ② Extract the generator main network The generated bandwidth sequence ; In order to be in time step bandwidth, , Uncertainty bandwidth limit for all spatial points in the target watershed The combined data ; Lower bound of uncertainty bandwidth for all spatial points in the target watershed The combined data ;
[0065] ③ and Input adversarial discriminator The two branches with shared weights are used to construct the physical consistency adversarial constraint loss function. :
[0066] (14)
[0067] in: represents the mathematical expectation; D(·) represents the probability that the adversarial discriminator determines the input sequence to be a true absolute physical residual sequence.
[0068] Furthermore, define the global total loss function. , To combat weight hyperparameters, step S5 employs an alternating training mechanism and a composite convergence termination criterion to train the generator main network. and adversarial discriminator The constructed deep learning models are jointly trained:
[0069] ① Alternating training:
[0070] Fixed Generator Main Network Update the adversarial discriminator The network parameters make Maximize and improve the adversarial discriminator The ability to capture physical temporal characteristics;
[0071] Fixed adversarial discriminator The generator main network is updated using the Adam optimization algorithm. The parameters minimize the global total loss function. This ensures that the generated bandwidth closely approximates the real physical characteristics and meets various bandwidth performance evaluation indicators.
[0072] ② Composite convergence termination criterion: During the training process, various bandwidth performance evaluation indicators are monitored through an independent validation set;
[0073] The alternating iteration process terminates and the current network parameters are saved as the final business model when any of the following stopping conditions are met:
[0074] Early stopping condition for physical performance: Within P consecutive iterations, the generator main network... Main loss function on the validation set The relative decline rate is below the minimum threshold, and the coverage ratio (CR) reaches the preset target value;
[0075] Adversarial equilibrium condition: Adversarial discriminator For true absolute physical residuals With bandwidth The mean output of the discrimination probability consistently oscillates between 0.5 ± 0.05, indicating that the adversarial discriminator... Unable to distinguish between genuine and fake, and the generator's main network It cannot be reduced further under these conditions. ;
[0076] Maximum iteration fallback condition: The total number of alternating training rounds reaches a preset upper limit threshold N. max Force a stop and backtrack to select the network parameters for the round with the best overall performance on the validation set.
[0077] Secondly, the present invention provides a hydrological uncertainty analysis system coupled with deep learning under changing environments, for implementing the hydrological uncertainty analysis method coupled with deep learning under changing environments.
[0078] The beneficial effects of this invention are as follows:
[0079] This invention provides a method and system for hydrological uncertainty analysis coupled with deep learning under changing environments. It innovatively integrates deep learning models with physical hydrological models, using the hydrological forecast results of the physical hydrological model as input to the deep learning model. The deep learning model is optimized with a unique loss function guided by physics (covering average bandwidth, coverage, median bandwidth, and observation determinism coefficients, etc.). Under the synergy of the physical architecture, the deep learning model significantly improves its nonlinear fitting ability and significantly reduces the forecast uncertainty of the physical hydrological model, providing a more advanced, accurate, and reliable uncertainty analysis solution for the hydrological field. Attached Figure Description
[0080] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0081] Figure 1 The flowchart illustrates the hydrological uncertainty analysis method coupled with deep learning under changing environments provided by this invention. Detailed Implementation
[0082] To make the technical problems solved, the technical solutions, and the beneficial effects of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and are not intended to limit the invention.
[0083] This invention provides a method and system for hydrological uncertainty analysis coupled with deep learning under changing environments. It innovatively integrates deep learning models with physical hydrological models, using the hydrological forecast results of the physical hydrological model as input to the deep learning model. The deep learning model is optimized with a unique loss function guided by physics (covering average bandwidth, coverage, median bandwidth, and observation determinism coefficients, etc.). Under the synergy of the physical architecture, the deep learning model significantly improves its nonlinear fitting ability and significantly reduces the forecast uncertainty of the physical hydrological model, providing a more advanced, accurate, and reliable uncertainty analysis solution for the hydrological field.
[0084] See Figure 1 The hydrological uncertainty analysis method coupled with deep learning under changing environments provided by this invention includes steps S1 to S6:
[0085] Step S1: Construct a physical hydrological model and a spatiotemporal dynamic environmental factor model. Analyze the historical hydrological and meteorological datasets of the target watershed over many years. Through spatiotemporal matching and feature fusion, construct a multi-model feature dataset.
[0086] In this step, each multimodal feature data in the multimodal feature dataset includes hydrological observation data. Meteorological driving data Physical hydrological models use meteorological data as the driving force. As input, hydrological forecast data obtained based on physical mechanisms. and the changing environmental factor data generated using a spatiotemporally dynamic environmental factor model. .
[0087] In this invention, the following key technologies are employed in constructing multimodal feature data:
[0088] (1) Constructing a physical hydrological model
[0089] Constructing a physical hydrological model suitable for the watershed is a preferred approach. The physical hydrological model is a parallel coupled model that includes multiple conceptual models, such as the SWAT model, the Xin'anjiang model, and the HYMOD model.
[0090] Physical hydrological models use meteorological driving data As input, hydrological forecast data are obtained based on physical mechanisms. ,include:
[0091] At each spatial point in the target watershed The physical hydrological model adopts the overall target watershed at time step Meteorological driving data Based on pre-calibrated fixed physical parameters At the corresponding spatial point Perform hydrophysical runoff generation and confluence simulation, and output spatial points. In time step Hydrological forecast data Its governing equations can be abstractly represented as: ; Describe spatial points The hydrophysical runoff generation and confluence simulation process; wherein, the hydrological forecast data includes one or both of the runoff forecast data and water level forecast data at the outlet of the target basin; the meteorological driving data For multidimensional meteorological characteristic data, T can be set flexibly, for example, the total time step forecast, K p The meteorological feature dimension includes rainfall, temperature, etc. A meteorological feature data matrix;
[0092] Hydrological forecast data for all spatial points in the target watershed Combined into the target watershed at time step Hydrological forecast data .
[0093] (2) Construction of changing environmental factors under time-series sliding window
[0094] Changes in environmental factor data Including the dynamic change rate of precipitation Temperature dynamic change rate Reservoir dynamic regulation coefficient and the dynamic water use ratio for agricultural irrigation Characterized as The spatiotemporal dynamic environmental factor model generates the changing environmental factor data. The method is as follows:
[0095] ① Using formula (1), the dynamic change rate of precipitation is generated. :
[0096] (1)
[0097] Among them: W s The length of the time-series sliding window, for example, the most recent 365 days; For time step Rainfall at time, hourly step It can be done daily; ; This represents the multi-year average precipitation; using this time-series sliding window algorithm, short-term time-scale matching with hydrological forecast data is obtained, while simultaneously characterizing the most recent long-term time-scale.
[0098] Changes in precipitation characteristics ;
[0099] ②Use formula (2) to generate the dynamic temperature change rate. :
[0100] (2)
[0101] in: For time step The average temperature at that time; The average temperature over many years;
[0102] ③ Using formula (3), the dynamic regulation coefficient of the reservoir is generated. :
[0103] (3)
[0104] Where: N res V represents the total number of reservoirs within the target basin; i (t) and V i,max These are the real-time water storage and total storage capacity of the i-th reservoir, i=1~N. res Q i,out (t) and Q i,in (t) represents the real-time outflow and inflow, respectively; k1 and k2 are fixed weights, generally set to k1=0.6 and k2=0.4; To prevent the constant from becoming zero, for example, we can take 10. -5 ;
[0105] ④ Using formula (4), the dynamic water use ratio for agricultural irrigation is generated. :
[0106] (4)
[0107] in: This is for real-time agricultural irrigation water usage. This represents the total runoff of the basin.
[0108] When using the multimodal feature data sample set constructed in this step, in each training batch, a time step of length of [missing value] is selected from the multimodal feature dataset. Furthermore, the multi-modal feature data sequence is arranged in time sequence, where time steps Multimodal feature data , , For multi-mode state data, For hydrological observation data, For meteorological driving data, The physical hydrological model is driven by meteorological data. As input, hydrological forecast data obtained based on physical mechanisms. The data of changing environmental factors generated using the aforementioned spatiotemporal dynamic environmental factor model;
[0109] Due to the characteristics of hydrological forecasting, this invention determines within the target watershed the presence of... The hydrological observation data at each spatial point For each spatial point within the target watershed Hydrological observation data The resulting vector is characterized as , , Transform the matrix to its rank; similarly, for hydrological forecast data... ; For spatial points Hydrological forecast data; data on changing environmental factors For the target watershed as a whole in time step Changes in environmental factors, for each spatial point The uncertainty of hydrological forecasts has an impact.
[0110] Step S2: Construct the generator main network based on the time-series deep learning model. ;
[0111] As one implementation method, the structural principles of the generator include the following four aspects:
[0112] (1) Input layer: consisting of N time steps Multimodal state data The resulting multi-mode state data sequence;
[0113] (2) Network structure design: The generator main network is constructed using a Long Short-Term Memory (LSTM) network. ;
[0114] Generator Main Network The main principle is:
[0115] The generator main network Using multi-mode state data sequences as input, the evolution trend of hydrological forecast data sequences is extracted through linear mapping, generating high-dimensional hidden state data sequences containing hydrophysical and environmental context information. The first branch of the output layer outputs a hydrological forecast trend feature sequence. Simultaneously, a causal relationship analysis is performed on the uncertainty of hydrological forecast data sequences caused by changing environmental factors at each time step. The uncertainty of hydrological forecast data caused by changes in environmental factors is adaptively quantified into an initial half-bandwidth thickness. For example, when the changes in environmental factor data E(t) generate drastic abnormal disturbances, such as illegal storage and release of water from reservoirs or extreme weather changes, the generator main network... The detection of instability signals deviating from the baseline assumptions of the physical hydrological model led to a hidden state. When a drift occurs, the second branch automatically outputs a significantly increased initial half-bandwidth thickness, instantly widening the upper and lower limits of the uncertainty bandwidth to warn of forecast risks; conversely, during a natural, stable evolution period, the network spontaneously tightens the bandwidth. This mechanism fundamentally gives the dynamic adaptive nature of hydrological uncertainty forecasting a physical meaning.
[0116] In this invention, the initial half-bandwidth thickness is forcibly processed using the Softplus activation function to obtain the half-bandwidth thickness. Then, taking the hydrological forecast trend characteristics as the center, symmetrical upper and lower bounds of the uncertainty bandwidth, representing the uncertainty of the hydrological forecast, are generated at the half-bandwidth thickness positions above and below them. At each time step, generate the upper limit trajectory of uncertain bandwidth and the lower limit trajectory of uncertain bandwidth.
[0117] (3) Constraint output: The main network output layer is divided into two branches, which output the hydrological forecast trend characteristics of each spatial point respectively. With adaptive half-bandwidth thickness To ensure that the upper and lower limits of the interval do not physically overlap, the Softplus activation function is forcibly applied to half the bandwidth, thereby calculating and outputting the final uncertain bandwidth upper limit. and uncertainty bandwidth lower limit .
[0118] As one implementation, the generator main network At each time step The method for symmetrically generating the upper and lower bounds of the uncertainty bandwidth to characterize the uncertainty of hydrological forecasts is as follows:
[0119] At each time step spatial point , , The number of spatial points within the target watershed will be used to determine the change ring.
[0120] The degree of uncertainty in hydrological forecast data caused by environmental factors is adaptively quantified into the initial half-bandwidth thickness. The half-bandwidth thickness is obtained using the Softplus activation function. : ;
[0121] Using formulas (5) and (6), spatial points are generated. Uncertainty bandwidth limit and uncertainty bandwidth lower limit :
[0122] (5)
[0123] (6)
[0124] in: The hydrological forecast trend characteristics are output by the first branch of the output layer.
[0125] (4) Physically guided weighted multi-objective main loss function
[0126] In this embodiment, a generator main network is constructed. Physically guided weighted multi-objective main loss function Its construction method is as follows:
[0127] Obtaining the generator's main network Output and Then, combined with hydrological observation data Calculate the main loss function L within a training batch of length N. main .
[0128] The following six bandwidth performance evaluation metrics are defined:
[0129] ① Average bandwidth (MBW): Measures the sharpness of the uncertain bandwidth range (the narrower the better).
[0130] (7)
[0131] ② Coverage Rate (CR): Measures the reliability of hydrological observation data falling within the uncertainty bandwidth.
[0132] (8)
[0133] in: This is an indicator function; it takes the value 1 if the condition is true, and 0 otherwise. Spatial points of the target watershed In time step Hydrological observation data;
[0134] ③ Coefficient of Determinism (CCE): Measures the accuracy of the fit between the median bandwidth of the uncertainty bandwidth and the hydrological observation data.
[0135] (9)
[0136] in: For spatial points In the current training batch The average of hydrological observation data over a step;
[0137] ④ Discrete Environment Sensitivity (ES): The first-order finite difference is used to measure the bandwidth's response capability to sudden environmental changes.
[0138] (10)
[0139] in: It is an L2 norm; This represents the time difference operation between adjacent time steps; , Indicates time step Changes in environmental factor data With time Changes in environmental factor data Time difference operations; To prevent zero constant;
[0140] ⑤ Physical Continuity PC: Deviation between the dynamic change of the penalty bandwidth and the dynamic response of the physical hydrological model
[0141] (11)
[0142] in: This is the amplitude scaling constant;
[0143] ⑥ Physical Spatial Consistency (PSI): The bandwidth ratio of different spatial points within the target watershed must conform to the magnitude ratio of hydrological forecast data predicted by the physical hydrological model.
[0144] (12)
[0145] in: and They are spatial points Uncertainty bandwidth upper limit and uncertainty bandwidth lower limit; spatial point For different from spatial points Spatial points; For spatial points Hydrological forecast data;
[0146] By linearly weighting the aforementioned bandwidth performance evaluation metrics using fixed hyperparameters, the generator main network is constructed. Physically guided weighted multi-objective main loss function :
[0147] (13)
[0148] in: These are the fixed hyperparameters for the corresponding bandwidth performance evaluation indicators.
[0149] Step S3, Physical consistency adversarial constraint based on Siamese temporal convolution: Design a temporal convolutional network (TCN) with a weight-sharing dual-branch structure as an adversarial discriminator. Forced generator main network The output trajectory with upper and lower bounds of uncertainty bandwidth exhibits the true fluctuation characteristics of physical hydrological errors.
[0150] As one implementation method, the adversarial discriminator Physical consistency adversarial constraint loss function The construction method is as follows:
[0151] ① Calculate the true absolute physical residual sequence of the physical hydrological model in the current training batch. ; In order to be in time step The true absolute physical residual, ;
[0152] ② Extract the generator main network The generated bandwidth sequence ; In order to be in time step bandwidth, , Uncertainty bandwidth limit for all spatial points in the target watershed The combined data ; Lower bound of uncertainty bandwidth for all spatial points in the target watershed The combined data ;
[0153] ③ and Input adversarial discriminator The two branches with shared weights are used to construct the physical consistency adversarial constraint loss function. :
[0154] (14)
[0155] in: D represents the mathematical expectation (i.e., the average of the logarithmic probabilities of all samples in a training batch); D(·) represents the probability that the adversarial discriminator determines the input sequence to be a true absolute physical residual sequence.
[0156] Step S4, Joint Generator Main Network Physically guided weighted multi-objective main loss function and adversarial discriminator Physical consistency adversarial constraint loss function Define the global total loss function. ;
[0157] Therefore, the global total loss function is defined. , To counteract weight hyperparameters.
[0158] Step S5, based on the global total loss function For the generator main network and adversarial discriminator The constructed deep learning models are jointly trained to obtain the trained generator main network. and adversarial discriminator ;
[0159] As one implementation method, an alternating training mechanism and a composite convergence termination criterion are used for the generator main network. and adversarial discriminator The constructed deep learning models are jointly trained:
[0160] ① Alternating training:
[0161] Fixed Generator Main Network Update the adversarial discriminator The network parameters make Maximize and improve the adversarial discriminator The ability to capture physical temporal characteristics;
[0162] Fixed adversarial discriminator The generator main network is updated using the Adam optimization algorithm. The parameters (i.e., the LSTM network parameters) are used to minimize the global total loss function. This ensures that the generated bandwidth closely approximates the real physical characteristics and meets various bandwidth performance evaluation indicators such as coverage.
[0163] ② Composite convergence termination criterion: During the training process, various bandwidth performance evaluation indicators are monitored through an independent validation set;
[0164] The alternating iteration process terminates and the current network parameters are saved as the final business model when any of the following stopping conditions are met:
[0165] Early stopping condition for physical performance: Within P consecutive iterations, the generator main network... Main loss function on the validation set The relative decline rate is below a small threshold, such as 10. -4 And the coverage ratio (CR) reaches the preset target value, such as above 85%;
[0166] Adversarial equilibrium condition: Adversarial discriminator For true absolute physical residuals With bandwidth The mean output of the discrimination probability consistently oscillates between 0.5 ± 0.05, indicating that the adversarial discriminator... Unable to distinguish between genuine and fake, and the generator's main network It cannot be reduced further under these conditions. ;
[0167] Maximum iteration fallback condition: The total number of alternating training rounds reaches a preset upper limit threshold N. max For example, after 2000 rounds, the network parameters of the round with the best overall performance on the validation set are forcibly stopped and backtracked.
[0168] Step S6, Predictive Extrapolation of Uncertain Bandwidth and Application in Business Decision Making:
[0169] During the operational hydrological forecasting stage, the adversarial discriminator is unloaded. Only the physical hydrological model, the spatiotemporal dynamic environmental factor model, and the trained generator main network are retained. A hydrological forecast uncertainty model is constructed. When future meteorological forecast data is input, the hydrological forecast uncertainty model automatically performs physical forward simulation and gating adaptive parameter mapping of changing environmental factors. Finally, it directly forward propagates and outputs the upper and lower limits of the uncertainty bandwidth of the hydrological forecast at each future time step, which have high physical interpretability and high rigor.
[0170] The present invention also provides a hydrological uncertainty analysis system coupled with deep learning under changing environments, for implementing the aforementioned hydrological uncertainty analysis method coupled with deep learning under changing environments.
[0171] As an example, a hydrological uncertainty analysis system coupled with deep learning under changing environments may include:
[0172] (1) Data acquisition module, used to collect meteorological data (such as precipitation, temperature, etc.), geographic information (such as topography, soil type, etc.), hydrological observation data (such as flow rate, water level, etc.) and changing environmental factors;
[0173] (2) Physical mechanism hydrological model, or physical hydrological model for short, is used to generate preliminary hydrological forecast data;
[0174] (3) Deep learning models, including generator main network and adversarial discriminator It receives hydrological forecast data, meteorological driving data, and changing environmental factors from a physical hydrological model, and after training and prediction, outputs the upper and lower limits of the uncertainty bandwidth of the hydrological forecast.
[0175] (4) Uncertainty analysis module, which is used to analyze the uncertainty of hydrological forecast results based on the uncertainty bandwidth output by the deep learning model, and to assess the reliability and risk of the forecast.
[0176] (5) Decision support module, which provides decision support for water resources management and flood control and disaster reduction based on the results of uncertainty analysis; the decision support module can formulate flood control strategies during the flood season and water resources allocation schemes during the dry season based on the upper and lower limits of the uncertainty bandwidth.
[0177] (6) System integration and optimization module, which integrates the functions of each module, realizes automatic transmission and processing of data streams, and optimizes model parameters and system performance based on actual application feedback, so as to improve the accuracy and efficiency of hydrological uncertainty analysis.
[0178] Through the above methods and systems, this invention introduces physical guidance characteristics into the loss function of deep learning models, enabling them to better adapt to changing environments, reduce the uncertainty of hydrological model forecasts, and provide more reliable and accurate uncertainty analysis results for hydrological forecasts. It has significant practical application value and innovation.
[0179] The following is an example:
[0180] This embodiment applies the present invention to the analysis of runoff uncertainty at a hydrological station in the Yangtze River Basin. This basin is influenced by the monsoon climate, resulting in significant interannual variations in precipitation. Furthermore, in recent years, it has been affected by both climate change and human activities (such as reservoir construction and agricultural irrigation), leading to complex and variable hydrological processes. Traditional hydrological models struggle to accurately predict runoff and its uncertainties.
[0181] This embodiment specifically includes the following steps:
[0182] (1) Data preparation
[0183] Meteorological data (including daily precipitation, temperature, humidity, wind speed, etc.), geographic information (such as topography, soil type, land use type, etc.), and hydrological observation data (such as daily runoff, water level, etc.) for the past 20 years were collected from the station and its surrounding areas in the Yangtze River Basin. Simultaneously, data reflecting environmental changes were collected, such as climate change indicators (regional precipitation and temperature trends simulated by global climate models) and indicators of human activity intensity (reservoir operation records, irrigation water consumption, urbanization rate, etc.).
[0184] (2) Construction of physical mechanism hydrological model
[0185] The SWAT (Soil and Water Assessment Tool) physical mechanism hydrological model, suitable for the Yangtze River Basin, along with other suitable conceptual models such as the Xin'anjiang model and HYMOD, were selected and coupled in parallel to obtain the physical-hydrological model for the basin. Based on the basin's geographical information and meteorological data, the model's parameters were calibrated and validated to simulate the basin's daily runoff process. The model input is daily meteorological data, and the output is the simulated daily runoff at the basin outlet.
[0186] (3) Construction of the vector of changing environmental factors
[0187] The vector of changing environmental factors includes the rate of change in precipitation dynamics. Temperature dynamic change rate Reservoir dynamic regulation coefficient and the dynamic water use ratio for agricultural irrigation .
[0188] (4) Deep learning model construction and training
[0189] Build a generator main network and adversarial discriminator Deep learning models.
[0190] The collected historical data was divided into a training set (the first 15 years) and a test set (the last 5 years). The deep learning model was trained using the training set data, and the model parameters were adjusted by minimizing the loss function through an optimization algorithm (such as the Adam optimization algorithm). During training, the model's performance on the validation set was validated every 10 epochs to prevent overfitting.
[0191] (5) Uncertainty analysis and forecast results
[0192] Run the trained deep learning model on the test set to obtain the upper and lower bounds of the uncertainty bandwidth U(t) for daily runoff forecasts. Calculate the following metrics to evaluate the model performance:
[0193] Average bandwidth (MBW): The average uncertain bandwidth over all days during the test period, resulting in 5.2m. 3 / s, which is 30% lower than traditional methods (such as those based on statistical distributions).
[0194] Coverage (CR): The proportion of days in which the observed runoff falls within the uncertainty bandwidth, reaching 82%, higher than the 70% of the traditional method.
[0195] The coefficient of determination (CCE) is 0.85, which is better than the 0.75 of the traditional method, indicating that the uncertainty bandwidth matches the observations better.
[0196] Discrete environment sensitivity ES: The value is 0.68, indicating that the model is highly sensitive to changing environmental factors and can adapt well to environmental changes.
[0197] (6) Decision support applications
[0198] Based on the runoff uncertainty analysis results obtained by this invention, the following decision support is provided for water resource management in this region of the Yangtze River Basin:
[0199] During the flood season, when the uncertainty bandwidth is wide and the upper limit is high, downstream areas should be notified in advance to prepare for flood control and reservoirs should be pre-emptively released to make room for flood control.
[0200] During the dry season, based on the lower limit of the uncertainty bandwidth, assess the risk of water shortage, formulate precise irrigation plans and urban water supply schemes, and ensure the water needs of residents and agricultural production.
[0201] (7) System integration and optimization
[0202] The various modules of this invention (data acquisition, physical mechanism model, deep learning model, uncertainty analysis, decision support, etc.) are integrated into a unified software platform. In practical applications, the parameters of the deep learning model are regularly updated and optimized based on new hydrological observation data and changing environmental factor data each year, continuously improving the accuracy and reliability of uncertainty analysis.
[0203] As can be seen from this embodiment, the present invention can effectively reduce the uncertainty of hydrological model forecasts, adapt to changing environments, improve model performance, and provide a scientific basis for water resources management in practical applications, and has significant application value and promotion prospects.
[0204] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A hydrological uncertainty analysis method coupled with deep learning under changing environments, characterized in that, include: Step S1: Construct a physical hydrological model and a spatiotemporal dynamic environmental factor model. Analyze the historical hydrological and meteorological datasets of the target watershed over many years. Through spatiotemporal matching and feature fusion, construct a multi-model feature dataset. In each training batch, a time step of length of is selected from the multi-modal feature dataset. Furthermore, the multi-modal feature data sequence is arranged in time sequence, where time steps Multimodal feature data , , For multi-mode state data, For hydrological observation data, For meteorological driving data, The physical hydrological model is driven by meteorological data. As input, hydrological forecast data obtained based on physical mechanisms. The data of changing environmental factors generated using the aforementioned spatiotemporal dynamic environmental factor model; Step S2: Construct the generator main network based on the time-series deep learning model. The generator main network Using multi-mode state data sequences as input, the evolution trend of hydrological forecast data sequences is extracted through linear mapping, generating high-dimensional hidden state data sequences containing hydrophysical and environmental context information. The first branch of the output layer outputs a hydrological forecast trend feature sequence. Simultaneously, a causal relationship analysis is performed on the uncertainty of hydrological forecast data sequences caused by changing environmental factors at each time step. The uncertainty of hydrological forecast data caused by changes in environmental factors is adaptively quantified into a preliminary half-bandwidth thickness, and the Softplus activation function is forcibly applied to obtain the half-bandwidth thickness. Then, taking the hydrological forecast trend characteristics as the center, the upper and lower bounds of the uncertainty bandwidth, representing the uncertainty of the hydrological forecast, are symmetrically generated at the half-bandwidth thickness positions above and below them. At each time step, generate the upper limit trajectory of uncertain bandwidth and the lower limit trajectory of uncertain bandwidth; Step S3: Design a temporal convolutional network with a weight-sharing dual-branch structure as an adversarial discriminator. Forced generator main network The output trajectory with upper and lower bounds of uncertainty bandwidth exhibits the true fluctuation characteristics of physical hydrological errors. Step S4, Joint Generator Main Network Physically guided weighted multi-objective main loss function and adversarial discriminator Physical consistency adversarial constraint loss function Define the global total loss function. ; Step S5, based on the global total loss function For the generator main network and adversarial discriminator The constructed deep learning models are jointly trained to obtain the trained generator main network. and adversarial discriminator ; Step S6, in the hydrological forecasting stage, the physical hydrological model, the spatiotemporally dynamic environmental factor model, and the trained generator main network are used. A hydrological forecast uncertainty model is constructed. Future meteorological forecast data is input, and the hydrological forecast uncertainty model performs physical forward simulation and gating adaptive parameter mapping of changing environmental factors, and outputs the upper and lower limits of the uncertainty bandwidth of hydrological forecasts at each future time step.
2. The hydrological uncertainty analysis method coupled with deep learning under changing environments as described in claim 1, characterized in that, The physical hydrological model is a parallel coupled model that includes multiple conceptual models; the conceptual models include the SWAT model, the Xin'anjiang model, and the HYMOD model.
3. The hydrological uncertainty analysis method coupled with deep learning under changing environments as described in claim 1, characterized in that, Within the target watershed, there are The hydrological observation data at each spatial point For each spatial point within the target watershed Hydrological observation data The resulting vector is characterized as , , Transform the matrix to its rank; similarly, for hydrological forecast data... ; For spatial points Hydrological forecast data; data on changing environmental factors For the target watershed as a whole in time step Changes in environmental factors, for each spatial point The uncertainty of hydrological forecasts has an impact.
4. The hydrological uncertainty analysis method coupled with deep learning under changing environments as described in claim 3, characterized in that, The physical hydrological model uses meteorological driving data. As input, hydrological forecast data are obtained based on physical mechanisms. ,include: At each spatial point in the target watershed The physical hydrological model adopts the overall target watershed at time step Meteorological driving data Based on pre-calibrated fixed physical parameters At the corresponding spatial point Perform hydrophysical runoff generation and confluence simulation, and output spatial points. In time step Hydrological forecast data The formula is represented as ; Describe spatial points The hydrophysical runoff generation and confluence simulation process; wherein, the hydrological forecast data includes one or both of the runoff forecast data and water level forecast data at the outlet of the target basin; the meteorological driving data This consists of multidimensional meteorological data, including rainfall and temperature data; Hydrological forecast data for all spatial points in the target watershed Combined into the target watershed at time step Hydrological forecast data .
5. The hydrological uncertainty analysis method coupled with deep learning under changing environments as described in claim 1, characterized in that, The changed environmental factor data Including the dynamic change rate of precipitation Temperature dynamic change rate Reservoir dynamic regulation coefficient and the dynamic water use ratio for agricultural irrigation Characterized as The spatiotemporal dynamic environmental factor model generates the changing environmental factor data. The method is as follows: ① Using formula (1), the dynamic change rate of precipitation is generated. : (1) Among them: W s The time-series sliding window length; For time step Rainfall at that time ; This represents the multi-year average precipitation; using this time-series sliding window algorithm, short-term data are obtained in conjunction with hydrological forecast data. Scale matching, simultaneously characterizing recent long-term precipitation feature changes ; ②Use formula (2) to generate the dynamic temperature change rate. : (2) in: For time step The average temperature at that time; The average temperature over many years; ③ Using formula (3), the dynamic regulation coefficient of the reservoir is generated. : (3) Where: N res V represents the total number of reservoirs within the target basin; i (t) and V i,max These are the real-time water storage and total storage capacity of the i-th reservoir, i=1~N. res Q i,out (t) and Q i,in (t) represents the real-time outflow and inflow, respectively; k1 and k2 are fixed weights; To prevent zero constant; ④ Using formula (4), the dynamic water use ratio for agricultural irrigation is generated. : (4) in: This is for real-time agricultural irrigation water usage. This represents the total runoff of the basin.
6. The hydrological uncertainty analysis method coupled with deep learning under changing environments according to claim 1, characterized in that, The generator main network At each time step The method for symmetrically generating the upper and lower bounds of the uncertainty bandwidth to characterize the uncertainty of hydrological forecasts is as follows: At each time step spatial point , , The number of spatial points within the target watershed will be used to determine the change ring. The degree of uncertainty in hydrological forecast data caused by environmental factors is adaptively quantified into the initial half-bandwidth thickness. The half-bandwidth thickness is obtained using the Softplus activation function. : ; Using formulas (5) and (6), spatial points are generated. Uncertainty bandwidth limit and uncertainty bandwidth lower limit : (5) (6) in: The hydrological forecast trend characteristics are output by the first branch of the output layer.
7. The hydrological uncertainty analysis method coupled with deep learning under changing environments as described in claim 6, characterized in that, The generator main network Physically guided weighted multi-objective main loss function The construction method is as follows: The following six bandwidth performance evaluation metrics are defined: ① Average bandwidth (MBW): measures the sharpness of a bandwidth range with uncertainty. (7) ② Coverage Rate (CR): Measures the reliability of hydrological observation data falling within the uncertainty bandwidth. (8) in: This is an indicator function; it takes the value 1 if the condition is true, and 0 otherwise. Spatial points of the target watershed In time step Hydrological observation data; ③ Coefficient of Determinism (CCE): Measures the accuracy of the fit between the median bandwidth of the uncertainty bandwidth and the hydrological observation data. (9) in: For spatial points In the current training batch The average of hydrological observation data over a step; ④ Discrete Environment Sensitivity (ES): The first-order finite difference is used to measure the bandwidth's response capability to sudden environmental changes. (10) in: It is an L2 norm; This represents the time difference operation between adjacent time steps; , Indicates time step Changes in environmental factor data With time Changes in environmental factor data Time difference operations; To prevent zero constant; ⑤ Physical Continuity PC: Deviation between the dynamic change of the penalty bandwidth and the dynamic response of the physical hydrological model (11) in: This is the amplitude scaling constant; ⑥ Physical Spatial Consistency (PSI): The bandwidth ratio of different spatial points within the target watershed must conform to the magnitude ratio of hydrological forecast data predicted by the physical hydrological model. (12) in: and They are spatial points Uncertainty bandwidth upper limit and uncertainty bandwidth lower limit; spatial point For different from spatial points Spatial points; For spatial points Hydrological forecast data; By linearly weighting the aforementioned bandwidth performance evaluation metrics using fixed hyperparameters, the generator main network is constructed. Physically guided weighted multi-objective main loss function : (13) in: These are the fixed hyperparameters for the corresponding bandwidth performance evaluation indicators.
8. The hydrological uncertainty analysis method coupled with deep learning under changing environments according to claim 7, characterized in that, The adversarial discriminator Physical consistency adversarial constraint loss function The construction method is as follows: ① Calculate the true absolute physical residual sequence of the physical hydrological model in the current training batch. ; In order to be in time step The true absolute physical residual, ; ② Extract the generator main network The generated bandwidth sequence ; In order to be in time step bandwidth, , Uncertainty bandwidth limit for all spatial points in the target watershed The combined data ; Lower bound of uncertainty bandwidth for all spatial points in the target watershed The combined data ; ③ and Input adversarial discriminator The two branches with shared weights are used to construct the physical consistency adversarial constraint loss function. : (14) in: represents the mathematical expectation; D(·) represents the probability that the adversarial discriminator determines the input sequence to be a true absolute physical residual sequence.
9. The hydrological uncertainty analysis method coupled with deep learning under changing environments according to claim 7, characterized in that, Define the global total loss function , To combat weight hyperparameters, step S5 employs an alternating training mechanism and a composite convergence termination criterion to train the generator main network. and adversarial discriminator The constructed deep learning models are jointly trained: ① Alternating training: Fixed Generator Main Network Update the adversarial discriminator The network parameters make Maximize and improve the adversarial discriminator The ability to capture physical temporal characteristics; Fixed adversarial discriminator The generator main network is updated using the Adam optimization algorithm. The parameters minimize the global total loss function. This ensures that the generated bandwidth closely approximates the real physical characteristics and meets various bandwidth performance evaluation indicators. ② Composite convergence termination criterion: During the training process, various bandwidth performance evaluation indicators are monitored through an independent validation set; The alternating iteration process terminates and the current network parameters are saved as the final business model when any of the following stopping conditions are met: Early stopping condition for physical performance: Within P consecutive iterations, the generator main network... Main loss function on the validation set The relative decline rate is below the minimum threshold, and the coverage ratio (CR) reaches the preset target value; Adversarial equilibrium condition: Adversarial discriminator For true absolute physical residuals With bandwidth The mean output of the discrimination probability consistently oscillates between 0.5 ± 0.05, indicating that the adversarial discriminator... Unable to distinguish between genuine and fake, and the generator's main network It cannot be reduced further under these conditions. ; Maximum iteration fallback condition: The total number of alternating training rounds reaches a preset upper limit threshold N. max Force a stop and backtrack to select the network parameters for the round with the best overall performance on the validation set.
10. A hydrological uncertainty analysis system coupled with deep learning under changing environments, characterized in that, This method is used to implement the hydrological uncertainty analysis method coupled with deep learning under changing environments as described in any one of claims 1-9.