A rapid assessment method for flood drainage effects combined with machine learning ensemble prediction

By combining the numerical model of hydrodynamics and multi-regression model ensemble prediction methods, the problem of insufficient response speed of urban flood emergency management is solved, the ability to quickly evaluate the flood drainage effect is achieved, and the efficiency of emergency decision-making is improved.

CN119294269BActive Publication Date: 2025-03-28NANJING UNIV OF INFORMATION SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411808187.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-10
Publication Date
2025-03-28
Estimated Expiration
2044-12-10

AI Technical Summary

Technical Problem

The existing technology has insufficient response speed in urban flood emergency management, and a single machine learning-based regression model cannot accurately and effectively perform flood prediction.

Method used

Combining the numerical model of physical significance with multiple regression algorithms based on machine learning methods, a ensemble prediction is carried out through Bayesian hyperparameter optimization to construct a rapid evaluation model for flood drainage effect.

Benefits of technology

It has greatly improved the response speed of urban flood emergency management, and can quickly evaluate the drainage effect under different rainwater outlet layout plans, help relevant departments make quick decisions and reduce property losses and casualties.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119294269B_ABST
    Figure CN119294269B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction, comprising the following steps: (1) collecting and collating characteristic data for predicting and assessing drainage effects under flood conditions; (2) establishing a flood hydrodynamic numerical model based on a physical mechanism; (3) constructing a data set and performing data preprocessing; (4) using a Bayesian optimizer to determine the optimal hyperparameter combination of each regression model; (5) training each regression model based on multiple machine learning methods and hyperparameter optimization; (6) performing ensemble prediction on each multi-regression model to construct a rapid prediction and assessment model for drainage effects during a flood process; and (7) using the model trained in step (6) for rapid assessment and prediction. The present invention improves the response speed of urban flood emergency management.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of flood numerical forecasting, and in particular to a method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction. Background Art

[0002] Urban flooding will become more frequent due to the increase in the frequency of extreme rainfall caused by climate change. The dynamic process of urban flooding is closely related to the urban surface and drainage conditions. Describing the flood process through drainage systems and complex urban environments is essential for understanding and assessing urban flood risks.

[0003] The existing hydrodynamic numerical models can simulate the evolution of urban floods under the effect of pipe network drainage, but the timeliness of rapid response decision-making required for urban flood emergency management is still insufficient. At present, the widely used machine learning has a certain degree of efficiency, but a single regression model based on machine learning cannot accurately and effectively predict. Summary of the invention

[0004] Purpose of the invention: The purpose of the present invention is to provide a method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction, combined with a hydrodynamic numerical model with physical significance, using multiple regression algorithms based on machine learning methods, and performing ensemble prediction through Bayesian hyperparameter optimization to solve the problems existing in the background technology.

[0005] Technical solution: The method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction described in the present invention comprises the following steps:

[0006] (1) Collect and organize characteristic data for predicting and evaluating drainage effects under flood conditions;

[0007] (2) Establish a flood hydrodynamic numerical model based on physical mechanisms;

[0008] (3) Construct a data set and perform data preprocessing;

[0009] (4) Use Bayesian optimizer to determine the optimal hyperparameter combination for each regression model;

[0010] (5) Training various regression models based on multiple machine learning methods and hyperparameter optimization;

[0011] (6) Perform ensemble predictions on each multi-regression model and construct a rapid prediction and evaluation model for the drainage effect during floods;

[0012] (7) Use the model trained in step (6) for quick evaluation and prediction.

[0013] Furthermore, step (1) is specifically as follows: collecting relevant terrain data and rainfall data for driving the simulation calculation of the hydrodynamic model; wherein the relevant terrain data includes: terrain elevation data, data of different slopes, rainfall data of different recurrence periods and different rainfall durations.

[0014] Furthermore, in step (2), the flood hydrodynamic numerical model is calculated using a two-dimensional shallow water equation, and its control equation is:

[0015] ;

[0016] in t It's time. x and y is the Cartesian coordinate in the horizontal and vertical directions, q contains the vectors of various hydraulic variables, f and g are x and y Directional flux, R,S b and S f represents the mass term, the bottom slope and the bottom friction term; the formula is as follows:

[0017] ;

[0018] in, h Represents water depth. u and v It corresponds to x and y The average velocity component in the direction of b represents the bottom elevation, g is the acceleration due to gravity, R is the rainfall rate, I is the permeability, D is the drainage loss, C f is the friction coefficient of the bottom bed; the finite volume method in Godunov format is used to discretize it in space; the interface flux is calculated using the HLLC Riemann solver, and the time step is discretized using the explicit method, where the time step is determined according to the CFL condition.

[0019] Furthermore, step (3) is as follows: First, set the normalized prediction value index, i.e. R DE ; The formula is as follows:

[0020] ;

[0021] in, A noDL and A DL Respectively represent the water depth thresholds that affect the normal operation of urban pedestrians and vehicles h * ,N inlet Represents the total number of rainwater outlets in the area; then different multi-combination parameters are used as model input parameters, and based on the flood hydrodynamic numerical model, the drainage effect index driven by different combination parameters is calculated R DE , construct a data set; divide the data set into training set and test set and perform normalization preprocessing.

[0022] Furthermore, step (4) is as follows: using multiple machine learning methods and combining with Bayesian hyperparameter optimizer to build multiple machine learning regression models for urban flood drainage effect prediction and evaluation, including XGBoost distributed gradient boosting library, Random Forest, LightGBM lightweight gradient boosting machine, Extra Trees extreme random tree, Elastic Net elastic network; for each model, initialize the parameters and determine their value range, including: the number of trees n_estimators, the maximum depth max_depth, the learning rate learning_rate, and combine the Bayesian optimizer to determine the optimal value of the hyperparameter.

[0023] Furthermore, step (5) is as follows: after determining the optimal hyperparameter combination for each model, each model is trained; wherein, the XGBoost model obtains the final prediction value of the XGBoost model for the input data; the RandomForest model forms the final prediction value of the Random Forest model for the input data; the LightGBM model obtains the final prediction value by weighting the prediction results of all trees; the Extra Trees model obtains the final prediction value of the Extra Trees model for the input data; the Elastic Net model is finally trained to obtain the optimal parameter configuration of the Elastic Net model, and uses these parameters to predict the input data.

[0024] Furthermore, step (6) is as follows: The prediction values ​​generated by each model constitute a feature matrix containing the prediction results of all models , recorded as:

[0025] ;

[0026] Among them, among them, They respectively represent the final prediction value of the input data by the XGBoost model; the final prediction value of the input data by the Random Forest model; the final prediction value obtained by the LightGBM model by weighting the prediction results of all trees; the final prediction value of the input data by the Extra Trees model; and the final prediction value of the input data by the Elastic Net model.

[0027] Then, a linear weighted integration method is used to assign weights to the prediction results of each model, and a weighted sum is performed to obtain the final prediction value; the least squares method is used to determine the optimal model weight; after the weight is determined, the model prediction results of each sample are weighted summed to obtain the final ensemble prediction result; after the ensemble prediction is completed, the mean square error MSE and R² score are used to evaluate the final ensemble model.

[0028] Furthermore, the optimal model weights are determined using the least squares method as follows:

[0029] Let the weight vector be ,in, They represent the weight values ​​of the XGBoost model, the Random Forest model, the LightGBM model, the Extra Trees model, and the Elastic Net model respectively. The final prediction value of each test sample is It is expressed as:

[0030] ;

[0031] The feature matrix of all test samples and the actual observation vector , determine the optimal weight vector by minimizing the loss function , the formula is as follows:

[0032] .

[0033] An electronic device described in the present invention includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the computer program is loaded into the processor, it implements any one of the methods described in the rapid assessment of flood and drainage effects combined with machine learning set prediction.

[0034] A storage medium described in the present invention stores a computer program, and when the computer program is executed by a processor, it implements any one of the methods for rapid assessment of flood drainage effects combined with machine learning set prediction.

[0035] Beneficial effects: Compared with the prior art, the present invention has the following significant advantages: The present invention combines the hydrodynamic numerical model and the multi-regression model ensemble prediction method based on Bayesian optimization, which greatly improves the response speed of urban flood emergency management. In extreme rainfall events, the drainage effect of different stormwater outlets in urban floods can be quickly evaluated, so that relevant emergency departments can make decisions more quickly, deploy rescue resources, and reduce potential property losses and casualties. By predicting and evaluating the drainage effects under various stormwater outlet layout schemes, a scientific basis can be provided for urban planning and municipal construction, and a more effective stormwater outlet layout and urban infrastructure can be designed. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 is a flow chart of the present invention;

[0037] Figure 2 Constructing a data set for the flood-based hydrodynamic numerical model of the present invention;

[0038] Figure 3 It is a schematic diagram of the multi-regression model ensemble prediction method based on Bayesian optimization of the present invention. DETAILED DESCRIPTION

[0039] The technical solution of the present invention is further described below in conjunction with the accompanying drawings.

[0040] like Figure 1 As shown, an embodiment of the present invention provides a method for quickly evaluating flood drainage effects combined with machine learning set prediction, comprising the following steps:

[0041] (1) Data collection: In order to study the effects of pipe network drainage in different terrain features after heavy rainfall of different intensities and durations in urban environments, especially considering the effects of surface water flow movement with terrain changes and slope changes on pipe network drainage, it is necessary to collect relevant terrain data and rainfall data to drive the simulation calculation of the hydrodynamic model. In particular, terrain elevation data, data of different slopes, rainfall data of different return periods and rainfall durations, etc. are considered.

[0042] For different slope data, in order to study the drainage efficiency of the pipeline network under the influence of different slopes, a series of analyzable slope conditions are created. By modifying the elevation digital model of the selected study area, only the slope change is changed, without affecting the terrain characteristics of various urban buildings on the surface.

[0043] For rainfall data of different rainfall intensities and rainfall durations, please refer to the design rainfall intensity formula:

[0044] (1);

[0045] in, iTo design the rainstorm intensity; T is the return period, t is the duration of rainfall; A.C and b is the regional parameter, n is the rainstorm attenuation coefficient, A.C , b The value is also selected based on the region.

[0046] (2) Construction of flood hydrodynamic model: The numerical model of surface flood hydrodynamics driven by rainfall is solved using the two-dimensional shallow water equation. The matrix form of its control equation is as follows:

[0047] (2);

[0048] in t It's time. x and y is the Cartesian coordinate in the horizontal and vertical directions, q contains the vectors of various hydraulic variables, f and g are x and y Directional flux, R,S b and S f Represents the mass term, the bed slope and the bed friction term. The above vectors are expressed as:

[0049] (3);

[0050] in h Represents water depth. u and v It corresponds to x and y The average velocity component in the direction of b represents the bottom elevation, g is the acceleration due to gravity, R is the rainfall rate, I is the permeability, D is the drainage loss, C f is the coefficient of friction of the substrate.

[0051] Based on the above control equations, the finite volume method (FVM) in Godunov format is used to discretize them in space. The HLLC (Harten-Lax-van Leer-Contact) Riemann solver is used to calculate the interface flux, which can effectively capture shock waves and flood waves that propagate forward in the form of discontinuous waves. For time discretization, it is performed by explicit methods, so the choice of time step is crucial to ensure the stability and accuracy of the calculation of variables over time. Therefore, the time step is determined according to the CFL (Courant-Friedrichs-Lewy) condition.

[0052] (3) Introducing drainage losses into flood hydrodynamic models

[0053] The present invention mainly considers the impact of the layout of the pipe network drainage outlets in municipal construction and the terrain slope on flooding, so in the two-dimensional surface hydrodynamic numerical model, the rainwater outlet is mainly considered as the confluence point in the model. For the pipe network drainage loss in step (2) (i.e., D in formula (3)), when the surface water flow rate is lower than the maximum carrying capacity of the rainwater outlet, the relationship between the surface drainage flow rate and the surface water after rainfall is considered, and the drainage loss is calculated using the following drainage relationship:

[0054] (4);

[0055] in, a , b are parameters related to the type of stormwater inlet and the corresponding geometric characteristics, h is the surface water depth, c o is the efficiency coefficient of the stormwater outlet drainage. c o , indicating the blockage of the stormwater outlet, with a value range of 0-1 (0 means complete blockage, 1 means no blockage).

[0056] For the network drainage loss in step (2) (i.e., the loss in formula (3) D ), when the surface water flow rate is greater than the maximum carrying capacity of the stormwater inlet, the drainage loss of the pipe network in the model is the maximum drainage capacity of the stormwater inlet design standard.

[0057] (4) Definition of prediction value: In order to quantify the drainage benefits of the pipe network with different rainwater outlet distributions under heavy rainfall, a normalized prediction value index is defined as R DE . R DE The indicator is calculated by calculating the relative difference in the flood inundation range before and after the pipe network is drained, and then analyzing the total number of rainwater outlets in the study area. Ninlets Normalize to express:

[0058] (5);

[0059] in, A noDL and A DL Respectively represent the water depth thresholds that affect the normal operation of urban pedestrians and vehicles h * (Consider here h * = 0.1m, h * = 0.3m, h * = 0.5m) without and with drainage considered.

[0060] Considering the density of stormwater inlets in the study area, R DE It provides an overall quantification of the benefit indicator of the stormwater inlet drainage function in reducing the scope of local flood inundation. It focuses more on the drainage effect of the stormwater inlet in the study area on the entire flood event, rather than the local effect of a single stormwater inlet. R DE The higher the value, the more significant its drainage effect is in reducing surface water during the evolution of floods. By analyzing this indicator under different urban terrain characteristics and rainfall conditions, the effect of the layout of stormwater inlets on the drainage of surface water under the interaction of different terrain characteristics and rainfall characteristics can be quantified.

[0061] (5) If Figure 2 As shown in the figure, the data set is constructed: different multi-combination parameters are used as model input parameters, and based on the flood hydrodynamic numerical model described in step (3), the drainage effect indicators driven by different combination parameters are calculated. R DE In order to reduce the risk of overfitting and underfitting and improve the generalization ability of the model, the data set is divided into a training set and a test set in a ratio of 7:3. At the same time, in order to improve the stability and efficiency of the model, all data need to be normalized and preprocessed, namely:

[0062] (6);

[0063] in, X norm is the normalized data. X is the feature data to be processed, X minis the minimum value in X, X max for X The maximum value in .

[0064] (6) Figure 3 As shown in the figure, model parameter optimization: multiple regression models based on machine learning methods are used, combined with the Bayesian hyperparameter optimization method for ensemble prediction, to build and train multiple machine learning regression models for urban flood drainage effect prediction and evaluation, and perform ensemble prediction. Five regression models based on machine learning are built and trained, including XGBoost, Random Forest, LightGBM, Extra Trees, and Elastic Net. The training steps of each model follow clear initialization parameters, model construction, feature selection, data splitting and integration logic to ensure that the drainage network efficiency optimization problem can be effectively predicted.

[0065] The preprocessed data set is standardized to obtain standardized training and test sets. The standardized training sets are used to train custom models, including XGBoost, Random Forest, LightGBM, ExtraTrees, and Elastic Net models. For each model, its main parameters are initialized and its value range is determined, such as the number of trees (n_estimators), maximum depth (max_depth), learning rate (learning_rate) and other hyperparameters, and the Bayesian optimizer is used to determine the optimal values ​​of these hyperparameters.

[0066] The Bayesian optimization process for hyperparameters is as follows: First, define the hyperparameter search space for each model, including the main hyperparameters in each model and their value ranges. By defining the value ranges of these parameters, it is ensured that the Bayesian optimizer can involve all possible parameter combinations during the search process. After defining the parameter range, the Bayesian optimizer performs an iterative search in the hyperparameter search space. In each iteration, the optimizer uses the Gaussian process to model the objective function based on the current model performance results and the corresponding parameter combinations, predicts the model performance under different parameter combinations, and calculates and selects the next optimal parameter combination for trial based on the output of the model. In each trial, the optimizer divides the data set into multiple subsets for each parameter combination, uses these subsets for training and verification in turn, calculates the average error of the model, and evaluates the prediction performance of the model under this parameter combination. The optimizer will update its exploration strategy for the hyperparameter space based on these evaluation results to maximize the search efficiency. In order to minimize the training error, the Bayesian optimizer takes minimizing the mean square error (MSE) as the goal, iterates the hyperparameter combination of each model multiple times, and finally outputs a set of optimal hyperparameter combinations.

[0067] (7) Model construction and training: After determining the optimal hyperparameter combination for each model, train each model.

[0068] (a) The XGBoost model makes an initial prediction for the training data and calculates the residual between the predicted value and the actual value. In each iteration, the residual is input into a custom decision tree model for fitting, a new regression tree is built to learn the residual, the model's prediction results are updated, and finally the final prediction value of the XGBoost model for the input data is obtained through the weighted sum of all weak learners.

[0069] (b) The Random Forest model generates several subsets from the standardized training data set through a self-sampling method, and each subset is used to train a custom decision tree model. The decision tree model starts from the root node and gradually divides the data set until it reaches the maximum depth or meets the conditions of the minimum sample split and leaf node sample number. Each tree is trained on its training subset, and the prediction results of all trees are integrated and averaged to form the final prediction value of the Random Forest model for the input data.

[0070] (c) LightGBM model The training data is input into the LightGBM framework. The framework continuously improves the model performance by gradually building decision trees. In each iteration, the model selects a feature to split, determines the best split point by maximizing information gain, builds a new tree to reduce the residual of the current model, and finally obtains the final prediction value by weighting the prediction results of all trees.

[0071] (d) The Extra Trees model randomly generates subsets of the standardized training data set through a self-service sampling method, and trains a custom decision tree for each subset. Unlike the Random Forest model, Extra Trees has stronger randomness when selecting feature split points, and the split point of each feature is completely randomly selected. The prediction results of all decision trees are integrated and averaged to obtain the final prediction value of the Extra Trees model for the input data.

[0072] (e) The Elastic Net model inputs the standardized training data into the regularized linear regression model. By minimizing the objective loss function, which includes the prediction error term and the regularization term, the model parameters are continuously updated using the gradient descent method, and the optimal parameter configuration of the Elastic Net model is finally trained and used to predict the input data.

[0073] (8) Ensemble prediction and model evaluation: After completing the training and optimization of each model, the prediction results of each model are combined for integrated prediction. The advantages of different models under different data characteristics are used to reduce the possible errors of a single model, thereby improving the prediction accuracy. The process of ensemble prediction is as follows:

[0074] For each test sample, five models retrained after Bayesian optimization were used for prediction, including XGBoost, Random Forest, LightGBM, Extra Trees, and Elastic Net models. The prediction values ​​generated by each model constitute a feature matrix containing the prediction results of all models. , recorded as:

[0075] (7);

[0076] in, They respectively represent the final prediction value of the input data by the XGBoost model; the final prediction value of the input data by the Random Forest model; the final prediction value obtained by the LightGBM model by weighting the prediction results of all trees; the final prediction value of the input data by the Extra Trees model; and the final prediction value of the input data by the Elastic Net model.

[0077] Then, a linear weighted integration method is used to assign a weight to the prediction results of each model, and they are weighted summed to obtain the final prediction value. The Least Squares Method is used to determine the optimal model weight.

[0078] The specific process is: Assume that the weight vector is:

[0079] ;

[0080] in, They represent the weight value of the XGBoost model, the weight value of the Random Forest model, the weight value of the LightGBM model, the weight value of the Extra Trees model, and the weight value of the Elastic Net model.

[0081] The final predicted value of each test sample is It can be expressed as:

[0082] (8);

[0083] Given the feature matrix of all test samples and the actual observation vector , by minimizing the loss function (Equation 9) to determine the optimal weight vector :

[0084] (9);

[0085] After the ensemble prediction is completed, the final ensemble model is evaluated using the mean square error (MSE) and R² score. The expression is:

[0086] (10);

[0087] (11);

[0088] MSE stands for mean square error, which is the average of the squares of the difference between the predicted value and the actual value. It is used to measure the prediction deviation of the model. The smaller the value, the smaller the error. R² It represents the coefficient of determination, which measures the model's ability to explain data fluctuations. Its value range is from 0 to 1. The closer it is to 1, the better the model fit. n Indicates the number of samples used for validation; y i represents the predicted value, Indicates the actual value, Represents the sample mean.

[0089] By calculating MSE, we can evaluate the average error of the ensemble model on the test set. R² The score can measure how well the integrated model fits the data and how well it explains it.

[0090] An embodiment of the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the computer program is loaded into the processor, it implements any one of the methods for rapid assessment of flood and drainage effects combined with machine learning set prediction.

[0091] An embodiment of the present invention also provides a storage medium storing a computer program, which, when executed by a processor, implements any one of the methods for rapid assessment of flood and drainage effects combined with machine learning set prediction.

Claims

1. A method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction, characterized in that: The following steps are involved: (1) Collect and organize characteristic data for predicting and evaluating drainage effects under flooding; specifically, collect relevant terrain data and rainfall data for driving hydrodynamic model simulation calculations; the relevant terrain data include terrain elevation data, data of different slopes, and rainfall data of different return periods and rainfall durations; for data of different slopes, modify the digital elevation model of the selected study area to only change its slope, without affecting the terrain characteristics of various urban buildings on the surface; For rainfall data with different rainfall intensities and rainfall durations, the rainfall intensity formula is designed: (1); in, i To design the rainstorm intensity; T is the return period, t is the duration of rainfall; A.C and b is the regional parameter, n is the rainstorm attenuation coefficient, A.C , b The value is also selected according to the region; (2) Establish a flood hydrodynamic numerical model based on physical mechanisms. The flood hydrodynamic numerical model uses a two-dimensional shallow water equation for calculation, and its governing equation is: ; in t It's time. x and y is the Cartesian coordinate in the horizontal and vertical directions, q contains the vectors of various hydraulic variables, f and g are x and y Directional flux, R, S b and S f represents the mass term, the bottom slope and the bottom friction term; the formula is as follows: ; in, h Represents water depth. u and v It corresponds to x and y The average velocity component in the direction of b represents the bottom elevation, g is the acceleration due to gravity, R is the rainfall rate, I is the permeability, D is the drainage loss, C f is the friction coefficient of the bottom bed; the finite volume method of Godunov format is used to discretize it in space; the interface flux is calculated by HLLC Riemann solver, and the time discretization is performed by explicit method, where the time step is determined according to the CFL condition; D The formula for drainage loss is as follows: in, ;in, a , b are parameters related to the type of stormwater inlet and the corresponding geometric characteristics, h is the surface water depth, c o is the efficiency coefficient of stormwater drainage; c o , indicates the blockage of the rainwater outlet, with a value range of 0-1, 0 indicates complete blockage, and 1 indicates no blockage; (3) Construct a data set and perform data preprocessing; the details are as follows: First, set the normalized prediction value index, i.e. R DE ; The formula is as follows: ; in, A noDL and A DL Respectively represent the water depth thresholds that affect the normal operation of urban pedestrians and vehicles h * The flooded area before and after drainage is considered below; N inlet Represents the total number of rainwater outlets in the area; then different multi-combination parameters are used as model input parameters, and based on the flood hydrodynamic numerical model, the drainage effect index driven by different combination parameters is calculated R DE , construct a data set; divide the data set into a training set and a test set and perform normalization preprocessing; (4) Use the Bayesian optimizer to determine the optimal hyperparameter combination for each regression model; specifically, multiple machine learning methods are used in combination with the Bayesian hyperparameter optimizer to build multiple machine learning regression models for urban flood drainage effect prediction and evaluation, including the XGBoost distributed gradient boosting library, Random Forest, LightGBM lightweight gradient boosting machine, Extra Trees extreme random tree, and Elastic Net elastic network; for each model, initialize the parameters and determine their value ranges, including: the number of trees n_estimators, the maximum depth max_depth, the learning rate learning_rate, and combine the Bayesian optimizer to determine the optimal value of the hyperparameter; the Bayesian optimization process for hyperparameters is as follows: first, define the hyperparameter search space for each model, including the hyperparameters in each model and their value ranges; by defining the value ranges of these parameters, ensure that the Bayesian optimizer can involve all possible parameter combinations in the search process; after defining the parameter range, the Bayesian optimizer performs an iterative search in the hyperparameter search space. At each iteration, the optimizer uses the Gaussian process Gaussian to perform an iterative search based on the current model performance results and the corresponding parameter combination. Process models the objective function, predicts the model performance under different parameter combinations, and calculates and selects the next optimal parameter combination for trial based on the model output; in each trial, the optimizer divides the data set into multiple subsets for each parameter combination, uses these subsets for training and verification in turn, calculates the average error of the model, and thus evaluates the prediction performance of the model under this parameter combination; the optimizer updates its exploration strategy for the hyperparameter space based on these evaluation results; the Bayesian optimizer iterates the hyperparameter combination of each model multiple times with the goal of minimizing the mean square error (MSE), and finally outputs a set of optimal hyperparameter combinations; (5) Training various regression models based on multiple machine learning methods and hyperparameter optimization; specifically, after determining the optimal hyperparameter combination for each model, each model is trained; among them, the XGBoost model obtains the final prediction value of the XGBoost model for the input data; the Random Forest model forms the final prediction value of the Random Forest model for the input data; the LightGBM model obtains the final prediction value by weighting the prediction results of all trees; the Extra Trees model obtains the final prediction value of the Extra Trees model for the input data; the Elastic Net model is finally trained to obtain the optimal parameter configuration of the Elastic Net model, and these parameters are used to predict the input data; (6) Perform ensemble predictions on each multi-regression model to construct a rapid prediction and evaluation model for the drainage effect during floods; the details are as follows: the prediction values ​​generated by each model constitute a feature matrix containing the prediction results of all models , recorded as: ; in, They respectively represent the final prediction value of the input data by the XGBoost model; the final prediction value of the input data by the Random Forest model; the final prediction value obtained by the LightGBM model by weighting the prediction results of all trees; the final prediction value of the input data by the Extra Trees model; and the final prediction value of the input data by the ElasticNet model. Then, a linear weighted integration method is used to assign weights to the prediction results of each model, and a weighted sum is performed to obtain the final prediction value; the least squares method is used to determine the optimal model weight; after the weight is determined, the weight is used to perform a weighted summation of the model prediction results of each sample to obtain the final ensemble prediction result; after the ensemble prediction is completed, the mean square error MSE and R² score are used to evaluate the final ensemble model; the optimal model weight is determined using the least squares method as follows: Let the weight vector be ,in, They represent the weight values ​​of the XGBoost model, the Random Forest model, the LightGBM model, the Extra Trees model, and the Elastic Net model respectively. The final prediction value of each test sample is It is expressed as: ; The feature matrix of all test samples and the actual observation vector , determine the optimal weight vector by minimizing the loss function , the formula is as follows: ; (7) Use the model trained in step (6) for quick evaluation and prediction.

2. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the computer program is loaded into the processor, it implements the method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction according to claim 1.

3. A storage medium storing a computer program, characterized in that: When the computer program is executed by the processor, it implements the method for rapid assessment of flood drainage effects combined with machine learning ensemble prediction according to claim 1.

Citation Information

Patent Citations

  • Intelligent flood forecasting method based on MCRBiLSTM

    CN115860231A

  • Urban flood deep learning prediction method considering disaster-pregnant environment clustering

    CN116523114A