Online prediction method of groundwater pollution in industrial parks based on machine learning model
By building an automatic online monitoring station for groundwater water quality and level in industrial parks and using machine learning models to predict groundwater pollution, the problems of low data utilization and slow calculation speed in the existing technology are solved, and real-time and accurate prediction of groundwater pollutant concentrations in industrial parks are achieved.
Patent Information
- Application Number
- CN202310373799.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-10
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2043-04-10
AI Technical Summary
In the spatial prediction of groundwater pollution in the prior art, the data utilization rate is low, the calculation speed is slow, and the traditional solute migration model has high parameters requirements, making it difficult to ensure prediction accuracy and speed.
The online prediction method of groundwater pollution in industrial parks based on machine learning models is adopted. By building an automatic online monitoring station for groundwater quality and level in industrial parks, the online update of modeling data is realized, and a real-time update groundwater pollution prediction model is built, combined with multiple types of models, and the optimal combination model is selected for prediction.
Real-time prediction of future groundwater pollutant concentrations in the entire industrial park is achieved, the cost of building monitoring stations is reduced, the prediction accuracy and speed is improved, and the problem of high parameters requirements of traditional methods is solved.
Smart Images

Figure CN116579128B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of groundwater pollution prediction, and in particular to an online prediction method for groundwater pollution in an industrial park based on a machine learning model. Background Art
[0002] As a supplementary resource for surface water in special periods, groundwater is of great significance to the development of the economy and society and the maintenance of the ecological environment. However, affected by industrial and agricultural activities, especially in chemical clusters in industrial parks, there may be illegal discharge of sewage and leakage of pipe networks, which may cause pollutants to enter groundwater through soil and rivers.
[0003] Limited by factors such as the porosity of the water-bearing medium, groundwater migration is slow and its self-purification ability is weak. Once discovered, it has often reached a relatively serious level. At present, both at home and abroad, attention has been gradually paid to groundwater monitoring, and monitoring wells have been built in key areas for manual monitoring or online monitoring. However, water quality monitoring data alone cannot meet the long-term supervision of groundwater pollution. Groundwater quality monitoring data should be fully utilized to predict future diffusion trends, so as to take measures to avoid more serious pollution.
[0004] The patent specification with publication number CN 114184750 A discloses a method for monitoring groundwater pollutants, including: obtaining groundwater from different areas; testing and processing the groundwater separately to obtain multiple water quality test data; analyzing and processing the water quality test data to obtain pollutant data; constructing a pollutant detection model based on the water quality test data and the pollutant data; inputting the pollutant data into the pollutant detection model for prediction to obtain pollutant prediction results; and monitoring the pollutants in the groundwater based on the pollutant prediction results.
[0005] The patent specification with publication number CN 115828704 A discloses a method for rapid prediction of groundwater pollution, including the following methods: step one, constructing a conceptual model; determining the size of the simulated area according to the topography, hydrogeology, and hydrogeochemical conditions of groundwater pollution; step two, selecting a mathematical model; selecting a water flow model, a solute transport model, a reaction model, a hydrodynamic-water quality coupling model, and a hydrodynamic-dispersion-reaction coupling model according to the concepts of a one-dimensional mathematical model, a two-dimensional mathematical model, and a three-dimensional mathematical model; step three, digitizing the mathematical model; converting a mathematical model that cannot be solved by an analytical solution into a solvable numerical model using a finite element method or a finite difference method; step four, prediction and sensitivity analysis; making predictions using corrected parameter values; and step five, compiling an executable program.
[0006] At present, the spatial prediction methods for groundwater pollution at home and abroad mostly use traditional solute transport models. However, this type of method has low data utilization, high requirements on the parameters of solutes and water-containing media, slow calculation speed, and the prediction accuracy and speed cannot be guaranteed. There are also a few studies that apply machine learning models to groundwater pollution prediction, but most of them are single models, and rarely implement model combination and online updating, and the continuity of the model cannot be guaranteed. Summary of the invention
[0007] The present invention provides an online prediction method for groundwater pollution in industrial parks based on a machine learning model. By constructing an automatic online monitoring station for groundwater quality and water level in the industrial park, the modeling data can be updated online, thereby realizing the online update of the prediction model, and finally realizing the prediction of the future groundwater pollutant concentration in the entire industrial park, reducing the cost of building monitoring stations. In the modeling process, the model is adaptively improved to address the delay and lag in the response of groundwater pollutants. According to the prediction time and prediction point, the input data will change adaptively. Multiple types of models are combined, and the optimal combination model is selected as the default model through model training and verification. At the same time, different combination methods are supported to avoid the one-sidedness of the prediction results of a single model, and the problem of high parameter requirements of traditional diffusion models is solved.
[0008] An online prediction method for groundwater pollution in industrial parks based on machine learning models, including:
[0009] Step 1: Collect basic information and stratum data of the industrial park, establish a groundwater online monitoring station network in the industrial park, and obtain real-time online monitoring data of groundwater level and water quality;
[0010] Step 2: Based on the stratigraphic exploration drilling data, hydrogeological parameters, and groundwater level data of the industrial park, the industrial park is divided into regional grids to build an online groundwater flow model that can be updated in real time, providing online data support for steps 3 and 4.
[0011] Step 3: Construct a relative spatial coordinate system and obtain the basic modeling data of regional grid points. The required data is divided into the following four categories:
[0012] Grid point fixed data, including lithology and coordinates;
[0013] Online monitoring data of groundwater quality, including the types and concentrations of pollutants monitored and the corresponding monitoring time points;
[0014] Use the online water flow model to obtain the flow field data of each grid point, including flow direction, flow velocity, and water level;
[0015] Enterprise pollution information, including the location, area, types of pollutants emitted, and annual output of pollutants of enterprises in the surrounding area;
[0016] Based on the above data, the machine learning regression model in the machine learning library is used to select the optimal model combination through model training and verification, and a groundwater pollution prediction model that can be updated in real time is constructed by updating the basic modeling data;
[0017] Step 4: Implement online prediction for grids in the industrial park that have not undergone water quality monitoring. By obtaining the four types of data in step 3, using the trained and verified machine learning regression model, setting the prediction time, and predicting the future pollutant concentration of each grid point.
[0018] In step one, the groundwater online monitoring station network includes water quality monitoring points and water level monitoring points; the water quality monitoring points are arranged using a grid distribution method, taking into account both monitoring key pollution areas and the principle of uniform distribution, ensuring that there is a monitoring well in every 10 grid points in step two.
[0019] In step one, the basic information and stratigraphic data of the industrial park include the boundary range of the industrial park, the boundaries of enterprises within the park, the types of pollutants emitted by enterprises, the annual emissions of various types of pollutants by each enterprise, the distribution of rivers in the park, stratigraphic exploration drilling data, hydrogeological parameters, precipitation recharge parameters and land use conditions.
[0020] In step 2, the construction of an online groundwater flow model that can be updated in real time specifically includes the following steps:
[0021] S21. Constructing a hydrogeological conceptual model: Based on the stratigraphic exploration drilling data and hydrogeological parameters of the industrial park, analyze the three-dimensional spatial distribution of the aquifer and the lithological characteristics of the water-bearing medium, and establish a three-dimensional geological model of the industrial park; combine the hydrological data in the industrial park and the characteristics of the regional groundwater flow field to determine the groundwater recharge, runoff, and discharge characteristics, and combine field tests to preliminarily obtain key hydraulic parameters including rainfall infiltration coefficient and water supply degree, and construct a hydrogeological conceptual model;
[0022] S22. Model initial condition setting: For the state of groundwater flow field, a stable state within the industrial park that is not significantly affected by external stress terms is selected;
[0023] S23, model boundary condition setting: determine the boundary conditions of the groundwater online flow model based on the hydrogeological conceptual model, and generalize the industrial park boundary into a first-class boundary with a given water head, a second-class boundary with a given lateral runoff, or a third-class boundary with a given relationship between lateral flow and water level;
[0024] S24, Model source and sink item settings: Groundwater flow source and sink items include groundwater exploitation, rainfall infiltration recharge, evaporation from the water table, and exchange with surface water bodies, which are set through Class II and Class III boundary conditions;
[0025] S25, model parameter setting: groundwater online flow model parameters include permeability coefficient, water storage coefficient, water supply degree, porosity, dispersion and chemical reaction parameters;
[0026] S26, Model space discretization: Grid the simulation space of the industrial park using rectangular grids. The grid division accuracy depends on the area of the region and the number of monitoring well grids. The number of modeling grids is 10 times the number of monitoring well grids.
[0027] S27. Model calibration and verification: The model is calibrated according to the measured groundwater level elevation. By adjusting the parameter values, the model calculation values and the field observation values meet certain accuracy requirements, which basically characterize the changing characteristics of the groundwater flow field. The calibration result evaluation satisfies the similarity between the simulated flow field and the observed flow field morphology, requiring that the fitting error between the actual observed value of the groundwater level in the observation well and the simulated calculation value is less than 10% of the water level change range during the simulation period.
[0028] Due to the construction of an automatic groundwater level monitoring station, after the groundwater level data is updated, the water flow model can be synchronously updated according to the latest water level data and recalculate the flow velocity, flow direction and water level of each grid point at the latest moment.
[0029] In step three, the specific implementation method of constructing a relative spatial coordinate system is: select any point within the modeling range of the industrial park as the coordinate origin, construct a relative rectangular coordinate system, with the 0° direction as the horizontal axis and the 90° direction as the vertical axis, and convert the spatial longitude and latitude coordinates of each point into relative distance coordinates. After the conversion, the coordinates (x, y) of a certain point indicate that the point is x meters east of the origin and y meters north of the origin.
[0030] In step 3, considering that groundwater is a transmission medium, compared with environmental factors such as surface water and atmosphere, when pollutants leak, the transport rate of pollutants in groundwater is much slower. Therefore, when constructing the machine learning groundwater pollution prediction model that can be updated in real time, the hysteresis effect of the time factor is considered. The specific method is as follows:
[0031] Set the time range, combine the data of all monitoring wells in different periods, and determine the best input data date combination for each target point through correlation analysis;
[0032] The target monitoring well is denoted as M. In addition to the target monitoring well, there are N other monitoring wells, which are denoted as J1, J2, J3, ..., J N , the pollutant concentration at the target monitoring well at time T is M TThe earliest monitoring date of all monitoring wells is TL, and the historical monitoring data of pollutant concentration in monitoring well J1 is {J 1,T -L, ..., J 1,T-3 , J 1,T-2 , J 1,T-1}, the historical monitoring data of pollutant concentration in monitoring well J2 is {J 1,T-L , ..., J 2,T-3 , J 2,T-2 , J 2,T-1}, ..., monitoring well J N The historical monitoring data of pollutant concentration is {J N,T-L , ..., J N,T-3 , J N,T-2 , J N,T-1}; Use the historical monitoring data of other monitoring wells as the input of the model, M T As the output of the model, M T Combined with the data from other monitoring wells at different times to form an array [J 1,T1 , J 2,T2 , J 3,T3 ,……,J N,TN , M T ], where T1~TN can be independently selected from [T-1, T-2, T-3, ..., TL]. According to this rule, the final data combination is L N For each monitoring well, T A correlation analysis is performed with the historical monitoring data of other monitoring wells, and the Spearman correlation coefficient is calculated. The higher the correlation coefficient, the better the data correlation corresponding to the corresponding time combination. The combination with the largest correlation coefficient is selected as the optimal date combination, thereby constructing the relationship between the pollutant concentration at any moment in the target monitoring well and the historical monitoring data under the optimal date combination of other monitoring wells. Based on this, the pollution situation of the target monitoring well at a certain moment in the future can be accurately predicted, thereby achieving the purpose of early warning.
[0033] If the traditional sample combination method is used, that is, the same date is selected for the input data of each site, it may cause data redundancy and noise.
[0034] The specific implementation process of constructing the groundwater pollution prediction model that can be updated in real time is as follows:
[0035] Select a machine learning model: Select a regression model suitable for multi-factor prediction in the hydrological field from the machine learning library, with at least 5 types of models;
[0036] Data preprocessing: Discrete category information including lithology is converted into numerical data through one-hot encoding. The data of different elements have extreme values and more noise. Centralization is used to avoid the influence of outliers and extreme values, reduce errors, and speed up model training.
[0037] Establishing a data set: The construction of the model requires the input of a data set, including characteristic value X and target value Y. The target value Y represents the concentration of a specific pollutant at a grid point at a specific time, and the characteristic value X represents the multidimensional factor that affects the value of Y.
[0038] Sample segmentation: divide the data sets X and Y into training samples Xtr, Ytr, verification samples Xve, Yve and test samples Xte, Yte; the training samples are used for the model to learn the rules of historical data; the verification samples are used to adjust parameters and select the optimal model; the test samples are used to evaluate the prediction performance of the model; both the training samples and the verification samples participate in the construction of the model, while the test samples are brand new data for the model;
[0039] Combination model: For a single machine learning regression model of type R, R ≥ 5, the combination methods include selecting a combination model of 2, 3, …, R types, and R single models;
[0040] Training model: Use the inverse variance weighting method to combine models. For each single model, set different parameter combinations. Under various parameter combinations and model combination conditions, input training samples Xtr and Ytr to train the combined model.
[0041] Model calibration: For each combination model, input the verification sample Xve into the trained model under each parameter combination, compare and analyze the model prediction result Ypre_ve with the observed value Yve, and select the corresponding parameter combination and model combination method with the smallest error. The corresponding combination model with the best fitting accuracy of the verification sample is used as the default model for online prediction;
[0042] Model testing: Input the test sample Xte into the model selected by the verification sample to obtain the predicted value Ypre_te, and perform error analysis on Ypre_te and the observed value Yte to verify the accuracy of the model.
[0043] Based on the online water level monitoring data and water quality monitoring data, the modeling data can be updated, data from different time ranges can be selected, and the model can be retrained and verified to update the prediction model.
[0044] In step 4, for the grid points where monitoring wells have been built, the online prediction process of groundwater pollutant concentration includes the following steps:
[0045] ① The groundwater monitoring station automatically samples and conducts water quality analysis;
[0046] ② After the latest water quality data is generated, the prediction process is automatically triggered, the groundwater pollution prediction model that can be updated in real time constructed in step 3 is called, and the default prediction time is set;
[0047] ③ Retrieve the coordinate data, flow field data, lithology data, and enterprise pollution information data of all grid points, and also retrieve the online water quality monitoring data of the automatic monitoring station;
[0048] ④Perform data processing and sample reconstruction according to step 3 to obtain the eigenvalue X;
[0049] ⑤ Take the characteristic value X as input data and use the groundwater pollution prediction model that can be updated in real time constructed in step 3 to predict the concentration values of different pollutants at each grid point in the future;
[0050] Based on the predicted values of pollutant concentrations at the grid points of the built monitoring wells, Kriging interpolation is performed to calculate the pollutant concentrations at the grid points where the monitoring wells are not built.
[0051] Step 4 is the online prediction process for groundwater pollutant concentration. It supports the selection of multiple single models for combination, and the comparison of the prediction results of different model combinations. It also supports the selection of different prediction durations and the output of pollutant distribution in the park at different times in the future.
[0052] The online prediction method for groundwater pollution in industrial parks based on the machine learning model also includes:
[0053] Step 5: Visualize the spatial distribution map of pollution prediction results at the same time and the pollutant change trend map at the same point; for the prediction results at different points at the same time, use colors to distinguish different concentration differences; for the prediction results at the same point at different times, use a line graph to present the point pollutant concentration change trend, thereby visualizing the pollutant prediction results.
[0054] The prediction result visualization described in step 5 can use different color scales to distinguish the concentration range and render the distribution of a pollution indicator in the future industrial park. In addition, if you want to achieve dynamic effects, you can choose different prediction steps to predict the global pollution situation at different times. The system supports automatic playback of the pollution concentration distribution of different nodes, so as to intuitively visualize the pollutant diffusion trend of the park in the future.
[0055] Compared with the prior art, the present invention has the following beneficial effects:
[0056] The method of the present invention makes full use of the groundwater monitoring data of the industrial park to predict the groundwater pollution diffusion status of the industrial park in real time. In addition, the method of the present invention takes into account the transmission medium of groundwater. Compared with environmental factors such as surface water and atmosphere, when pollutants leak, the transport rate of pollutants in groundwater is much slower. Therefore, the hysteresis effect needs to be considered when constructing the prediction model, and adaptive improvements should be made to this. For a point, if the pollutant concentration of the target point is to be predicted, the input data is the historical data of other monitoring wells, but because the relative spatial position of each monitoring well and the target point is different, the molecular diffusion speed at each point in space is different, so the target point is affected by the other monitoring wells. There are differences, and the target point is affected by the monitoring data of the same monitoring well at different periods. There are also differences. Therefore, in the selection process of input data, adaptive improvements should be made to take time factors into consideration. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] Figure 1 The figure is a flow chart of an online prediction method for groundwater pollution in an industrial park based on a machine learning model in a specific implementation manner. DETAILED DESCRIPTION
[0058] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments. It should be understood that these embodiments are only used to illustrate the present invention and are not used to limit the scope of the present invention.
[0059] like Figure 1 As shown, an online prediction method for groundwater pollution in industrial parks based on a machine learning model includes:
[0060] Step 1: Collect basic information and stratigraphic data of the industrial park, establish a network of online groundwater monitoring stations in the industrial park, and obtain real-time online groundwater level monitoring data and water quality online monitoring data.
[0061] The groundwater online monitoring station network includes water quality monitoring points and water level monitoring points; the water quality monitoring points are arranged using a grid distribution method, taking into account both monitoring key pollution areas and the principle of uniform distribution, ensuring that there is a monitoring well for every 10 grid points in step two.
[0062] The basic information and stratigraphic data of the industrial park include the boundary range of the industrial park, the boundaries of enterprises within the park, the types of pollutants emitted by enterprises, the annual emissions of various types of pollutants by each enterprise, the distribution of rivers in the park, stratigraphic exploration drilling data, hydrogeological parameters, precipitation recharge parameters and land use conditions.
[0063] Step 2: Based on the stratigraphic exploration drilling data, hydrogeological parameters, and groundwater level data of the industrial park, the industrial park is divided into regional grids to build an online groundwater flow model that can be updated in real time, providing online data support for steps 3 and 4.
[0064] The construction of the groundwater online flow model that can be updated in real time specifically includes the following steps:
[0065] S21. Constructing a hydrogeological conceptual model: Based on the stratigraphic exploration drilling data and hydrogeological parameters of the industrial park, analyze the three-dimensional spatial distribution of the aquifer and the lithological characteristics of the water-bearing medium, and establish a three-dimensional geological model of the industrial park; combine the hydrological data in the industrial park and the characteristics of the regional groundwater flow field to determine the groundwater recharge, runoff, and discharge characteristics, and combine field tests to preliminarily obtain key hydraulic parameters including rainfall infiltration coefficient and water supply degree, and construct a hydrogeological conceptual model;
[0066] S22. Model initial condition setting: For the state of groundwater flow field, a stable state within the industrial park that is not significantly affected by external stress terms is selected;
[0067] S23, model boundary condition setting: determine the boundary conditions of the groundwater online flow model based on the hydrogeological conceptual model, and generalize the industrial park boundary into a first-class boundary with a given water head, a second-class boundary with a given lateral runoff, or a third-class boundary with a given relationship between lateral flow and water level;
[0068] S24, Model source and sink item settings: Groundwater flow source and sink items include groundwater exploitation, rainfall infiltration recharge, evaporation from the water table, and exchange with surface water bodies, which are set through Class II and Class III boundary conditions;
[0069] S25, model parameter setting: groundwater online flow model parameters include permeability coefficient, water storage coefficient, water supply degree, porosity, dispersion and chemical reaction parameters;
[0070] S26, Model space discretization: Grid the simulation space of the industrial park using rectangular grids. The grid division accuracy depends on the area of the region and the number of monitoring well grids. The number of modeling grids is 10 times the number of monitoring well grids.
[0071] S27. Model calibration and verification: The model is calibrated according to the measured groundwater level elevation. By adjusting the parameter values, the model calculation values and the field observation values meet certain accuracy requirements, which basically characterize the changing characteristics of the groundwater flow field. The calibration result evaluation satisfies the similarity between the simulated flow field and the observed flow field morphology, requiring that the fitting error between the actual observed value of the groundwater level in the observation well and the simulated calculation value is less than 10% of the water level change range during the simulation period.
[0072] Due to the construction of an automatic groundwater level monitoring station, after the groundwater level data is updated, the water flow model can be synchronously updated according to the latest water level data and recalculate the flow velocity, flow direction and water level of each grid point at the latest moment.
[0073] Step 3: Construct a relative spatial coordinate system and obtain the basic modeling data of regional grid points. The required data is divided into the following four categories:
[0074] Grid point fixed data, including lithology and coordinates;
[0075] Online monitoring data of groundwater quality, including the types and concentrations of pollutants monitored and the corresponding monitoring time points;
[0076] Use the online water flow model to obtain the flow field data of each grid point, including flow direction, flow velocity, and water level;
[0077] Enterprise pollution information, including the location, area, types of pollutants emitted, and annual output of pollutants of enterprises in the surrounding area;
[0078] Based on the above data, the machine learning regression model in the machine learning library is used to select the optimal model combination through model training and verification. By updating the basic modeling data, a groundwater pollution prediction model that can be updated in real time is constructed.
[0079] The specific implementation method of constructing the relative spatial coordinate system is: select any point within the modeling range of the industrial park as the coordinate origin, construct a relative rectangular coordinate system, with the 0° direction as the horizontal axis and the 90° direction as the vertical axis, and convert the spatial longitude and latitude coordinates of each point into relative distance coordinates. After the conversion, the coordinates (x, y) of a certain point indicate that the point is x meters east of the origin and y meters north of the origin.
[0080] Considering the transmission medium of groundwater, compared with environmental factors such as surface water and atmosphere, when pollutants leak, the transport rate of pollutants in groundwater is much slower. Therefore, the hysteresis effect of time factors is considered when constructing the machine learning groundwater pollution prediction model that can be updated in real time. The specific method is as follows:
[0081] Set the time range, combine the data of all monitoring wells in different periods, and determine the best input data date combination for each target point through correlation analysis;
[0082] The target monitoring well is denoted as M. In addition to the target monitoring well, there are N other monitoring wells, which are denoted as J1, J2, J3, ..., J N , the pollutant concentration at the target monitoring well at time T is M T The earliest monitoring date of all monitoring wells is TL, and the historical monitoring data of pollutant concentration in monitoring well J1 is {J 1,T-L , ..., J 1,T-3 , J 1,T-2 , J 1,T-1}, the historical monitoring data of pollutant concentration in monitoring well J2 is {J 1,T-L , ..., J 2,T-3 , J 2,T-2, J 2,T-1}, ..., monitoring well J N The historical monitoring data of pollutant concentration is {J N,T-L , ..., J N,T-3 , J N,T-2 , J N,T-1}; Use the historical monitoring data of other monitoring wells as the input of the model, M T As the output of the model, M T Combined with the data from other monitoring wells at different times to form an array [J 1,T1 , J 2,T2 , J 3,T3 ,……,J N,TN , M T ], where T1~TN can be independently selected from [T-1, T-2, T-3, ..., TL]. According to this rule, the final data combination is L N For each monitoring well, T A correlation analysis is performed with the historical monitoring data of other monitoring wells, and the Spearman correlation coefficient is calculated. The higher the correlation coefficient, the better the data correlation corresponding to the corresponding time combination. The combination with the largest correlation coefficient is selected as the optimal date combination, thereby constructing the relationship between the pollutant concentration at any moment in the target monitoring well and the historical monitoring data under the optimal date combination of other monitoring wells. Based on this, the pollution situation of the target monitoring well at a certain moment in the future can be accurately predicted, thereby achieving the purpose of early warning.
[0083] If the traditional sample combination method is used, that is, the same date is selected for the input data of each site, it may cause data redundancy and noise.
[0084] The specific implementation process of constructing the groundwater pollution prediction model that can be updated in real time is as follows:
[0085] Select a machine learning model: Select a regression model suitable for multi-factor prediction in the hydrological field from the machine learning library, with at least 5 types of models;
[0086] Data preprocessing: Discrete category information including lithology is converted into numerical data through one-hot encoding. The data of different elements have extreme values and more noise. Centralization is used to avoid the influence of outliers and extreme values, reduce errors, and speed up model training.
[0087] Establishing a data set: The construction of the model requires the input of a data set, including characteristic value X and target value Y. The target value Y represents the concentration of a specific pollutant at a grid point at a specific time, and the characteristic value X represents the multidimensional factor that affects the value of Y.
[0088] Sample segmentation: divide the data sets X and Y into training samples Xtr, Ytr, verification samples Xve, Yve and test samples Xte, Yte; the training samples are used for the model to learn the rules of historical data; the verification samples are used to adjust parameters and select the optimal model; the test samples are used to evaluate the prediction performance of the model; both the training samples and the verification samples participate in the construction of the model, while the test samples are brand new data for the model;
[0089] Combination model: For a single machine learning regression model of type R, R ≥ 5, the combination methods include selecting a combination model of 2, 3, …, R types, and R single models;
[0090] Training model: Use the inverse variance weighting method to combine models. For each single model, set different parameter combinations. Under various parameter combinations and model combination conditions, input training samples Xtr and Ytr to train the combined model.
[0091] Model calibration: For each combination model, input the verification sample Xve into the trained model under each parameter combination, compare and analyze the model prediction result Ypre_ve with the observed value Yve, and select the corresponding parameter combination and model combination method with the smallest error. The corresponding combination model with the best fitting accuracy of the verification sample is used as the default model for online prediction;
[0092] Model testing: Input the test sample Xte into the model selected by the verification sample to obtain the predicted value Ypre_te, and perform error analysis on Ypre_te and the observed value Yte to verify the accuracy of the model.
[0093] Based on the online water level monitoring data and water quality monitoring data, the modeling data can be updated, data from different time ranges can be selected, and the model can be retrained and verified to update the prediction model.
[0094] Step 4: Implement online prediction for grids in the industrial park that have not undergone water quality monitoring. By obtaining the four types of data in step 3, using the trained and verified machine learning regression model, setting the prediction time, and predicting the future pollutant concentration of each grid point.
[0095] For the grid points where monitoring wells have been built, the online prediction process of groundwater pollutant concentration includes the following steps:
[0096] ① The groundwater monitoring station automatically samples and conducts water quality analysis;
[0097] ② After the latest water quality data is generated, the prediction process is automatically triggered, the groundwater pollution prediction model that can be updated in real time constructed in step 3 is called, and the default prediction time is set;
[0098] ③ Retrieve the coordinate data, flow field data, lithology data, and enterprise pollution information data of all grid points, and also retrieve the online water quality monitoring data of the automatic monitoring station;
[0099] ④Perform data processing and sample reconstruction according to step 3 to obtain the eigenvalue X;
[0100] ⑤ Take the characteristic value X as input data and use the groundwater pollution prediction model that can be updated in real time constructed in step 3 to predict the concentration values of different pollutants at each grid point in the future;
[0101] Based on the predicted values of pollutant concentrations at the grid points of the built monitoring wells, Kriging interpolation is performed to calculate the pollutant concentrations at the grid points where the monitoring wells are not built.
[0102] Step 4 is the online prediction process for groundwater pollutant concentration. It supports the selection of multiple single models for combination, and the comparison of the prediction results of different model combinations. It also supports the selection of different prediction durations and the output of pollutant distribution in the park at different times in the future.
[0103] Step 5: Visualize the spatial distribution map of pollution prediction results at the same time and the pollutant change trend map at the same point; for the prediction results at different points at the same time, use colors to distinguish different concentration differences; for the prediction results at the same point at different times, use a line graph to present the point pollutant concentration change trend, thereby visualizing the pollutant prediction results.
[0104] The prediction result visualization described in step 5 can use different color scales to distinguish the concentration range and render the distribution of a pollution indicator in the future industrial park. In addition, if you want to achieve dynamic effects, you can choose different prediction steps to predict the global pollution situation at different times. The system supports automatic playback of the pollution concentration distribution of different nodes, so as to intuitively visualize the pollutant diffusion trend of the park in the future.
[0105] In addition, it should be understood that after reading the above description of the present invention, those skilled in the art may make various changes or modifications to the present invention, and these equivalent forms also fall within the scope defined by the claims attached to this application.
Claims
1. An online prediction method for groundwater pollution in industrial parks based on a machine learning model, characterized in that: include: Step 1: Collect basic information and stratum data of the industrial park, establish a groundwater online monitoring station network in the industrial park, and obtain real-time online monitoring data of groundwater level and water quality; Step 2: Based on the stratigraphic exploration drilling data, hydrogeological parameters, and groundwater level data of the industrial park, the industrial park is divided into regional grids to build an online groundwater flow model that can be updated in real time, providing online data support for steps 3 and 4. Step 3: Construct a relative spatial coordinate system and obtain the basic modeling data of the regional grid points. The required basic modeling data is divided into the following four categories: Grid point fixed data, including lithology and coordinates; Online monitoring data of groundwater quality, including the types and concentrations of pollutants monitored and the corresponding monitoring time points; Use the groundwater online flow model to obtain the flow field data of each grid point, including flow direction, flow velocity, and water level; Enterprise pollution information, including the location, area, types of pollutants emitted, and annual output of pollutants of enterprises in the surrounding area; Based on the above basic modeling data, the machine learning regression model in the machine learning library is used to select the optimal model combination through model training and verification. By updating the basic modeling data, a groundwater pollution prediction model that can be updated in real time is constructed. When constructing a machine learning groundwater pollution prediction model that can be updated in real time, the hysteresis effect of the time factor is considered. The specific method is as follows: Set the time range, combine the data of all monitoring wells in different periods, and determine the best input data date combination for each target point through correlation analysis; The target monitoring well is denoted as M. In addition to the target monitoring well, there are N other monitoring wells, which are denoted as J1, J2, J3, ..., J N , the pollutant concentration at the target monitoring well at time T is M T The earliest monitoring date of all monitoring wells is TL, and the historical monitoring data of pollutant concentration in monitoring well J1 is {J 1,T-L , ..., J 1,T-3 , J 1,T-2 , J 1,T-1 }, the historical monitoring data of pollutant concentration in monitoring well J2 is {J 1,T-L , ..., J 2,T-3 , J 2,T-2 , J 2,T-1 }, ..., monitoring well J N The historical monitoring data of pollutant concentration is {J N,T-L , ..., J N,T-3 , J N,T-2 , J N,T-1 }; Use the historical monitoring data of other monitoring wells as the input of the model, M T As the output of the model, M T Combined with the data from other monitoring wells at different times to form an array [J 1,T1 , J 2,T2 , J 3,T3 ,……,J N,TN , M T ], where T1~TN can be independently selected from [T-1, T-2, T-3, ..., TL]. According to this rule, the final data combination is L N For each monitoring well, T Carry out correlation analysis with historical monitoring data of other monitoring wells and calculate the Spearman correlation coefficient. The higher the correlation coefficient, the better the data correlation corresponding to the corresponding time combination. Select the combination with the largest correlation coefficient as the best input data date combination. The specific implementation process of constructing the groundwater pollution prediction model that can be updated in real time is as follows: Select a machine learning model: Select a regression model suitable for multi-factor prediction in the hydrological field from the machine learning library, with at least 5 types of models; Data preprocessing: discrete category information including lithology is converted into numerical data through one-hot encoding, and centralized processing is used to avoid the influence of outliers and extreme values, reduce errors, and speed up model training; Establishing a data set: The construction of the model requires the input of a data set, including characteristic value X and target value Y. The target value Y represents the concentration of a certain pollutant at a certain grid point at a certain time, and the characteristic value X represents the multidimensional factor that affects the value of Y. Sample segmentation: The data set is segmented into training samples Xtr, Ytr, verification samples Xve, Yve and test samples Xte, Yte; the training samples are used for the model to learn the rules of historical data; the verification samples are used to adjust parameters and select the optimal model; the test samples are used to evaluate the prediction performance of the model; both the training samples and the verification samples participate in the construction of the model, while the test samples are completely new data for the model; Combination model: For a single machine learning regression model of type R, R ≥ 5, the combination methods include selecting a combination model of 2, 3, …, R types, and R single models; Training model: Use the inverse variance weighting method to combine models. For each single model, set different parameter combinations. Under various parameter combinations and model combination conditions, input training samples Xtr and Ytr to train the combined model. Model calibration: For each combination model, input the verification sample Xve into the trained model under each parameter combination, compare and analyze the model prediction results Ypre_ve and Yve, and select the corresponding parameter combination and model combination method with the smallest error. The corresponding combination model is the one with the best fitting accuracy of the verification sample, which is used as the default model for online prediction. Model testing: Input the test sample Xte into the model selected by the verification sample to obtain the predicted value Ypre_te, and perform error analysis between Ypre_te and Yte to verify the accuracy of the model; Step 4: Implement online prediction for grids in the industrial park that have not undergone water quality monitoring. By obtaining the four types of data in step 3, using the trained and verified machine learning regression model, setting the prediction time, and predicting the future pollutant concentration of each grid point.
2. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: In step one, the groundwater online monitoring station network includes water quality monitoring points and water level monitoring points; the water quality monitoring points are arranged using a grid distribution method, taking into account both monitoring key pollution areas and the principle of uniform distribution, ensuring that there is a monitoring well in every 10 grid points in step two.
3. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: In step one, the basic information and stratigraphic data of the industrial park include the boundary range of the industrial park, the boundaries of enterprises within the park, the types of pollutants emitted by enterprises, the annual emissions of various types of pollutants by each enterprise, the distribution of rivers in the park, stratigraphic exploration drilling data, hydrogeological parameters, precipitation recharge parameters and land use conditions.
4. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: In step 2, the construction of an online groundwater flow model that can be updated in real time specifically includes the following steps: S21. Constructing a hydrogeological conceptual model: Based on the stratigraphic exploration drilling data and hydrogeological parameters of the industrial park, analyze the three-dimensional spatial distribution of the aquifer and the lithological characteristics of the water-bearing medium, and establish a three-dimensional geological model of the industrial park; combine the hydrological data in the industrial park and the characteristics of the regional groundwater flow field to determine the groundwater recharge, runoff, and discharge characteristics, and combine field tests to preliminarily obtain key hydraulic parameters including rainfall infiltration coefficient and water supply degree, and construct a hydrogeological conceptual model; S22. Model initial condition setting: For the state of groundwater flow field, a stable state within the industrial park that is not significantly affected by external stress terms is selected; S23, model boundary condition setting: determine the boundary conditions of the groundwater online flow model based on the hydrogeological conceptual model, and generalize the industrial park boundary into a first-class boundary with a given water head, a second-class boundary with a given lateral runoff, or a third-class boundary with a given relationship between lateral flow and water level; S24, Model source and sink item settings: Groundwater flow source and sink items include groundwater exploitation, rainfall infiltration recharge, evaporation from the water table, and exchange with surface water bodies, which are set through Class II and Class III boundary conditions; S25, model parameter setting: groundwater online flow model parameters include permeability coefficient, water storage coefficient, water supply degree, porosity, dispersion and chemical reaction parameters; S26, Model space discretization: Grid the simulation space of the industrial park using rectangular grids. The grid division accuracy depends on the area of the region and the number of monitoring well grids. The number of modeling grids is 10 times the number of monitoring well grids. S27, Model calibration and verification: Calibrate the model based on the measured groundwater level elevation, and adjust the parameter values to make the model calculation value and the actual observation value reach a certain accuracy requirement, basically characterizing the change characteristics of the groundwater flow field; The calibration result evaluation satisfies the requirement that the simulated flow field is similar to the observed flow field morphology, and requires that the fitting error between the actual observed value of the groundwater level in the observation well and the simulated calculated value is less than 10% of the water level variation range during the simulation period.
5. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: In step three, the specific implementation method of constructing a relative spatial coordinate system is: select any point within the modeling range of the industrial park as the coordinate origin, construct a relative rectangular coordinate system, with the 0° direction as the horizontal axis and the 90° direction as the vertical axis, and convert the spatial longitude and latitude coordinates of each point into relative distance coordinates. After the conversion, the coordinates (x, y) of a certain point indicate that the point is x meters east of the origin and y meters north of the origin.
6. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: In step 4, for the grid points where monitoring wells have been built, the online prediction process of groundwater pollutant concentration includes the following steps: ① The groundwater monitoring station automatically samples and conducts water quality analysis; ② After the latest water quality data is generated, the prediction process is automatically triggered, the groundwater pollution prediction model that can be updated in real time constructed in step 3 is called, and the default prediction time is set; ③ Retrieve the coordinate data, flow field data, lithology data, and enterprise pollution information data of all grid points, and also retrieve the online water quality monitoring data of the automatic monitoring station; ④Perform data processing and sample reconstruction according to step 3 to obtain the eigenvalue X; ⑤ Take the characteristic value X as input data and use the groundwater pollution prediction model that can be updated in real time constructed in step 3 to predict the concentration values of different pollutants at each grid point in the future; Based on the predicted values of pollutant concentrations at the grid points of the built monitoring wells, Kriging interpolation is performed to calculate the pollutant concentrations at the grid points where the monitoring wells are not built.
7. The online prediction method for groundwater pollution in industrial parks based on a machine learning model according to claim 1 is characterized in that: The online prediction method for groundwater pollution in industrial parks based on the machine learning model also includes: Step 5: Visualize the spatial distribution map of pollution prediction results at the same time and the pollutant change trend map at the same point; for the prediction results at different points at the same time, use colors to distinguish different concentration differences; for the prediction results at the same point at different times, use a line graph to present the point pollutant concentration change trend, thereby visualizing the pollutant prediction results.
Citation Information
Patent Citations
Underground water pollutant monitoring method, device and equipment and storage medium
CN114184750A
Geological statistics mode recognition method based on Bayesian ensemble learning machine
CN115510977A
Rapid prediction method for groundwater pollution
CN115828704A