A water quality prediction method for water diversion projects based on SVR coupling mechanism model

By adopting the water quality prediction method based on SVR coupling mechanism model in the water diversion project, the problems of low water quality prediction efficiency and insufficient prediction performance in the water diversion project in the existing technology are solved, and fast and accurate water quality prediction is achieved, which is a water diversion solution. The formulation provides a scientific basis.

CN118094323BActive Publication Date: 2025-02-18CHINA INST OF WATER RESOURCES & HYDROPOWER RES
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410212510.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-02-27
Publication Date
2025-02-18
Estimated Expiration
2044-02-27

AI Technical Summary

Technical Problem

The existing technology has problems of low efficiency and insufficient prediction performance in water quality prediction in water diversion projects. The calculation of mechanism model takes time, while the water quality machine learning model has insufficient simulation performance due to the low quality of the sample database.

Method used

The water quality prediction method of water diversion engineering based on the SVR coupling mechanism model is adopted. By collecting and sorting the basic data along the water diversion project, a mechanism water quality prediction model and sample database are constructed, and the water quality prediction is predicted using the SVR coupling mechanism model.

Benefits of technology

It has achieved rapid and accurate water quality prediction of rivers along the water diversion project, which is short time and high efficiency, and solved the problem of poor prediction performance caused by insufficient sample data, providing a scientific basis for the reasonable formulation of water diversion plans.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118094323B_ABST
    Figure CN118094323B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for predicting water quality of water diversion projects based on an SVR coupling mechanism model, the method comprising the following steps: step 1, collecting basic data along the water diversion project; step 2, constructing a mechanism water quality prediction model; step 3, constructing a sample database; step 4, constructing an SVR coupling mechanism model; step 5, model verification; step 6, water quality prediction of water diversion projects. The method of the present invention constructs a mechanism water quality prediction model based on existing relevant hydrological and other information, and uses it to simulate the river water quality response process under possible water diversion scenarios, thereby constructing a sample database, and then constructing an SVR coupling mechanism model to predict water quality. The method of the present invention takes into account the influence of water quality and flow at the same time, and can quickly and accurately realize the water quality prediction of the river along the water diversion project, with high efficiency, effectively solving the problem of poor prediction performance due to insufficient sample data, and having strong practicality, providing a scientific basis for the rational formulation of water diversion plans.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of water quality prediction, and in particular relates to a water quality prediction method for a water diversion project based on an SVR coupling mechanism model. Background Art

[0002] Water resource shortage and uneven distribution in time and space are the challenges faced by my country in the development, utilization and management of water resources. Building water diversion projects to supply water from water-rich areas to water-scarce areas is an effective measure to solve this problem. my country's large-scale inter-basin water diversion projects are gradually increasing. They further affect the ecological environment and economic and social development by changing the original hydrological conditions of rivers and lakes along the route. Water quality prediction is the basis for the rational formulation of water diversion plans for water diversion projects and an important research content for water quality safety assurance. It is necessary to study it.

[0003] At present, the research method used for water quality prediction is mainly mechanism model. However, the scheduling plan of water diversion projects needs to be optimized according to the water quality prediction results. During this period, multiple batch iterative calculations will be performed, which is time-consuming and inefficient. Therefore, the application of mechanism model in the optimization process is more limited. The prediction speed of water quality machine learning model meets the requirements of optimization scheduling calculation and is adopted first. However, the planned water diversion projects often lack sufficient historical water quality and other monitoring data, and the sample database quality is low, resulting in insufficient simulation performance of water quality machine learning model. Therefore, for water diversion projects, it is difficult to make efficient water quality predictions with separate mechanism models and machine learning models. Summary of the invention

[0004] The purpose of the present invention is to provide a water quality prediction method for water diversion projects based on the SVR coupling mechanism model to solve the above technical problems.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] The present invention discloses a water quality prediction method for a water diversion project based on an SVR coupling mechanism model, the method comprising the following steps:

[0007] Step 1, collecting basic data along the water diversion project: collecting and arranging basic data along the water diversion project, including topographic data, hydrological data along the line, water quality data along the line, outflow data of sewage outlets, tributaries, and water intakes along the line, and gate structure parameters; the hydrological data along the line include daily water level and flow data of hydrological stations along the line or daily water level data of water level stations, and the water quality data along the line include daily concentrations of various water quality indicators;

[0008] Step 2, construct a mechanism water quality prediction model: Based on the basic data collected along the water diversion project, a mechanism water quality prediction model for the river along the water diversion project is constructed, including a hydrodynamic module and a water quality module, wherein the upstream hydrodynamic boundary is the daily flow data at the hydrological station, the downstream hydrodynamic boundary is the daily water level data at the hydrological station or water level station, and the upstream water quality boundary is the daily concentration of each water quality index. The gate adopts flow control, and the water balance of the model is considered, and the outflow of the sewage outlet, tributary, and water intake into the river are all taken as source and sink items; the mechanism water quality prediction model is calibrated and verified to determine the river roughness and the degradation coefficient of each water quality index;

[0009] Step 3, build a sample database: determine the upstream flow, water intake, flow through the gate, and upstream water quality of the water diversion project, perform interpolation, and obtain possible water diversion scenarios; use the constructed mechanism water quality prediction model to simulate, extract daily water quality data of a section and determine the final output result of water quality, and form a sample database together with the corresponding upstream flow, water intake, flow through the gate, and upstream water quality;

[0010] Step 4, constructing the SVR coupling mechanism model: The construction of the SVR coupling mechanism model includes the steps of selecting a kernel function, calling a sample database, and selecting an optimization algorithm for parameter optimization, wherein the radial basis kernel function is selected as the kernel function of the model; calling the data in the sample database as the training data set and the verification data set, taking the upstream flow, water intake, gate flow, and upstream water quality as input features, and taking the predicted cross-section water quality data as the output result; using the whale optimization algorithm for parameter optimization, the hyperparameters required to be input into the SVR coupling mechanism model include the penalty coefficient C, the insensitive loss coefficient ε, and the kernel function parameter σ, and optimizing the hyperparameters through iterative updating of the whale optimization algorithm until the optimal hyperparameters are output, and substituted into the SVR coupling mechanism model for training and modeling;

[0011] Step 5, model verification: call the input feature data of the verification data set in the sample database, use the trained model to predict water quality, compare it with the output results in the verification data set, use mean square error, determination coefficient, and mean relative error to evaluate the model performance, and verify the reliability of the model until the model verification passes;

[0012] Step 6: Water quality prediction for water diversion projects: Input the input feature data of the water diversion project design scenario into the verified model to perform water quality prediction and obtain the water quality prediction result.

[0013] Furthermore, the terrain data described in step 1 refers to the "Hydrological Yearbook" and the "Preliminary Design Report"; the hydrological data along the line refers to the "Hydrological Yearbook"; the water quality indicators include COD and NH3-N, and the water quality monitoring section can be a national control assessment section; the remaining data refers to relevant pollution control plans and feasibility study reports.

[0014] Furthermore, the process of determining the river channel roughness in step 2 is to first refer to the roughness table of natural river channels in the "Hydraulic Calculation Manual" for preliminary value determination, and after calibration and verification of the model, finally obtain the calibration result of the river channel roughness; the process of determining the degradation coefficient of each water quality index is to first refer to the degradation coefficient of each water quality index of the river channel in the literature for preliminary value determination, and after calibration and verification of the model, finally obtain the value of the degradation coefficient of each water quality index along the river channel.

[0015] Furthermore, the specific process of forming the sample database in step 3 is as follows:

[0016] Step 31. According to the design scenario of the water diversion project and the water demand of the area, the upstream flow range calculated by the mechanism water quality prediction model is set. The upstream flow in the possible water diversion scenario is linearly interpolated within this range, and the conventional scenario of the implementation of the water diversion plan is covered. Since the water diversion volume in the design scenario of the water diversion project is a ten-day flow, each flow value after interpolation is also simulated for 10 consecutive days to obtain a daily flow. The water intake takes a fixed value, and the flow through the gate is the sum of the upstream flow and the source and sink flow. The sewage outlets and tributaries into the river are not subject to artificial regulation and are assumed to remain unchanged before and after the operation of the water diversion project.

[0017] Step 32: according to the minimum water quality concentration in the actual historical water quality data and the water quality requirements for water transfer, the upstream water quality concentration range calculated by the mechanism water quality prediction model is set, and the upstream water quality concentration in the possible water transfer scenario is linearly interpolated within this range to cover the water quality concentration of the upstream water quality control section;

[0018] Step 33: According to the possible water transfer scenario, the mechanism water quality prediction model simulates the water quality concentration data after interpolation as the upstream water quality under the same hydrodynamic conditions;

[0019] Step 34. After the calculation of the mechanism water quality prediction model is completed, the daily water quality data of a section along the water diversion project is output, and the water quality simulation result corresponding to each upstream water diversion volume reaching the section is selected as the final water quality output result, together with the corresponding input characteristics, namely upstream flow, water intake, gate flow and upstream water quality, as samples to form a sample database.

[0020] Furthermore, the specific process of using WOA to optimize parameters and train modeling in step 4 is as follows:

[0021] Step 41, calling the sample database: 80% of the data in the sample database are selected as training data sets, and 20% of the data are selected as verification data sets, and the data are normalized;

[0022] Step 42, initializing WOA parameters: setting the population size, maximum number of iterations, dimension, upper and lower boundaries of the parameters to be optimized in WOA;

[0023] Step 43, initialize the whale position and find the current global optimal position: initialize the position of each whale in the population, calculate the fitness value of each individual whale, and compare the sizes, select the whale position corresponding to the smallest fitness value as the optimal position in the current population, and save its corresponding position vector, that is, the parameter combination (C, ε, σ);

[0024] Step 44, iteration and search for the current global optimal position: perform the next iteration, use the spiral update, shrinkage and random search mechanism of WOA to update the whale position, and determine whether its position is within the boundary range. If it is beyond, randomly generate a new position; bring the updated whale position into the fitness calculation, compare the calculation result with the fitness value of the optimal position of other iterations, and select the whale position corresponding to the minimum fitness value as the current global optimal position;

[0025] Step 45, determine whether the maximum number of iterations has been reached: if the maximum number of iterations has been reached, stop the iteration, and output the whale position and the corresponding parameter combination (C, ε, σ) at this time, which is the global optimal position and parameter combination; otherwise, add 1 to the number of iterations and jump to step 44 to update the optimal position until the condition is met;

[0026] Step 46: Training and modeling: The optimal hyperparameters output by WOA are brought into the model for training and modeling.

[0027] Furthermore, the fitness value is calculated as follows: in the parameter optimization process, a determination coefficient is calculated for comparing the prediction result with the output result in the training data set, and the value of 1 minus the determination coefficient is used as the fitness value in the whale optimization algorithm.

[0028] Furthermore, during the model verification process described in step 5, if the verification fails, return to step 42, increase the population size and the maximum number of iterations, and if the verification still fails, return to step 3, increase the interpolation density of the upstream flow and water quality concentration, and re-interpolate until the model verification passes.

[0029] The beneficial effects of the present invention are as follows: the method of the present invention constructs a mechanism water quality prediction model based on existing relevant hydrological, water quality and other information, and uses it to simulate the river water quality response process under possible water diversion scenarios, thereby constructing a sample database, and then constructing an SVR coupling mechanism model to predict water quality. The method of the present invention takes into account the influence of water quality and flow rate at the same time, and can quickly and accurately realize the water quality prediction of the river along the water diversion project, with short time consumption and high efficiency, and effectively solves the problem of poor prediction performance due to insufficient sample data. It has strong practicality and provides a scientific basis for the rational formulation of water diversion plans.

[0030] The present invention will be further described in detail below in conjunction with the accompanying drawings and specific implementation methods. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 Input and output characteristic block diagram of SVR coupling mechanism model;

[0032] Figure 2 Schematic diagram of the SVR coupling mechanism model construction process. DETAILED DESCRIPTION

[0033] The present invention discloses a water quality prediction method for water diversion projects based on an SVR coupling mechanism model. Figure 1 , Figure 2 As shown, the method comprises the following steps:

[0034] Step 1. Collect basic data along the water diversion project: Collect and organize basic data along the water diversion project, including topographic data, hydrological data along the line, water quality data along the line, outflow data of sewage outlets, tributaries, and water intakes along the line, gate structure parameters, etc. Among them, topographic data can refer to the "Hydrological Yearbook" and "Preliminary Design Report"; hydrological data along the line include daily water level and flow data of hydrological stations along the line or daily water level data of water level stations, which can refer to the "Hydrological Yearbook"; water quality data along the line include daily concentrations of various water quality indicators, water quality indicators include COD, NH3-N and other commonly used water quality indicators, and water quality monitoring sections can be national control assessment sections; other data can refer to relevant pollution control plans and feasibility study reports.

[0035] Step 2. Construct a mechanism water quality prediction model: Based on the basic data collected along the water diversion project, a mechanism water quality prediction model for the river along the water diversion project is constructed, including a hydrodynamic module and a water quality module. The upstream hydrodynamic boundary is the daily flow data at the hydrological station, the downstream hydrodynamic boundary is the daily water level data at the hydrological station or water level station, and the upstream water quality boundary is the daily concentration of each water quality indicator. The gate adopts flow control, and considers the water balance of the model, and the outflow from the sewage outlet, tributaries, and water intake into the river are all regarded as source and sink items.

[0036] The mechanism water quality prediction model is calibrated and verified to determine the roughness of the river channel and the degradation coefficients of various water quality indicators. For the hydrodynamic module of the model, the parameters that need to be calibrated are mainly the roughness n. Generally, the method of first taking empirical values ​​and then calibrating the model is adopted, that is, first refer to the roughness table of natural river channels in the "Hydraulic Calculation Manual" for preliminary values, and after calibration and verification of the model, the calibration results of the river channel roughness are finally obtained. For the water quality module of the model, the parameters that need to be calibrated are mainly the degradation coefficients of various water quality indicators. First, refer to the degradation coefficients of various water quality indicators of the river channel in the literature for preliminary values, and after calibration and verification of the model, the values ​​of the degradation coefficients of various water quality indicators along the river channel are finally obtained.

[0037] Step 3: Construct a sample database: Determine the upstream flow, water intake, flow through the gate, and upstream water quality of the water diversion project, and interpolate to obtain possible water diversion scenarios. Use the constructed mechanism water quality prediction model to simulate, extract daily water quality data of a section and determine the final output result of water quality, and form a sample database together with the corresponding upstream flow, water intake, flow through the gate, and upstream water quality.

[0038] The specific process of forming a sample database includes the following steps:

[0039] Step 31. According to the design scenario of the water diversion project and the water demand of the area, set the upstream flow range calculated by the mechanism water quality prediction model. The upstream flow in the possible water diversion scenario is linearly interpolated within this range, and the conventional scenario of the implementation of the water diversion plan is covered as much as possible. Since the water diversion volume in the design scenario of the water diversion project is a ten-day flow, each interpolated flow value is also simulated for 10 consecutive days to obtain a daily flow. The water intake is fixed. The flow through the gate is the sum of the upstream flow and the source and sink flow. The sewage outlets and tributaries into the river are not subject to artificial regulation and are assumed to remain unchanged before and after the operation of the water diversion project.

[0040] Step 32: According to the minimum water quality concentration in the actual historical water quality data and the water quality requirements for water transfer, set the upstream water quality concentration range calculated by the mechanism water quality prediction model. The water quality requirements for water transfer are generally based on the "Surface Water Environmental Quality Standard" (GB3838-2002) and related plans. The upstream water quality concentration in the possible water transfer scenario is linearly interpolated within this range to cover the common water quality concentrations in the upstream water quality control section as much as possible.

[0041] Step 33: Based on the possible water diversion scenarios, the mechanism water quality prediction model simulates the upstream water quality using the interpolated water quality concentration data under the same hydrodynamic conditions.

[0042] Step 34. After the calculation of the mechanism water quality prediction model is completed, the daily water quality data of a section along the water diversion project is output, and the corresponding water quality simulation result when each upstream water diversion volume reaches the section is selected as the final water quality output result, together with the corresponding input characteristics (upstream flow, water intake, gate flow and upstream water quality) as samples to form a sample database.

[0043] Step 4. Construct the SVR coupling mechanism model: The construction of the SVR coupling mechanism model includes the steps of selecting the kernel function, calling the sample database, and selecting the optimization algorithm for parameter optimization. Among them, the radial basis kernel function (RBF) is selected as the kernel function of the model. According to the actual situation of the water diversion project, the model uses multiple features to predict a water quality index. For the SVR coupling mechanism model, the hyperparameters that need to be input are the penalty coefficient C, the insensitive loss coefficient ε, and the kernel function parameter σ. The whale optimization algorithm (WOA) is used to optimize its parameters. During the parameter optimization process, the determination coefficient of the comparison between the predicted results and the output results in the training data set is calculated, and the value of 1 minus the determination coefficient is used as the fitness value calculated in the whale optimization algorithm.

[0044] The SVR coupling mechanism model construction process is as follows Figure 2 As shown in the figure, 80% of the data in the sample database is used as the training data set, and 20% is used as the validation data set. The training data set in the sample database is called, and the daily upstream flow, water intake, gate flow, and upstream water quality are used as input features, and the predicted daily water quality data of the sections along the line are used as output results. In the process of finding the optimal hyperparameters, these three hyperparameters are used as the position vectors (C, ε, σ) in WOA, and the hyperparameters are optimized through continuous iterative updates of WOA until the global optimal position is found, that is, the position vector with the lowest fitness value is found, and it is used as the final hyperparameter of the SVR coupling mechanism model, and trained and modeled.

[0045] The specific process of using WOA to optimize parameters and train modeling is as follows:

[0046] Step 41, calling the sample database: calling the sample database, optionally selecting 80% of the data in the sample database as the training data set and 20% of the data as the verification data set, and normalizing the data.

[0047] Step 42, initialize WOA parameters: set the population size, maximum number of iterations, dimension (number of parameters to be optimized), upper and lower boundaries of the parameters to be optimized in WOA.

[0048] Step 43, initialize the whale position and find the current global optimal position: initialize the position of each whale in the population, calculate the fitness value of each individual whale, and compare the sizes, select the whale position corresponding to the smallest fitness value as the optimal position in the current population, and save its corresponding position vector, that is, the parameter combination (C, ε, σ).

[0049] Step 44, iteration and search for the current global optimal position: perform the next iteration, use the spiral update, shrinkage and random search mechanism of WOA to update the whale position, and determine whether its position is within the boundary range. If it is beyond, randomly generate a new position. Bring the updated whale position into the fitness calculation, compare the calculation result with the fitness value of the optimal position of other iterations, and select the whale position corresponding to the minimum fitness value as the current global optimal position.

[0050] Step 45, determine whether the maximum number of iterations has been reached: if the maximum number of iterations has been reached, stop the iteration, and output the whale position and the corresponding parameter combination (C, ε, σ) at this time, which is the global optimal position and parameter combination; otherwise, add 1 to the number of iterations and jump to step 44 to update the optimal position until the conditions are met.

[0051] Step 46: Training and modeling: The optimal hyperparameters output by WOA are brought into the model for training and modeling.

[0052] Step 5, model verification: call the input feature data of the verification data set in the sample database, use the trained SVR coupling mechanism model to predict water quality, compare with the output results in the verification data set, use mean square error, determination coefficient, and average relative error to evaluate model performance and verify the reliability of the model. If the verification fails, return to step 42, increase the population size and the maximum number of iterations. If the verification still fails, consider returning to step 3, increase the interpolation density of upstream flow and water quality concentration, and re-interpolate until the model verification passes.

[0053] Step 6, water quality prediction of water diversion project: call the input feature data of the water diversion project design scenario, input the input feature data of the water diversion project design scenario into the verified model to perform water quality prediction, and obtain the water quality prediction result.

[0054] Finally, it should be noted that the above is only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred arrangement scheme, a person skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention.

Claims

1. A water quality prediction method for water diversion projects based on the SVR coupling mechanism model, characterized in that: The method comprises the following steps: Step 1, collecting basic data along the water diversion project: collecting and arranging basic data along the water diversion project, including topographic data, hydrological data along the line, water quality data along the line, outflow data of sewage outlets, tributaries, and water intakes along the line, and gate structure parameters; the hydrological data along the line include daily water level and flow data of hydrological stations along the line or daily water level data of water level stations, and the water quality data along the line include daily concentrations of various water quality indicators; Step 2, construct a mechanism water quality prediction model: Based on the basic data collected along the water diversion project, a mechanism water quality prediction model for the river along the water diversion project is constructed, including a hydrodynamic module and a water quality module, wherein the upstream hydrodynamic boundary is the daily flow data at the hydrological station, the downstream hydrodynamic boundary is the daily water level data at the hydrological station or water level station, and the upstream water quality boundary is the daily concentration of each water quality index. The gate adopts flow control, and the water balance of the model is considered, and the outflow of the sewage outlet, tributary, and water intake into the river are all taken as source and sink items; the mechanism water quality prediction model is calibrated and verified to determine the river roughness and the degradation coefficient of each water quality index; Step 3, build a sample database: determine the upstream flow, water intake, flow through the gate, and upstream water quality of the water diversion project, perform interpolation, and obtain possible water diversion scenarios; use the constructed mechanism water quality prediction model to simulate, extract daily water quality data of a section and determine the final output result of water quality, and form a sample database together with the corresponding upstream flow, water intake, flow through the gate, and upstream water quality; Step 4, constructing the SVR coupling mechanism model: The construction of the SVR coupling mechanism model includes the steps of selecting a kernel function, calling a sample database, and selecting an optimization algorithm for parameter optimization, wherein the radial basis kernel function is selected as the kernel function of the model; calling the data in the sample database as the training data set and the verification data set, taking the upstream flow, water intake, gate flow, and upstream water quality as input features, and taking the predicted cross-section water quality data as the output result; using the whale optimization algorithm for parameter optimization, the hyperparameters required to be input into the SVR coupling mechanism model include the penalty coefficient C, the insensitive loss coefficient ε, and the kernel function parameter σ, and optimizing the hyperparameters through iterative updating of the whale optimization algorithm until the optimal hyperparameters are output, and substituted into the SVR coupling mechanism model for training and modeling; Step 5, model verification: call the input feature data of the verification data set in the sample database, use the trained model to predict water quality, compare it with the output results in the verification data set, use mean square error, determination coefficient, and mean relative error to evaluate the model performance, and verify the reliability of the model until the model verification passes; Step 6: Water quality prediction for water diversion project: Input the input characteristic data of the water diversion project design scenario into the verified model to perform water quality prediction and obtain the water quality prediction result.

2. According to claim 1, a water quality prediction method for water diversion projects based on the SVR coupling mechanism model is characterized in that: The terrain data described in step 1 refer to the "Hydrological Yearbook" and "Preliminary Design Report"; the hydrological data along the line refer to the "Hydrological Yearbook"; the water quality indicators include COD and NH3-N, and the water quality monitoring section is the national control assessment section; the remaining data refer to relevant pollution control plans and feasibility study reports.

3. The water quality prediction method for water diversion projects based on the SVR coupling mechanism model according to claim 1 is characterized in that: The process of determining the roughness of the river channel described in step 2 is to first refer to the roughness table of natural river channels in the "Hydraulic Calculation Manual" for preliminary value determination, and after calibration and verification of the model, finally obtain the calibration result of the river channel roughness; the process of determining the degradation coefficient of each water quality index is to first refer to the degradation coefficient of each water quality index of the river channel in the literature for preliminary value determination, and after calibration and verification of the model, finally obtain the value of the degradation coefficient of each water quality index along the river channel.

4. The water quality prediction method for water diversion projects based on the SVR coupling mechanism model according to claim 1 is characterized in that: The specific process of forming the sample database described in step 3 is: Step 31. According to the design scenario of the water diversion project and the water demand of the area, the upstream flow range calculated by the mechanism water quality prediction model is set. The upstream flow in the possible water diversion scenario is linearly interpolated within this range, and the conventional scenario of the implementation of the water diversion plan is covered. Since the water diversion volume in the design scenario of the water diversion project is a ten-day flow, each flow value after interpolation is also simulated for 10 consecutive days to obtain a daily flow. The water intake takes a fixed value, and the flow through the gate is the sum of the upstream flow and the source and sink flow. The sewage outlets and tributaries into the river are not subject to artificial regulation and are assumed to remain unchanged before and after the operation of the water diversion project. Step 32: according to the minimum water quality concentration in the actual historical water quality data and the water quality requirements for water transfer, the upstream water quality concentration range calculated by the mechanism water quality prediction model is set, and the upstream water quality concentration in the possible water transfer scenario is linearly interpolated within this range to cover the water quality concentration of the upstream water quality control section; Step 33: According to the possible water transfer scenario, the mechanism water quality prediction model simulates the water quality concentration data after interpolation as the upstream water quality under the same hydrodynamic conditions; Step 34. After the calculation of the mechanism water quality prediction model is completed, the daily water quality data of a section along the water diversion project is output, and the water quality simulation result corresponding to each upstream water diversion volume reaching the section is selected as the final water quality output result, together with the corresponding input characteristics, namely upstream flow, water intake, gate flow and upstream water quality, as samples to form a sample database.

5. The water quality prediction method for water diversion projects based on the SVR coupling mechanism model according to claim 1 is characterized in that: The specific process of using the whale optimization algorithm (WOA) to optimize parameters and train modeling in step 4 is as follows: Step 41, calling the sample database: 80% of the data in the sample database are selected as training data sets, and 20% of the data are selected as verification data sets, and the data are normalized; Step 42, initializing WOA parameters: setting the population size, maximum number of iterations, dimension, upper and lower boundaries of the parameters to be optimized in WOA; Step 43, initialize the whale position and find the current global optimal position: initialize the position of each whale in the population, calculate the fitness value of each individual whale, and compare the sizes, select the whale position corresponding to the smallest fitness value as the optimal position in the current population, and save its corresponding position vector, that is, the parameter combination (C, ε, σ); Step 44, iteration and search for the current global optimal position: perform the next iteration, use the spiral update, shrinkage and random search mechanism of WOA to update the whale position, and determine whether its position is within the boundary range. If it is beyond, randomly generate a new position; bring the updated whale position into the fitness calculation, compare the calculation result with the fitness value of the optimal position of other iterations, and select the whale position corresponding to the minimum fitness value as the current global optimal position; Step 45, determine whether the maximum number of iterations has been reached: if the maximum number of iterations has been reached, stop the iteration, and output the whale position and the corresponding parameter combination (C, ε, σ) at this time, which is the global optimal position and parameter combination; otherwise, add 1 to the number of iterations and jump to step 44 to update the optimal position until the condition is met; Step 46: Training and modeling: The optimal hyperparameters output by WOA are brought into the model for training and modeling.

6. The water quality prediction method for water diversion projects based on the SVR coupling mechanism model according to claim 5 is characterized in that: The fitness value is calculated as follows: in the parameter optimization process, the determination coefficient of the comparison between the prediction result and the output result in the training data set is calculated, and the value of 1 minus the determination coefficient is used as the fitness value in the whale optimization algorithm.

7. The method for predicting water quality of water diversion projects based on the SVR coupling mechanism model according to claim 5 is characterized in that: During the model verification process described in step 5, if the verification fails, return to step 42, increase the population size and the maximum number of iterations, and if the verification still fails, return to step 3, increase the interpolation density of the upstream flow and water quality concentration, and re-interpolate until the model verification passes.

Citation Information

Patent Citations

  • Ecological compensation standard measuring and calculating method for networked water transfer

    CN112241850A

  • Earth and rockfill dam operation period settlement deformation prediction method based on improved WOA-SVR

    CN113313308A