River water level dynamic monitoring and flood overflow risk prediction method based on deep learning
By constructing a water level prediction model based on a bidirectional long-short-term memory network and attention mechanism based on multi-source hydrological data, combined with dynamic risk threshold judgment and edge warning linkage, the problems of data update delay and low model prediction accuracy in the existing water level monitoring system are solved, and high-precision, adaptive and intelligent monitoring and early warning of river water levels are achieved.
Patent Information
- Application Number
- CN202510825361.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-09-26
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing water level monitoring system has data update delays, low model prediction accuracy, and is unable to adapt to complex geographical and meteorological changes, resulting in delayed response to sudden water level changes, insufficient timeliness and accuracy of early warning signals, insufficient multi-source data integration capabilities, and a single dynamic risk judgment logic, making it difficult to support high-frequency predictions and intelligent responses for modern water conservancy projects.
A water level prediction model is constructed using a bidirectional long short-term memory network and attention mechanism based on multi-source hydrological data. Combined with dynamic risk threshold judgment and edge warning linkage mechanism, intelligent monitoring of river water levels and flood risk prediction are achieved.
It has improved the accuracy and response capability of water level prediction, enhanced the ability to identify flood risks, achieved local rapid response and remote collaboration, and significantly improved the intelligence level and early warning reliability of the monitoring system.
Smart Images

Figure CN120706644A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of hydrological monitoring and disaster warning, and in particular to a method for dynamic monitoring of river water levels and prediction of flood risks based on deep learning. Background Art
[0002] With climate change and the frequent occurrence of extreme weather events, floods pose a serious threat to infrastructure safety, social production, and the lives and property of residents in riverside areas. Real-time monitoring of river water levels and early warning of flood risks have become key links in disaster prevention and mitigation systems. Traditional water level monitoring systems rely on single-point sensing devices and centralized data collection architectures, collecting and uploading hydrological information such as water level and flow at a fixed frequency. These systems then use water conservancy scheduling experience or statistical regression models to determine whether flood risks exist. However, these methods are limited by factors such as data update delays, low model prediction accuracy, and an inability to automatically adapt to complex geographical and meteorological changes. This results in delayed responses to sudden water level changes and a serious lack of timeliness and accuracy in warning signals.
[0003] Among existing water level prediction technologies, physical mechanism models and empirical regression models are widely used. Although physical models can reflect hydrodynamic processes, they have numerous parameters, are complex to construct, are highly dependent on data quality and boundary conditions, and are difficult to adjust in real time to respond to complex environmental disturbances. Empirical models establish prediction functions based on linear or nonlinear statistical relationships. Although simple to implement and computationally inexpensive, they are limited in their ability to handle hydrological time series with non-stationary, multivariate, and significant nonlinear characteristics, and are prone to large errors, especially under extreme climatic conditions. In addition, existing systems generally have problems such as insufficient ability to integrate multi-source data, single dynamic risk judgment logic, and weak edge deployment capabilities, making it difficult to support the needs of modern water conservancy projects for high-frequency prediction, wide-area linkage, and intelligent response.
[0004] Given these challenges, deep learning technology, with its outstanding capabilities in time series modeling, automatic feature extraction, and nonlinear pattern recognition, has become a potential solution to the inadequate accuracy and robustness of water level forecasting. However, most existing research remains at the theoretical or small-scale experimental stage, lacking mature methods for integrating deep learning with practical hydrological monitoring systems. In particular, there is a lack of systematic technical approaches for multi-source heterogeneous data processing, model structure design, dynamic risk threshold identification, field deployment, and coordinated response.
[0005] In response to the above-mentioned problems in the existing technology, the present invention proposes a water level prediction model framework based on multi-source hydrological data input, constructed with a bidirectional long short-term memory network and an attention mechanism, and integrates dynamic risk threshold judgment and edge warning linkage mechanism to construct a full-process, scrollable and adaptive flood risk prediction method, aiming to improve the intelligence level of river water level monitoring and the foresight and reliability of emergency response.
[0006] Therefore, how to provide a method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning is an urgent problem that technicians in this field need to solve. Summary of the Invention
[0007] One purpose of the present invention is to propose a method for dynamic monitoring of river water levels and prediction of flood risks based on deep learning. The present invention integrates multi-source hydrological data with a deep learning prediction model, adopts a bidirectional long-short-term memory network and an attention mechanism to improve the accuracy of water level prediction, combines a dynamic threshold judgment method to enhance the ability to identify flood risks, and realizes local rapid response and remote collaboration through edge deployment and standard communication interfaces, significantly improving the intelligence level of the monitoring system and the reliability of early warning.
[0008] A method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to an embodiment of the present invention includes the following steps:
[0009] S1. Deploy water level gauges, rain gauges, current meters, remote sensing monitoring devices, and edge data collection terminals along the river. These data, including river water level, rainfall, flow velocity, evaporation, upstream water flow, reservoir capacity scheduling instructions, and underlying surface topography, are collected synchronously at fixed time intervals. All data are then labeled with time and spatial coordinates to construct an original time series dataset.
[0010] S2. Perform data cleaning and formatting on the original dataset, specifically including performing spline interpolation to fill missing values in the collected data, removing outliers using the median outlier detection method, performing minimum and maximum normalization on each feature, and organizing the data structure into a time series tensor with equal time intervals and fixed dimensions to construct a unified input format for the neural network input;
[0011] S3. Construct a water level prediction model based on a multi-layer bidirectional long short-term memory network and an attention mechanism fusion, the model including an input layer, a first layer of bidirectional long short-term memory network, a second layer of deeply stacked bidirectional long short-term memory network, a cross-scale attention feature enhancement module, a multi-head attention mechanism fusion layer, a high-dimensional fully connected mapping module, an output layer, and a prediction result encapsulation and interface output module;
[0012] S4. Input the standardized time series data obtained in step S2 into the water level prediction model, perform a forward reasoning process, and output a predicted water level sequence for multiple time steps in the future as a trend estimation result of river water level changes in the future period of time;
[0013] S5. Set multi-level dynamic risk thresholds based on historical hydrological extreme value data, seasonal scheduling strategies, and site levels. Compare the predicted water level sequence with the risk threshold corresponding to the current cycle at each time point. Combined with the real-time rainfall intensity level, upstream inflow increment, gate opening status, and river channel flux margin, use segmented logic rules to determine whether there is a threshold-crossing risk or a trend-based flooding risk.
[0014] S6. If there is a risk of flooding, a risk prediction label is generated, including the risk level, expected threshold-crossing start time, peak water level time, spatial positioning information, and warning confidence. The label information is cached in the local warning queue and remote warning linkage system. If there is no risk, the difference between the predicted result and the actual sampling value is recorded as a calibration factor for subsequent model accuracy adjustment, and the next round of data collection is started.
[0015] S7. Output the water level prediction sequence and risk warning labels to an external dispatching and commanding system or visualization platform through a communication interface. The interface supports data transmission protocols such as HTTP, MQTT, and WebSocket, and has a unified data packet structure and multi-platform compatibility to support docking with a graphic display module, a dispatching center terminal, or an intelligent edge node device.
[0016] S8. Update the input data in a rolling manner according to the set prediction cycle, and repeat steps S2 to S7 to achieve continuous dynamic monitoring of the river water level status and real-time intelligent prediction of flood overflow risks.
[0017] Optionally, the S2 specifically includes:
[0018] S21. Time alignment is performed on the collected original multi-source hydrological data. All feature data are synchronously resampled at fixed time intervals to ensure the consistency of various features in the time dimension.
[0019] S22. Perform missing value processing on the resampled data, use sliding window interpolation to fill in incomplete time series segments, and construct a time-continuous hydrological data chain;
[0020] S23. Detect and eliminate outliers in various sampled data, use outlier detection rules based on historical statistics to mark measurement data that deviate from the range, and replace them with the smoothed mean of the previous and next moments;
[0021] S24. Perform normalization processing on the cleaned data to map hydrological characteristics of different physical magnitudes and units to a unified scale interval to eliminate the impact of dimensional differences on subsequent modeling training;
[0022] S25, performing encoding conversion on terrain-related data, expanding static terrain parameters including geographic coordinates, altitude, and underlying surface type into auxiliary feature columns consistent with the hydrological data structure, and combining them to form a unified input structure;
[0023] S26. Arrange the above preprocessing results in chronological order into time series samples in the form of fixed-length sliding windows, ensuring that each sample segment contains complete and continuous historical observation information as the input unit of the subsequent deep learning model.
[0024] Optionally, the water level prediction model includes an input layer, a first-layer bidirectional long short-term memory network, a second-layer deeply stacked bidirectional long short-term memory network, a cross-scale attention feature enhancement module, a multi-head attention mechanism fusion layer, a high-dimensional fully connected mapping module, an output layer, and a prediction result encapsulation and interface output module:
[0025] The input layer receives standardized sliding window format time series samples, which include a fixed time step length and a feature dimension structure. The time step dimension consists of historical continuous sampling moments, and the feature dimension includes river water level, accumulated rainfall, flow rate, evaporation, gate opening status, reservoir capacity surplus ratio, terrain slope factor, and tributary inflow hydrological and physical variables;
[0026] The first-layer bidirectional long-short-term memory network consists of a set of forward and reverse LSTM units, encoding and learning the input sequence in forward and reverse time order, respectively. Each LSTM unit contains an input gate, a forget gate, and an output gate to control the selective memory and discarding of the state vector. This layer captures the dynamic response relationship between upstream and downstream water level changes within a short time frame and improves the modeling ability of downstream feedback and lagged changes through a time-reversal structure. The final output is the concatenation of the bidirectional hidden states at each time step.
[0027] The second layer is a deeply stacked bidirectional long short-term memory network. This layer performs contextual fusion learning across time windows based on the bidirectional hidden state output of the first layer, enhancing the model's ability to identify medium-term trends and potential fluctuation structures. The output of each time step is connected to a layer normalization module to alleviate gradient explosion and decay issues. A residual shortcut connects the hidden states of the previous and next layers, effectively maintaining the stability of information flow and feature depth expansion.
[0028] The cross-scale attention feature enhancement module calculates the short-term attention in the local time window and the long-term attention at the global sequence level for the bidirectional output sequence, and fuses the weights of the two types of attention in a proportional weighted manner. The position encoding mechanism is introduced to enhance the temporal position perception capability;
[0029] The multi-head attention mechanism fusion layer divides the weighted context features output from S34 into multiple independent subspaces and establishes multi-head attention subnetworks in parallel. Each subnetwork is responsible for learning the interaction between a set of feature substructures. By splicing the results of multiple attention heads and introducing a linear transformation layer to complete the unified context embedding, a multi-scale feature fusion expression is obtained.
[0030] The high-dimensional fully connected mapping module consists of two fully connected sub-layers connected in series, with batch normalization and activation functions inserted in between to improve the model's nonlinear expression capabilities and training stability. The input is the fused context features, and the output is a fixed-length prediction vector corresponding to the water level value at each time point in the prediction window.
[0031] The output layer outputs a one-dimensional time series vector, with each element corresponding to the water level forecast for a specific future time step. The output layer has configurable time step interval control and prediction step size parameters. The output sequence comes with an optional confidence interval evaluation module.
[0032] The prediction result encapsulation and interface output module packages the prediction results together with the prediction start time, input data summary, model version, and run batch number metadata into a structured data format, and selects HTTP, MQTT, or WebSocket communication protocols according to the calling environment, and sends them to the upper-level visualization platform, scheduling system, or edge warning terminal through the API gateway.
[0033] Optionally, the S4 specifically includes:
[0034] S41. Input the standardized time series samples constructed by the time sliding window into the input layer of the water level prediction model in sequence, ensuring that the input data meets the time step length and feature dimension requirements set in the model structure;
[0035] S42. Send the data received by the input layer to the first-layer bidirectional long short-term memory network, calculate the forward hidden state sequence and the reverse hidden state sequence of the time series in the forward and reverse directions respectively, and splice them into the time series feature output of the first stage;
[0036] S43, passing the first-stage temporal feature output to the second-layer bidirectional long short-term memory network to further extract deep dynamic features across the time window, and outputting the second-stage hidden state sequence as a complete temporal expression result;
[0037] S44. Input the second-stage hidden state sequence into the attention mechanism module, assign weights to the hidden states of all time steps, extract the time series feature segments with key predictive significance, and generate a fused context vector;
[0038] S45, passing the fused context vector to the fully connected mapping layer, setting the number and order of output units according to the required prediction time length, and mapping the time features into water level prediction results for multiple future time steps;
[0039] S46. Output the water level prediction results to the downstream risk judgment module and save them in the local prediction cache for subsequent error analysis and model update with actual observation data.
[0040] Optionally, the S5 specifically includes:
[0041] S51, extracting the predicted values of multiple consecutive time steps from the water level prediction results, and matching them one-to-one with the overflow risk thresholds of the corresponding time periods within the set period to form a time series comparison data set;
[0042] S52. Based on historical observation data, regional scheduling rules, seasonal hydrological patterns, and flood characteristics over the years, multiple levels of risk threshold segments are set, wherein the risk threshold segments include warning water levels, guaranteed water levels, and extremely high warning water levels;
[0043] S53, classifying the predicted water level value at each time step according to its interval position in the set risk threshold segment, and marking the corresponding risk level label, wherein the risk level label includes five risk states: safe, warning, alert, serious and extreme;
[0044] S54. Construct an auxiliary condition set for risk assessment by combining dynamic hydrological input information such as cumulative rainfall during the forecast period, discharge from upstream reservoirs, gate scheduling plans, and tributary inflow fluctuations;
[0045] S55: Based on the predicted water level and the auxiliary condition set, a logical rule set is used to determine whether there is a continuous upward trend, a trend exceeding a critical threshold, or an extreme risk emergency event, and output a risk determination result;
[0046] S56. When it is determined that there is a risk of flooding, the time of the first threshold exceeding, the time of the peak water level and the risk level are recorded to form a structured risk prediction label and submitted to the early warning processing process; if it is determined that there is no risk, the current status mark is updated and the data processing task of the next prediction cycle is continued.
[0047] Optionally, the S6 specifically includes:
[0048] S61. If the risk determination result indicates that there is a risk of flooding, generate a structured risk warning label, the label including the risk level, prediction start time, expected threshold exceeding time, maximum water level time, peak water level value, site number, geographic coordinates, and prediction confidence score;
[0049] S62: Writing the structured risk warning tag into a local warning buffer queue. The buffer queue has timestamp sorting and tag version tracking functions, and is used to record and manage multiple rounds of prediction results and their evolution process.
[0050] S63. Call the local linkage rule in the edge node device and determine whether to trigger the local buzzer alarm, LCD display module or SMS push module based on the risk level field contained in the tag;
[0051] S64. Send the structured risk warning label in the form of a data packet to the remote warning linkage system. The data packet includes the label content, model version identifier, reasoning time identifier, and site data summary to support the comprehensive risk assessment of the superior dispatch command center.
[0052] S65. Under the condition that there is no flood risk, the prediction results of the current cycle are compared with the latest measured values for error analysis, and the deviation of the results is calculated as a feedback basis for subsequent model parameter updates or optimizations;
[0053] S66. Under risk-free conditions, the prediction results and comparison error information are recorded in the local status log, and the warning label information in the previous round cache is cleared to keep the system in a risk-free monitoring state.
[0054] Optionally, the S7 specifically includes:
[0055] S71. Configure a communication interface module. The module supports three communication modes: HTTP, WebSocket, and MQTT. It has data compression, packet transmission, and breakpoint resuming functions, and is used to achieve remote transmission of model prediction results and risk information.
[0056] S72. Encapsulate the water level prediction result and the structured risk warning label into a standardized data package, wherein the data package includes a unique site identifier, data generation time, prediction duration, prediction result sequence, risk label content, and a data verification code;
[0057] S73. Sending the data packet to the upper-level scheduling management platform through the communication interface module. After receiving the data, the platform automatically connects to the monitoring visualization interface and displays the risk level information in the river section diagram, water level trend chart, and alarm timeline.
[0058] S74. Synchronously sending the data packet to the regional emergency response system for linkage with emergency plan dispatch, pre-disaster personnel transfer planning, and generation of temporary facility deployment suggestions;
[0059] S75. In a deployment scenario with local edge nodes, the prediction results and risk tags are further sent to downstream control terminals, including the sluice control module, the early warning broadcast system, the LED warning screen, and the site management client.
[0060] S76. After completing data upload and push, a communication log is generated for all communication behaviors of the current predicted batch. The log includes data sending time, target interface response status and data integrity verification results, and is stored in the log database for subsequent audit queries.
[0061] Optionally, the S8 specifically includes:
[0062] S81. Set a fixed time period as the model operation scheduling interval. The period length can be set in hours or minutes. The scheduling management module performs global unified control to ensure the synchronous execution of multi-site model prediction.
[0063] S82. Before the start of each cycle, extract the latest observation data of the previous cycle from the data acquisition module, update the standardized time series sample, and construct a sliding window input segment containing the latest data to replace the current input queue of the model;
[0064] S83: Send the updated input data to the prediction model, perform forward reasoning operations, regenerate the water level prediction sequence and risk assessment results for the current cycle, and replace the old output content in the cache of the previous cycle;
[0065] S84. Detect the trend of residual values between the prediction model output and the actual observation value, and record the error offset status within consecutive cycles to dynamically determine whether the model performance has degraded and trigger a model fine-tuning request;
[0066] S85. Continue to use the current model parameters to perform the next round of prediction tasks under the condition that the set error tolerance range is met; if there is a trend of prediction deviation accumulation for multiple consecutive cycles, submit a model update task request to the local or remote training module;
[0067] S86. After executing all the processes of prediction, warning, communication and logging in this cycle, update the scheduling timestamp and re-enter the model reasoning and data processing cycle of the next cycle to achieve continuous dynamic prediction and risk monitoring of river water level status.
[0068] The beneficial effects of the present invention are:
[0069] The present invention achieves high precision, strong robustness and improved adaptability in river water level dynamic monitoring and flood risk prediction scenarios by constructing a deep learning prediction model that integrates a multi-layer bidirectional long short-term memory network and an attention mechanism.
[0070] First, the present invention introduces a multi-source hydrological information collection mechanism at the data processing level, integrating characteristics such as river water level, rainfall, flow rate, evaporation, scheduling instructions and terrain elements to form a unified standard time series input format, significantly improving the model's comprehensive perception ability of complex hydrological scenarios, and effectively solving the limitations of traditional single sensor data-driven models in the information dimension.
[0071] Secondly, the deep learning prediction model constructed by the present invention adopts a two-layer bidirectional long-short-term memory structure. While retaining the long-term dependence characteristics of hydrological data, it improves the timeliness and accuracy of water level prediction through joint modeling of previous and subsequent time series features; combined with the attention mechanism module to further focus on key time segments, the model can dynamically weigh the contribution of different historical moments to the prediction results, thereby enhancing the recognition and response capabilities of abnormal events such as sudden floods and extreme rainfall, and making up for the shortcomings of traditional models in predicting nonlinear fluctuations.
[0072] Furthermore, in the risk identification phase, this invention innovatively introduces a multi-level dynamic threshold judgment mechanism. This combines historical hydrological extremes, seasonal scheduling strategies, and on-site control information to construct a more adaptable risk assessment rule system, effectively improving the accuracy and credibility of early warning judgments. The early warning output includes not only the risk level but also a time tag, geographic coordinates, and confidence level indicators, which can serve as a direct decision-making basis for the dispatch system, enabling intelligent linkage between prediction results and dispatch actions.
[0073] Finally, this invention combines edge computing with standard communication interface design to create a deployment solution that supports rapid local response and visual collaboration with remote platforms, ensuring the system's continuous operation even in communication-constrained or on-site emergencies. Through periodic data updates and model iteration, the system provides rolling prediction, self-correction, and performance maintenance capabilities, comprehensively improving the stability, scalability, and intelligence of river monitoring systems in real-world scenarios, demonstrating significant engineering value and potential for widespread adoption. BRIEF DESCRIPTION OF THE DRAWINGS
[0074] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings:
[0075] Figure 1 This is the overall flow chart of a deep learning-based river water level dynamic monitoring and flood risk prediction method proposed in this invention;
[0076] Figure 2 This is a structural diagram of the water level prediction model based on bidirectional long short-term memory network and attention mechanism proposed in the present invention;
[0077] Figure 3 This is a flow chart of the periodic rolling update mechanism and closed-loop feedback of prediction results proposed by the present invention. DETAILED DESCRIPTION
[0078] The present invention will now be described in further detail with reference to the accompanying drawings, which are simplified schematic diagrams that illustrate the basic structure of the present invention in a schematic manner.
[0079] refer to Figure 1-3 A method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning includes the following steps:
[0080] S1. Deploy water level gauges, rain gauges, current meters, remote sensing monitoring devices, and edge data collection terminals along the river. These data, including river water level, rainfall, flow velocity, evaporation, upstream water flow, reservoir capacity scheduling instructions, and underlying surface topography, are collected synchronously at fixed time intervals. All data are then labeled with time and spatial coordinates to construct an original time series dataset.
[0081] S2. Perform data cleaning and formatting on the original dataset, specifically including performing spline interpolation to fill missing values in the collected data, removing outliers using the median outlier detection method, performing minimum and maximum normalization on each feature, and organizing the data structure into a time series tensor with equal time intervals and fixed dimensions to construct a unified input format for the neural network input;
[0082] S3. Construct a water level prediction model based on a multi-layer bidirectional long short-term memory network and an attention mechanism fusion, the model including an input layer, a first layer of bidirectional long short-term memory network, a second layer of deeply stacked bidirectional long short-term memory network, a cross-scale attention feature enhancement module, a multi-head attention mechanism fusion layer, a high-dimensional fully connected mapping module, an output layer, and a prediction result encapsulation and interface output module;
[0083] S4. Input the standardized time series data obtained in step S2 into the water level prediction model, perform a forward reasoning process, and output a predicted water level sequence for multiple time steps in the future as a trend estimation result of river water level changes in the future period of time;
[0084] S5. Set multi-level dynamic risk thresholds based on historical hydrological extreme value data, seasonal scheduling strategies, and site levels. Compare the predicted water level sequence with the risk threshold corresponding to the current cycle at each time point. Combined with the real-time rainfall intensity level, upstream inflow increment, gate opening status, and river channel flux margin, use segmented logic rules to determine whether there is a threshold-crossing risk or a trend-based flooding risk.
[0085] S6. If there is a risk of flooding, a risk prediction label is generated, including the risk level, expected threshold-crossing start time, peak water level time, spatial positioning information, and warning confidence. The label information is cached in the local warning queue and remote warning linkage system. If there is no risk, the difference between the predicted result and the actual sampling value is recorded as a calibration factor for subsequent model accuracy adjustment, and the next round of data collection is started.
[0086] S7. Output the water level prediction sequence and risk warning labels to an external dispatching and commanding system or visualization platform through a communication interface. The interface supports data transmission protocols such as HTTP, MQTT, and WebSocket, and has a unified data packet structure and multi-platform compatibility to support docking with a graphic display module, a dispatching center terminal, or an intelligent edge node device.
[0087] S8. Update the input data in a rolling manner according to the set prediction cycle, and repeat steps S2 to S7 to achieve continuous dynamic monitoring of the river water level status and real-time intelligent prediction of flood overflow risks.
[0088] By constructing a multi-stage process system consisting of data perception, cleaning processing, in-depth modeling, dynamic assessment, graded early warning, and continuous circulation, this method achieves high-frequency monitoring of river water level evolution and accurate prediction of flood risk for the first time, significantly improving data coverage, model adaptability, and early warning stability in complex hydrological environments. Compared with traditional centralized model prediction solutions, this method possesses end-to-end adaptability at the data processing, model structure, and early warning output layers. It can complete fully automated operations from data collection to output with minimal human intervention, and has excellent scalability, portability, and deployment versatility.
[0089] In this embodiment, S2 specifically includes:
[0090] S21. Time alignment is performed on the collected original multi-source hydrological data. All feature data are synchronously resampled at fixed time intervals to ensure the consistency of various features in the time dimension.
[0091] S22. Perform missing value processing on the resampled data, use sliding window interpolation to fill in incomplete time series segments, and construct a time-continuous hydrological data chain;
[0092] S23. Detect and eliminate outliers in various sampled data, use outlier detection rules based on historical statistics to mark measurement data that deviate from the range, and replace them with the smoothed mean of the previous and next moments;
[0093] S24. Perform normalization processing on the cleaned data to map hydrological characteristics of different physical magnitudes and units to a unified scale interval to eliminate the impact of dimensional differences on subsequent modeling training;
[0094] S25, performing encoding conversion on terrain-related data, expanding static terrain parameters including geographic coordinates, altitude, and underlying surface type into auxiliary feature columns consistent with the hydrological data structure, and combining them to form a unified input structure;
[0095] S26. Arrange the above preprocessing results in chronological order into time series samples in the form of fixed-length sliding windows, ensuring that each sample segment contains complete and continuous historical observation information as the input unit of the subsequent deep learning model.
[0096] By establishing clear data quality assurance mechanisms during the data preprocessing phase, including sampling synchronization, missing data repair, outlier removal, dimensionality unification, and terrain information encoding, the consistency and temporal continuity of the input tensor structure are guaranteed, significantly reducing the risk of abnormal perturbations during model training. This processing not only enhances the data's adaptability to time series models but also establishes a unified modeling foundation for static and dynamic hydrological elements. This facilitates the subsequent network's accurate learning of changing trends, critical point responses, and spatial differences, improving the stability and generalization capabilities of the overall predictive modeling system.
[0097] In this embodiment, the water level prediction model includes an input layer, a first-layer bidirectional long short-term memory network, a second-layer deeply stacked bidirectional long short-term memory network, a cross-scale attention feature enhancement module, a multi-head attention mechanism fusion layer, a high-dimensional fully connected mapping module, an output layer, and a prediction result encapsulation and interface output module:
[0098] The input layer receives standardized sliding window format time series samples, which include a fixed time step length and a feature dimension structure. The time step dimension consists of historical continuous sampling moments, and the feature dimension includes river water level, accumulated rainfall, flow rate, evaporation, gate opening status, reservoir capacity surplus ratio, terrain slope factor, and tributary inflow hydrological and physical variables;
[0099] The first-layer bidirectional long-short-term memory network consists of a set of forward and reverse LSTM units, encoding and learning the input sequence in forward and reverse time order, respectively. Each LSTM unit contains an input gate, a forget gate, and an output gate to control the selective memory and discarding of the state vector. This layer captures the dynamic response relationship between upstream and downstream water level changes within a short time frame and improves the modeling ability of downstream feedback and lagged changes through a time-reversal structure. The final output is the concatenation of the bidirectional hidden states at each time step.
[0100] The second layer is a deeply stacked bidirectional long short-term memory network. This layer performs contextual fusion learning across time windows based on the bidirectional hidden state output of the first layer, enhancing the model's ability to identify medium-term trends and potential fluctuation structures. The output of each time step is connected to a layer normalization module to alleviate gradient explosion and decay issues. A residual shortcut connects the hidden states of the previous and next layers, effectively maintaining the stability of information flow and feature depth expansion.
[0101] The cross-scale attention feature enhancement module calculates the short-term attention in the local time window and the long-term attention at the global sequence level for the bidirectional output sequence, and fuses the weights of the two types of attention in a proportional weighted manner. The position encoding mechanism is introduced to enhance the temporal position perception capability;
[0102] The multi-head attention mechanism fusion layer divides the weighted context features output from S34 into multiple independent subspaces and establishes multi-head attention subnetworks in parallel. Each subnetwork is responsible for learning the interaction between a set of feature substructures. By splicing the results of multiple attention heads and introducing a linear transformation layer to complete the unified context embedding, a multi-scale feature fusion expression is obtained.
[0103] The high-dimensional fully connected mapping module consists of two fully connected sub-layers connected in series, with batch normalization and activation functions inserted in between to improve the model's nonlinear expression capabilities and training stability. The input is the fused context features, and the output is a fixed-length prediction vector corresponding to the water level value at each time point in the prediction window.
[0104] The output layer outputs a one-dimensional time series vector, with each element corresponding to the water level forecast for a specific future time step. The output layer has configurable time step interval control and prediction step size parameters. The output sequence comes with an optional confidence interval evaluation module.
[0105] The prediction result encapsulation and interface output module packages the prediction results together with the prediction start time, input data summary, model version, and run batch number metadata into a structured data format, and selects HTTP, MQTT, or WebSocket communication protocols according to the calling environment, and sends them to the upper-level visualization platform, scheduling system, or edge warning terminal through the API gateway.
[0106] The proposed dual-layer, bidirectional LSTM structure and attention mechanism fusion model has multi-granularity and multi-directional information extraction capabilities, effectively identifying potential cross-period dependency structures in water level data. Bidirectional information fusion solves the problem of unbalanced response of unidirectional LSTM to upstream and downstream temporal features. The superimposed hierarchical structure enhances feature abstraction capabilities, while the attention module further improves the model's prediction sensitivity and positioning accuracy for sudden abnormal hydrological events (such as short-term rainstorms and sudden flood peaks) by focusing on key time points. This ensures the model's deep recognition and response capabilities to abnormal fluctuation trends.
[0107] In this embodiment, the S4 specifically includes:
[0108] S41. Input the standardized time series samples constructed by the time sliding window into the input layer of the water level prediction model in sequence, ensuring that the input data meets the time step length and feature dimension requirements set in the model structure;
[0109] S42. Send the data received by the input layer to the first-layer bidirectional long short-term memory network, calculate the forward hidden state sequence and the reverse hidden state sequence of the time series in the forward and reverse directions respectively, and splice them into the time series feature output of the first stage;
[0110] S43, passing the first-stage temporal feature output to the second-layer bidirectional long short-term memory network to further extract deep dynamic features across the time window, and outputting the second-stage hidden state sequence as a complete temporal expression result;
[0111] S44. Input the second-stage hidden state sequence into the attention mechanism module, assign weights to the hidden states of all time steps, extract the time series feature segments with key predictive significance, and generate a fused context vector;
[0112] S45, passing the fused context vector to the fully connected mapping layer, setting the number and order of output units according to the required prediction time length, and mapping the time features into water level prediction results for multiple future time steps;
[0113] S46. Output the water level prediction results to the downstream risk judgment module and save them in the local prediction cache for subsequent error analysis and model update with actual observation data.
[0114] By meticulously defining each step of the model inference process, from input tensor loading, two-layer state extraction, attention fusion, to prediction value generation and result output, the entire process structure is highly modularized and features closed data flow. This path design supports lightweight configuration and pipeline execution of inference nodes in actual deployment, significantly reducing real-time operation latency and improving the overall system's response frequency. It also possesses excellent structural interpretability and debuggability, making it suitable for stable operation and controllable performance expansion in edge deployment scenarios.
[0115] In this embodiment, the S5 specifically includes:
[0116] S51, extracting the predicted values of multiple consecutive time steps from the water level prediction results, and matching them one-to-one with the overflow risk thresholds of the corresponding time periods within the set period to form a time series comparison data set;
[0117] S52. Based on historical observation data, regional scheduling rules, seasonal hydrological patterns, and flood characteristics over the years, multiple levels of risk threshold segments are set, wherein the risk threshold segments include warning water levels, guaranteed water levels, and extremely high warning water levels;
[0118] S53, classifying the predicted water level value at each time step according to its interval position in the set risk threshold segment, and marking the corresponding risk level label, wherein the risk level label includes five risk states: safe, warning, alert, serious and extreme;
[0119] S54. Construct an auxiliary condition set for risk assessment by combining dynamic hydrological input information such as cumulative rainfall during the forecast period, discharge from upstream reservoirs, gate scheduling plans, and tributary inflow fluctuations;
[0120] S55: Based on the predicted water level and the auxiliary condition set, a logical rule set is used to determine whether there is a continuous upward trend, a trend exceeding a critical threshold, or an extreme risk emergency event, and output a risk determination result;
[0121] S56. When it is determined that there is a risk of flooding, the time of the first threshold exceeding, the time of the peak water level and the risk level are recorded to form a structured risk prediction label and submitted to the early warning processing process; if it is determined that there is no risk, the current status mark is updated and the data processing task of the next prediction cycle is continued.
[0122] A flood risk assessment mechanism based on multi-layer dynamic thresholds was introduced, combining time-varying water level forecast sequences with multi-factor auxiliary information to construct a risk identification logic system that can perceive differences in different hydrological stages, scheduling strategies, and spatial locations. This mechanism significantly overcomes the adaptability of fixed threshold methods to atypical hydrological scenarios, ensuring that early warning results are not only timely but also structurally stable and risk-sensitive. This effectively supports the precise scheduling, scientific deployment, and regional linkage of a multi-level response system based on different risk levels.
[0123] In this embodiment, S6 specifically includes:
[0124] S61. If the risk determination result indicates that there is a risk of flooding, generate a structured risk warning label, the label including the risk level, prediction start time, expected threshold exceeding time, maximum water level time, peak water level value, site number, geographic coordinates, and prediction confidence score;
[0125] S62: Writing the structured risk warning tag into a local warning buffer queue. The buffer queue has timestamp sorting and tag version tracking functions, and is used to record and manage multiple rounds of prediction results and their evolution process.
[0126] S63. Call the local linkage rule in the edge node device and determine whether to trigger the local buzzer alarm, LCD display module or SMS push module based on the risk level field contained in the tag;
[0127] S64. Send the structured risk warning label in the form of a data packet to the remote warning linkage system. The data packet includes the label content, model version identifier, reasoning time identifier, and site data summary to support the comprehensive risk assessment of the superior dispatch command center.
[0128] S65. Under the condition that there is no flood risk, the prediction results of the current cycle are compared with the latest measured values for error analysis, and the deviation of the results is calculated as a feedback basis for subsequent model parameter updates or optimizations;
[0129] S66. Under risk-free conditions, the prediction results and comparison error information are recorded in the local status log, and the warning label information in the previous round cache is cleared to keep the system in a risk-free monitoring state.
[0130] Structured risk labels not only contain risk levels but also carry multi-dimensional information such as time, space, evolutionary trends, and model confidence. Combined with local and remote warning caching mechanisms, they support both rapid local decision-making and remote coordinated scheduling. Combined with label version tracking mechanisms and error feedback calibration channels, they enable closed-loop verification of prediction results, continuous detection of model operational deviations, and self-tuning performance optimization. This enhances the overall system's evolutionary adaptability and intelligent fault tolerance, significantly improving the reliability and foresight of pre-disaster response.
[0131] In this embodiment, the S7 specifically includes:
[0132] S71. Configure a communication interface module. The module supports three communication modes: HTTP, WebSocket, and MQTT. It has data compression, packet transmission, and breakpoint resuming functions, and is used to achieve remote transmission of model prediction results and risk information.
[0133] S72. Encapsulate the water level prediction result and the structured risk warning label into a standardized data package, wherein the data package includes a unique site identifier, data generation time, prediction duration, prediction result sequence, risk label content, and a data verification code;
[0134] S73. Sending the data packet to the upper-level scheduling management platform through the communication interface module. After receiving the data, the platform automatically connects to the monitoring visualization interface and displays the risk level information in the river section diagram, water level trend chart, and alarm timeline.
[0135] S74. Synchronously sending the data packet to the regional emergency response system for linkage with emergency plan dispatch, pre-disaster personnel transfer planning, and generation of temporary facility deployment suggestions;
[0136] S75. In a deployment scenario with local edge nodes, the prediction results and risk tags are further sent to downstream control terminals, including the sluice control module, the early warning broadcast system, the LED warning screen, and the site management client.
[0137] S76. After completing data upload and push, a communication log is generated for all communication behaviors of the current predicted batch. The log includes data sending time, target interface response status and data integrity verification results, and is stored in the log database for subsequent audit queries.
[0138] Based on a communication protocol-adaptive interface module and standardized data packet encapsulation mechanism, this system enables rapid and stable interoperability between water level forecast data and risk tags in a variety of system environments, breaking through the "closed transmission" bottleneck of traditional hydrological information systems. Combined with compatible docking capabilities with upper-layer platforms, graphical interfaces, dispatch terminals, and emergency response systems, this invention establishes a multi-level, cross-platform, task-oriented linkage mechanism, enabling the visualization of early warning information, the linkage of emergency dispatch instructions, and the efficient integration of edge response control.
[0139] In this embodiment, the S8 specifically includes:
[0140] S81. Set a fixed time period as the model operation scheduling interval. The period length can be set in hours or minutes. The scheduling management module performs global unified control to ensure the synchronous execution of multi-site model prediction.
[0141] S82. Before the start of each cycle, extract the latest observation data of the previous cycle from the data acquisition module, update the standardized time series sample, and construct a sliding window input segment containing the latest data to replace the current input queue of the model;
[0142] S83: Send the updated input data to the prediction model, perform forward reasoning operations, regenerate the water level prediction sequence and risk assessment results for the current cycle, and replace the old output content in the cache of the previous cycle;
[0143] S84. Detect the trend of residual values between the prediction model output and the actual observation value, and record the error offset status within consecutive cycles to dynamically determine whether the model performance has degraded and trigger a model fine-tuning request;
[0144] S85. Continue to use the current model parameters to perform the next round of prediction tasks under the condition that the set error tolerance range is met; if there is a trend of prediction deviation accumulation for multiple consecutive cycles, submit a model update task request to the local or remote training module;
[0145] S86. After executing all the processes of prediction, warning, communication and logging in this cycle, update the scheduling timestamp and re-enter the model reasoning and data processing cycle of the next cycle to achieve continuous dynamic prediction and risk monitoring of river water level status.
[0146] A time-driven forecast rolling mechanism and dynamic error feedback pathway are constructed to ensure forecast continuity while enabling periodic evaluation of model performance, deviation tracking, and adaptive updates. This mechanism effectively prevents model performance degradation due to changes in the external hydrological environment (such as sudden changes in rainfall patterns and terrain transformation). By fine-tuning triggering and scheduling rhythmic control, the model is ensured to always maintain its optimal operating state, improving the system's stability and environmental adaptability during long-term operation and providing strong engineering controllability and safety protection capabilities.
[0147] Example 1:
[0148] To verify the feasibility of this invention, we applied it to a typical piedmont river, deploying and validating the deep learning-based method for dynamic river water level monitoring and flood risk prediction. The basin area covers approximately 1,425 square kilometers, encompassing urban areas, hilly areas, and portions of farmland flood protection zones. The region is characterized by concentrated runoff and steep flood peaks. Traditional manual scheduling suffers from prediction lags and slow responses, often leading to urban flooding and overflowing risks in coastal farmland due to sudden changes in water levels.
[0149] To carry out system verification, the project team set up eight water level monitoring sections along this section of the river, installing water level radar meters, rain gauges, ultrasonic flow meters, and environmental temperature and humidity sensors. At the same time, they connected to the regional reservoir's dispatching command system and historical storage capacity data, and obtained a structured database containing 10 years of hydrological history. The data resolution is one record every 5 minutes, and the spatial accuracy uniformly adopts WGS-84 coordinates.
[0150] After the system is deployed, all data collection devices send data to edge computing nodes via wireless IoT gateways, with a uniform data collection frequency of once per minute. After data cleaning and standardization, the model receives a sliding window of multivariate hydrological characteristics from the past four hours every 10 minutes. This is fed into a trained two-layer bidirectional long-short-term memory network. The model uses an internal attention mechanism to focus on windows with abnormal flow increases and outputs water level forecasts for 12 time points within the next hour.
[0151] Due to the combined impact of sudden rainfall upstream and the opening of the reservoir to release floodwaters, the measured water level in the area rose rapidly from 39.2 meters to 40.7 meters within five minutes. After the system's prediction model completed its inference at 20:10, it output a one-hour forecast sequence indicating that the water level would exceed 41.8 meters at 20:40 and reach the set severe warning threshold of 42.3 meters at 20:55. The system immediately generated a structured warning label with a "severe risk" rating and pushed the warning information to the municipal water conservancy dispatch platform and the Emergency Management Bureau via an HTTP interface. It also automatically activated a flashing red sign on the LED warning screen to alert residents along the coast.
[0152] Actual observation data showed that the maximum error in this round of forecasts was 0.19 meters, and the forecast lead time was 48 minutes, far exceeding the average 17-minute advance warning level achieved by manual forecasting. No casualties or economic losses were caused during this process. Flood control personnel in the region received notification at 8:15 PM and arranged for temporary dike closures in low-lying areas, further demonstrating the high responsiveness of this method in responding to sudden flood events.
[0153] In another test, despite a brief burst of heavy rainfall, the forecast model adaptively determined that the event did not present a risk based on characteristics such as low rainfall, stable reservoir inflow, and low pre-saturation soil. The model output a risk level of "safe" and did not trigger any redundant warnings. Compared to traditional systems based on static thresholds, this avoided the waste of scheduling resources caused by "false alarms," demonstrating the significant advantages of this approach in reducing false alarm rates and improving system reliability.
[0154] During four months of continuous operation, the system completed 27,840 automated reasoning and prediction rounds, triggering 192 warnings of various levels, including 12 of severe or higher risk, with a false alarm rate of less than 2.3%. The model experienced no drift failures during deployment, and the standard deviation of error was kept within ±0.15 meters. Compared to the existing regional empirical regression model, this proposed method improved average prediction accuracy by 12.7%, increased the recognition rate of extreme hydrological events by approximately 30%, and shortened system response time by an average of approximately 41 seconds, representing significant technological advancements.
[0155] This embodiment verifies the practical usability and advancement of the present invention in a typical natural complex watershed environment, especially in key links such as data fusion processing, multi-step time series prediction, dynamic risk assessment and linkage early warning response. It demonstrates stability, accuracy and adaptability that are superior to traditional solutions, and has extremely strong value for engineering promotion and practical application.
[0156] The above description is only a preferred specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field, within the technical scope disclosed by the present invention, who makes equivalent replacements or changes based on the technical solution and inventive concept of the present invention, should be covered by the scope of protection of the present invention.
Claims
1. A method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning, characterized in that: The steps include: S1. Synchronously collect multi-source hydrological data at fixed time intervals along the river channel, and construct the original time series dataset by attaching time tags and spatial coordinates to the multi-source hydrological data. S2. Perform data cleaning and formatting on the original dataset, and organize the data structure into time series tensors with equal time intervals and fixed dimensions, to build a unified input format for the neural network input; S3, building a water level prediction model based on a unified input format; S4. Input the time series tensor obtained in step S2 into the water level prediction model, perform the forward reasoning process, and output the predicted water level sequence for multiple time steps in the future; S5. Set multi-level dynamic risk thresholds based on historical hydrological extreme value data, seasonal scheduling strategies, and site levels. Compare the predicted water level sequence with the risk threshold corresponding to the current cycle at each time point. Combined with the real-time rainfall intensity level, upstream inflow increment, gate opening status, and river channel flux margin, use segmented logic rules to determine whether there is a threshold-crossing risk or a trend-based flooding risk. S6. If there is a flood risk, a risk prediction tag is generated, and the generated risk prediction tag information is cached in the local warning queue and the remote warning linkage system; If there is no risk, the difference between the predicted result and the actual sampling value is recorded and the next round of data collection is started; S7. Output the water level prediction sequence and risk warning label to the external dispatching command system or visualization platform through the communication interface; S8. Rolling update of input data according to the set prediction cycle.
2. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S2 specifically includes: S21, performing a time alignment operation on the collected original multi-source hydrological data, and synchronously resampling all feature data using a fixed time interval; S22. Perform missing value processing on the resampled data, use sliding window interpolation to fill in incomplete time series segments, and construct a time-continuous hydrological data chain; S23. Detect and eliminate outliers in various sampled data, use outlier detection rules based on historical statistics to mark measurement data that deviate from the range, and replace them with the smoothed mean of the previous and next moments; S24, performing normalization processing on the cleaned data to map hydrological characteristics of different physical magnitudes and units to a unified scale interval; S25, performing encoding conversion on terrain-related data, expanding static terrain parameters including geographic coordinates, altitude, and underlying surface type into auxiliary feature columns consistent with the hydrological data structure, and combining them to form a unified input structure; S26. Arrange the preprocessing results in chronological order into time series samples in the form of fixed-length sliding windows.
3. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The water level prediction model includes an input layer, a first-layer bidirectional long short-term memory network, a second-layer deeply stacked bidirectional long short-term memory network, a cross-scale attention feature enhancement module, a multi-head attention mechanism fusion layer, a high-dimensional fully connected mapping module, an output layer, and a prediction result encapsulation and interface output module: The input layer receives standardized sliding window format time series samples, wherein the samples include a fixed time step length and feature dimension structure; The first-layer bidirectional long short-term memory network consists of a set of forward LSTM units and reverse LSTM units, which encode and learn the input sequence in the forward and reverse time order respectively; The second layer of deeply stacked bidirectional long short-term memory network performs context fusion learning across time windows based on the bidirectional hidden state output of the first layer; The cross-scale attention feature enhancement module calculates the short-term attention in the local time window and the long-term attention at the global sequence level for the bidirectional output sequence, and fuses the two types of attention weights in a proportional weighted manner; The multi-head attention mechanism fusion layer divides the weighted context features into multiple independent subspaces and simultaneously establishes multi-head attention sub-networks in parallel; The high-dimensional fully connected mapping module is composed of two fully connected sub-layers connected in series, with batch normalization and activation function inserted in between; The output layer has an output structure of a one-dimensional time series vector, where each element corresponds to the water level prediction result at a specific time step; The prediction result encapsulation and interface output module packages the prediction results and metadata into a structured data format, and selects HTTP, MQTT, or WebSocket communication protocols according to the calling environment, and sends them to the upper-level visualization platform, scheduling system, or edge warning terminal through the API gateway.
4. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S4 specifically includes: S41, inputting the standardized time series samples constructed according to the time sliding window into the input layer of the water level prediction model in sequence; S42. Send the data received by the input layer to the first-layer bidirectional long short-term memory network, calculate the forward hidden state sequence and the reverse hidden state sequence of the time series in the forward and reverse directions respectively, and splice them into the time series feature output of the first stage; S43, passing the first-stage temporal feature output to the second-layer bidirectional long short-term memory network to further extract deep dynamic features across the time window, and outputting the second-stage hidden state sequence as a complete temporal expression result; S44. Input the second-stage hidden state sequence into the attention mechanism module, assign weights to the hidden states of all time steps, extract the time series feature segments with key predictive significance, and generate a fused context vector; S45, passing the fused context vector to the fully connected mapping layer, setting the number and order of output units according to the required prediction time length, and mapping the time features into water level prediction results for multiple future time steps; S46. Output the water level prediction result to the downstream risk judgment module and save it in the local prediction cache area.
5. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S5 specifically includes: S51, extracting the predicted values of multiple consecutive time steps from the water level prediction results, and matching them one-to-one with the overflow risk thresholds of the corresponding time periods within the set period to form a time series comparison data set; S52. Based on historical observation data, regional scheduling rules, seasonal hydrological patterns, and flood characteristics over the years, multiple levels of risk threshold segments are set, wherein the risk threshold segments include warning water levels, guaranteed water levels, and extremely high warning water levels; S53, classifying the predicted water level value at each time step according to its interval position in the set risk threshold segment, and marking the corresponding risk level label, wherein the risk level label includes five risk states: safe, warning, alert, serious and extreme; S54, constructing an auxiliary condition set based on dynamic hydrological input information within the forecast period, including accumulated rainfall, upstream reservoir discharge, gate scheduling plan, and tributary inflow fluctuations; S55: Based on the predicted water level and the auxiliary condition set, a logical rule set is used to determine whether there is a continuous upward trend, a trend exceeding a critical threshold, or an extreme risk emergency event, and output a risk determination result; S56. When it is determined that there is a risk of flooding, the time of the first threshold exceeding, the time of the peak water level and the risk level are recorded to form a structured risk prediction label and submitted to the early warning processing process; if it is determined that there is no risk, the current status mark is updated and the data processing task of the next prediction cycle is continued.
6. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S6 specifically includes: S61. If the risk determination result indicates that there is a risk of flooding, generate a structured risk warning label, the label including the risk level, prediction start time, expected threshold exceeding time, maximum water level time, peak water level value, site number, geographic coordinates, and prediction confidence score; S62. Write the structured risk warning tag into a local warning buffer queue, where the buffer queue has timestamp sorting and tag version tracking functions. S63. Call the local linkage rule in the edge node device and determine whether to trigger the local buzzer alarm, LCD display module or SMS push module based on the risk level field contained in the tag; S64. Send the structured risk warning label to the remote warning linkage system in the form of a data packet, wherein the data packet includes the label content, the model version identifier, the inference time identifier, and the site data summary; S65. Under the condition that there is no risk of flooding, the prediction result of the current cycle is compared with the latest measured value for error analysis, and the deviation of the result is calculated; S66. Under risk-free conditions, the prediction results and comparison error information are recorded in the local status log, and the warning label information in the previous round cache is cleared.
7. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S7 specifically includes: S71. Configure a communication interface module, which supports three communication modes: HTTP, WebSocket, and MQTT, and has data compression, packet transmission, and breakpoint resumable transmission functions; S72. Encapsulate the water level prediction result and the structured risk warning label into a standardized data package, wherein the data package includes a unique site identifier, data generation time, prediction duration, prediction result sequence, risk label content, and a data verification code; S73. Sending the data packet to the upper-level scheduling management platform through the communication interface module. After receiving the data, the platform automatically connects to the monitoring visualization interface and displays the risk level information in the river section diagram, water level trend chart, and alarm timeline. S74. Synchronously sending the data packet to the regional emergency response system; S75. In a deployment scenario with local edge nodes, the prediction results and risk tags are further sent to downstream control terminals, including the sluice control module, the early warning broadcast system, the LED warning screen, and the site management client. S76. After completing data upload and push, a communication log is generated for all communication behaviors of the current predicted batch. The log includes data sending time, target interface response status and data integrity verification results, and is stored in a log database.
8. The method for dynamic monitoring of river water levels and prediction of flood risk based on deep learning according to claim 1, characterized in that: The S8 specifically includes: S81. Set a fixed time period as the model operation scheduling interval. The period length can be set in hours or minutes, and the scheduling management module performs global unified control. S82. Before the start of each cycle, extract the latest observation data of the previous cycle from the data acquisition module, update the standardized time series sample, and construct a sliding window input segment containing the latest data; S83: Send the updated input data to the prediction model, perform forward reasoning operations, regenerate the water level prediction sequence and risk assessment results for the current cycle, and replace the old output content in the cache of the previous cycle; S84, detecting the trend of residual values between the output of the prediction model and the actual observation value, and recording the error offset status within consecutive cycles; S85. Continue to use the current model parameters to perform the next round of prediction tasks under the condition that the set error tolerance range is met; if there is a trend of prediction deviation accumulation for multiple consecutive cycles, submit a model update task request to the local or remote training module; S86. After executing all the processes of prediction, warning, communication and logging in this cycle, update the scheduling timestamp and re-enter the model reasoning and data processing loop of the next cycle.
Citation Information
Cited By
Reservoir water regimen analysis method and system based on artificial intelligence
CN121119724A
Water level flow intelligent monitoring system and method based on space-time prediction and quantum sliding window
CN121436423A
Underground pipe network partition metering monitoring and regulation system based on Internet of Things
CN121452494A
Sea-entering river cross-regional pollution cooperative treatment scheduling system
CN121684556A
Reservoir emergency prediction and management method and system based on cloud data, and electronic equipment
CN121787642A