Model training method, fine particulate matter concentration prediction method, device and electronic equipment

By screening and segmenting the initial data set, combining step-by-step regression analysis and deep neural networks, a mechanism model and error compensation model are established, which solves the problem of low accuracy in the prediction of fine particulate matter concentration in the existing technology, and achieves higher accuracy and real-time concentration prediction.

CN113962333BActive Publication Date: 2025-08-22BEIJING UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111451931.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-01
Publication Date
2025-08-22
Estimated Expiration
2041-12-01

AI Technical Summary

Technical Problem

In the prior art, the accuracy of the indoor and outdoor fine particulate concentration prediction model is low, and the numerical analysis method is poorly interpretable, so it cannot effectively guide pollution prevention and control measures.

Method used

By obtaining the initial data set, filtering the experimental data sets related to fine particulate matter, and dividing them into multiple sub-stages, using stepwise regression analysis and deep neural network to establish mechanism models and error compensation models, and training is carried out to improve prediction accuracy.

Benefits of technology

It improves the accuracy, real-time and efficiency of fine particulate concentration prediction, enhances the interpretability and adaptability of the model, and can more accurately predict indoor and outdoor fine particulate concentrations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113962333B_ABST
    Figure CN113962333B_ABST
Patent Text Reader

Abstract

The present application provides a model training method, a fine particulate matter concentration prediction method, a device and an electronic device, and relates to the technical field of fine particulate matter concentration prediction. The model training method includes: obtaining an initial data set collected in a monitoring device; screening the initial data set to establish an experimental data set related to fine particulate matter; dividing the experimental data set into multiple sub-stages based on the acquisition time corresponding to the experimental data set, and obtaining multiple corresponding sub-stage data sets; based on the sub-stage data sets, training the initial prediction model to obtain a concentration prediction model. The present application effectively improves the pertinence and effectiveness of the data set by segmenting the data set, thereby improving the prediction accuracy of the concentration prediction model, improving the performance of the prediction model, and making predictions based on the concentration prediction model, which can effectively improve the accuracy, real-timeness and efficiency of fine particulate matter concentration prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field, and in particular to a model training method, a fine particulate matter concentration prediction method, a device and an electronic device. Background Art

[0002] Indoor PM2.5 (fine particulate matter) primarily originates from two sources: outdoor fine particles enter indoor spaces through infiltration, mechanical ventilation, and natural ventilation. Indoor pollution sources, such as smoking, cooking, and burning incense, also contribute to fine particulate matter. Existing methods for analyzing the correlation between indoor and outdoor fine particulate matter primarily include mechanistic models and numerical analysis.

[0003] Currently, mechanism models can clearly derive the changing process and influencing factors of indoor particulate matter. However, the sources of indoor particulate matter are diverse and the propagation process is complex, making it difficult to comprehensively consider various factors and establish an accurate model. In the existing technology, numerical analysis methods are usually used to improve the accuracy of the model when establishing the model. For example, multivariate linear regression and neural network models are usually based on large data sets, which can achieve high prediction accuracy without considering complex mechanism laws. However, the methods based on numerical analysis have poor interpretability, which is not conducive to guiding the implementation of subjective pollution prevention and control measures. In addition, due to the non-selectability of the relevant variables in the model, the performance of the current prediction model is low, and it is impossible to accurately predict the concentration of fine particulate matter indoors and outdoors. Summary of the Invention

[0004] In view of this, the purpose of the embodiments of the present application is to provide a model training method, a fine particulate matter concentration prediction method, device and electronic device to improve the problem of low fine particulate matter prediction accuracy in the prior art.

[0005] In order to solve the above problems, in the first aspect, the present application provides a model training method, comprising:

[0006] Obtaining an initial data set collected by a monitoring device, the initial data set including indoor concentration and outdoor concentration of fine particulate matter and corresponding multiple environmental variable data;

[0007] screening the initial data set to establish an experimental data set related to the fine particulate matter;

[0008] Based on the acquisition time corresponding to the experimental data set, the experimental data set is divided into multiple sub-stages, and multiple corresponding sub-stage data sets are obtained;

[0009] Based on the sub-stage data set, the initial prediction model is trained to obtain a concentration prediction model.

[0010] In the above implementation, when training the prediction model, by screening the collected initial data set, an experimental data set related to fine particulate matter can be obtained, thereby filtering out some irrelevant data in the initial data set and improving the relevance of the experimental data set. By segmenting the experimental data set, the experimental data set can be divided into multiple sub-stages according to the acquisition time, thereby improving the relevance and effectiveness of the data set. The sub-stage data set corresponding to each sub-stage is used as training data and substituted into the initial prediction model for training to obtain a trained concentration prediction model, which effectively improves the prediction accuracy and performance of the prediction model, thereby improving the accuracy, real-time nature, and efficiency of fine particulate matter concentration prediction.

[0011] Optionally, screening the initial data set to establish an experimental data set related to the fine particulate matter includes:

[0012] configuring a regression equation based on the indoor concentration or the outdoor concentration;

[0013] Substituting the plurality of environmental variable data into the regression equation in sequence to perform calculations and obtain corresponding calculation results;

[0014] Screening the plurality of calculation results, and removing the environmental variable data whose calculation results do not meet the regression conditions from the regression equation;

[0015] retaining the environmental variable data whose calculation results satisfy the regression condition in the regression equation as relevant variable data;

[0016] The experimental data set is formed by using the multiple related variable data in the regression equation after screening.

[0017] In the above implementation, since the initial data set obtained includes indoor concentrations, outdoor concentrations and corresponding multiple environmental variable data of fine particulate matter, and some environmental variable data have a low correlation with the concentration of fine particulate matter, stepwise regression analysis can be used to screen the multiple environmental variable data. The indoor fine particulate matter concentration is used as the dependent variable of the regression equation, and some environmental variable data are randomly selected as independent variables. The regression equation is configured, and the correlation between each environmental variable data and the concentration of fine particulate matter is calculated through the regression equation to obtain the corresponding calculation results. The environmental variable data introduced into the regression equation and whose calculation results do not meet the regression conditions are eliminated, and the environmental variable data that are not introduced into the regression equation and whose calculation results meet the regression conditions are introduced into the regression equation as related variable data with a high correlation with the fine particulate matter concentration. The experimental data set is composed of multiple related variable data, which improves the pertinence and effectiveness of the experimental data set and reduces the adverse effects of irrelevant data on model training.

[0018] Optionally, dividing the experimental dataset into multiple sub-stages based on the acquisition time corresponding to the experimental dataset, and obtaining multiple corresponding sub-stage datasets includes:

[0019] Initially dividing the acquisition time of the experimental data set to obtain multiple initial sub-stages;

[0020] obtaining a plurality of initial samples of the initial sub-stages;

[0021] Calculating error data of the initial sample;

[0022] The error data is adjusted based on the standard sample to adjust the boundary points of the initial sub-stage, thereby obtaining a plurality of adjusted sub-stages and a corresponding sub-stage data set in each of the sub-stages.

[0023] In the above implementation, since the experimental data set involves different collection times, and considering that the concentration of fine particulate matter has obvious seasonal characteristics, the experimental data set is initially divided according to the collection time, and the experimental data set can be automatically divided into multiple initial sub-stages. Error adjustment is performed on the basis of the initial sub-stages, and the boundary points of the initial sub-stages can be adjusted to obtain multiple adjusted sub-stages, as well as multiple sub-stage data sets corresponding to the multiple sub-stages that are connected in time series. By segmenting the experimental data set, the experimental data can be processed separately based on different collection times, improving the temporal pertinence of the sub-stage data sets, so that the prediction model can be trained based on data from different time periods, improving the timeliness of the concentration prediction model.

[0024] Optionally, before training the initial prediction model based on the sub-stage data set to obtain the concentration prediction model, the method further includes:

[0025] Based on the penetration information of the fine particulate matter, a mechanism model corresponding to each of the sub-stages is established, wherein the mechanism model is a dynamic model representing the concentration change of the fine particulate matter;

[0026] Based on a deep neural network, an error compensation model corresponding to each of the mechanism models is established;

[0027] The error of the mechanism model is compensated based on the error compensation model to obtain an initial prediction model.

[0028] In this implementation, before training begins, a mechanistic model representing the changes in fine particle concentration corresponding to each sub-stage can be established based on the fine particle penetration information. Based on this mechanistic model, a corresponding error compensation model can be established using a deep neural network multi-layer perceptron to compensate for the errors in the mechanistic model, enabling the mechanistic model to cope with the impact of environmental factors and further improving the model's accuracy and adaptability. Thus, an initial prediction model is obtained based on the mechanistic model and the error compensation model. By modeling the changes in fine particle concentration and compensating for errors, the prediction accuracy of the initial prediction model can be effectively improved.

[0029] Optionally, establishing a mechanism model corresponding to each sub-stage based on the penetration information of the fine particulate matter includes:

[0030] obtaining penetration information of the fine particulate matter from different environments;

[0031] Calculating dynamic change information of the fine particulate matter based on the penetration information;

[0032] Based on the dynamic change information, a mechanism model corresponding to each sub-stage is established.

[0033] In the above implementation method, it is possible to obtain the penetration information of fine particulate matter from different sources, from different environments, and infiltrate through different pathways, and to conduct targeted modeling of the concentration changes of fine particulate matter in each sub-stage based on the penetration information, thereby effectively improving the performance of the mechanism model and reducing the error of the concentration prediction by the mechanism model.

[0034] Optionally, the training of the initial prediction model based on the sub-stage data set to obtain a concentration prediction model includes:

[0035] In each sub-stage, substituting the sub-stage data set into the initial prediction model for training, and obtaining the prediction error of the initial prediction model;

[0036] When the prediction error reaches a preset value, or the number of training times of the initial prediction model reaches a threshold, the training is terminated to obtain a concentration prediction model.

[0037] In the above implementation, for each sub-stage at different times, the sub-stage dataset corresponding to each sub-stage is used as training data and substituted into the corresponding initial prediction model for training. The training results of the initial prediction model in each sub-stage are fitted. When the prediction error obtained from training reaches a preset value or the number of training times of the initial prediction model reaches a threshold, the training is terminated, and the final concentration prediction model is obtained. Separate predictions can be made for sub-stages at different times to reduce the adverse effects of different times on the fine particulate matter concentration prediction results, enabling the concentration prediction model to make targeted predictions at different times, thereby improving the performance and prediction accuracy of the concentration prediction model.

[0038] Secondly, this application also provides a method for predicting fine particulate matter concentration, including:

[0039] Obtain environmental detection data corresponding to the target environment;

[0040] The environmental detection data is input into the concentration prediction model described in any one of the above-mentioned model training methods for processing to obtain a concentration prediction result of fine particulate matter corresponding to the target environment.

[0041] In the above implementation method, when predicting the concentration of fine particulate matter, the environmental detection data obtained by detecting in the target environment to be predicted is used as input data and substituted into the concentration prediction model trained in the model training method for processing. The concentration prediction result of the fine particulate matter in the target environment can be obtained, which effectively improves the accuracy, real-time and effectiveness of the concentration prediction result.

[0042] In a third aspect, the present application further provides a model training device, comprising:

[0043] An acquisition module is used to acquire an initial data set collected by the monitoring device, wherein the initial data set includes indoor concentration and outdoor concentration of fine particulate matter and corresponding multiple environmental variable data;

[0044] A screening module, configured to screen the initial data set to establish an experimental data set related to the fine particulate matter;

[0045] A segmentation module, configured to divide the experimental data set into a plurality of sub-stages based on the acquisition time corresponding to the experimental data set, and obtain a plurality of corresponding sub-stage data sets;

[0046] The training module is used to train the initial prediction model based on the sub-stage data set to obtain a concentration prediction model.

[0047] In the above implementation, an initial data set consisting of various data detected in the environment is obtained through the acquisition module. The initial data set is filtered through the screening module to filter out some irrelevant data in the initial data set, thereby obtaining an experimental data set related to fine particulate matter. The experimental data set is segmented by the segmentation module, and the experimental data set can be divided into multiple sub-stages according to the acquisition time, thereby improving the pertinence and effectiveness of the data set. The sub-stage data set corresponding to each sub-stage is used as training data by the training module and substituted into the initial prediction model for training to obtain a trained concentration prediction model, which effectively improves the prediction accuracy and performance of the prediction model, thereby improving the accuracy, real-time nature and efficiency of fine particulate matter concentration prediction.

[0048] In a fourth aspect, the present application further provides a fine particulate matter concentration prediction device, the device comprising:

[0049] A detection module is used to obtain environmental detection data corresponding to the target environment;

[0050] The prediction module is used to input the environmental detection data into the concentration prediction model described in any one of the above-mentioned model training methods for processing to obtain the concentration prediction result of fine particulate matter corresponding to the target environment.

[0051] In the above implementation method, the environmental detection data in the target environment that needs to be predicted is obtained through the detection module, and the environmental detection data is used as input data through the prediction module and substituted into the concentration prediction model trained in the model training method for processing, so as to obtain the concentration prediction result of fine particulate matter in the target environment, thereby effectively improving the accuracy, real-time and effectiveness of the concentration prediction result.

[0052] In a fifth aspect, the present application also provides an electronic device, which includes a memory and a processor, wherein the memory stores program instructions, and when the processor reads and runs the program instructions, it executes the steps in any implementation method of the above-mentioned model training method.

[0053] In a sixth aspect, the present application also provides a computer-readable storage medium, in which computer program instructions are stored. When the computer program instructions are read and run by a processor, the steps in any implementation of the above-mentioned model training method are executed.

[0054] In summary, the present application provides a model training method, a fine particulate matter concentration prediction method, a device and an electronic device. By segmenting the data set, the pertinence and effectiveness of the data set are effectively improved, thereby improving the prediction accuracy of the concentration prediction model and improving the performance of the prediction model. Predictions based on the concentration prediction model can effectively improve the accuracy, real-time nature and efficiency of fine particulate matter concentration prediction. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without creative work.

[0056] Figure 1 A flowchart of a model training method provided in an embodiment of the present application;

[0057] Figure 2 A detailed flow chart of step S2 provided in an embodiment of the present application;

[0058] Figure 3 A detailed flow chart of step S3 provided in an embodiment of the present application;

[0059] Figure 4 A detailed flow chart of step S4 provided in an embodiment of the present application;

[0060] Figure 5 A flowchart of another model training method provided in an embodiment of the present application;

[0061] Figure 6 A flow chart of a method for predicting fine particulate matter concentration provided in an embodiment of the present application;

[0062] Figure 7 A schematic diagram of the structure of a model training device provided in an embodiment of the present application;

[0063] Figure 8 A schematic diagram of the structure of a fine particulate matter concentration prediction device provided in an embodiment of the present application.

[0064] Icons: 700-model training device; 710-acquisition module; 720-screening module; 730-segmentation module; 740-training module; 800-fine particulate matter concentration prediction device; 810-detection module; 820-prediction module. DETAILED DESCRIPTION

[0065] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the embodiments described are only part of the embodiments of the present application, not all of them. Based on the embodiments of the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the embodiments of the present application.

[0066] Existing methods for analyzing the correlation between indoor and outdoor fine particulate matter mainly include mechanistic models and numerical analysis. For example, a mechanistic model is established based on the principles of indoor and outdoor fine particulate matter variation, enabling the prediction of indoor particulate matter concentration changes. Alternatively, a neural network-based model can be trained by selecting multiple environmental variables closely related to indoor fine particulate matter, such as outdoor fine particulate matter, indoor and outdoor temperature, indoor and outdoor temperature, and ventilation rate, to predict indoor fine particulate matter concentrations.

[0067] However, these numerical analysis-based methods suffer from poor interpretability, making them inadequate for guiding the implementation of subjective pollution prevention measures. Furthermore, due to the non-selectability of relevant model variables, current prediction models exhibit low performance and are unable to accurately predict indoor and outdoor fine particulate matter concentrations.

[0068] To address the above issues, embodiments of the present application provide a model training method for use on a server, which can be an electronic device with logical computing capabilities, such as a personal computer (PC), tablet computer, smartphone, or personal digital assistant (PDA). This application can train a prediction model based on segmented data, thereby improving the performance of the prediction model.

[0069] See also Figure 1 , Figure 1 A flow chart of a model training method provided in an embodiment of the present application, which may include the following steps:

[0070] Step S1: Acquire an initial data set collected by a monitoring device.

[0071] Among them, the initial data set includes indoor concentrations, outdoor concentrations of fine particulate matter and corresponding various environmental variable data.

[0072] Alternatively, environmental monitoring points can be pre-set in multiple environments, either indoors or outdoors, to collect data from these multiple environments. The environmental monitoring points are wirelessly connected to a server via a network, allowing the server to obtain an initial dataset consisting of multiple data points collected from one or more environmental monitoring points. Alternatively, the server can obtain historical data from the database of the environmental monitoring station as the initial dataset.

[0073] Optionally, environmental monitoring points can be equipped with a variety of air monitors to regularly collect air-related data such as indoor and outdoor concentrations of fine particulate matter, indoor and outdoor temperatures, and indoor and outdoor relative humidity in multiple environments. Environmental monitoring points can also be equipped with a variety of environmental monitors to regularly collect various environmental data such as outdoor wind direction, outdoor wind speed, indoor pressure, outdoor pressure, wind chill index, heat index, dew point temperature, and wet-bulb temperature to construct an initial data set.

[0074] Optionally, when collecting various data in the initial data set, the user can set the time points for data collection based on actual needs or environmental conditions. For example, data collection can be performed periodically, with the data collection interval set to one minute, and the initial data set period set to one year. The corresponding time points can also be modified or adjusted.

[0075] Step S2: screening the initial data set to establish an experimental data set related to the fine particulate matter.

[0076] Among them, since the initial data set obtained includes the indoor concentration, outdoor concentration and corresponding multiple environmental variable data of fine particulate matter, and some environmental variable data have a low correlation with the concentration of fine particulate matter, multiple environmental variable data can be selected and screened to obtain an experimental data set consisting of multiple data related to fine particulate matter.

[0077] Optionally, see Figure 2 , Figure 2 A detailed flow diagram of step S2 provided in an embodiment of the present application, step S2 may further include steps S21-S24:

[0078] Step S21: configuring a regression equation based on the indoor concentration or the outdoor concentration.

[0079] Among them, a stepwise regression analysis method can be used to gradually screen multiple environmental variable data, using indoor concentration or outdoor concentration as the dependent variable of the regression equation. The regression equation is configured to randomly select a portion of environmental variable data from the initial data set and introduce it into the regression equation as the independent variable of the regression equation. The independent variables in the regression equation have a strong regression relationship with the dependent variable and there is no multicollinearity problem between the variables, which effectively improves the accuracy of the regression equation. The regression equation is as follows:

[0080] Y=β0+β1X1+β2X2+…+β K X K ;

[0081] Where Y is the indoor concentration or outdoor concentration, X1, X2, ..., X Kare multiple environmental variable data, β0, β1, β2, ..., β K are multiple regression coefficients.

[0082] Step S22: Substitute the plurality of environmental variable data into the regression equation in sequence to perform calculations and obtain corresponding calculation results.

[0083] Among them, since the initial data set contains multiple different environmental variable data, when using the stepwise regression method to screen the environmental variables, the multiple environmental variable data in the initial data set can be substituted into the regression equation in turn for calculation. The calculation results obtained include two calculation data: partial regression sum of squares and significance.

[0084] Step S23 , screening the plurality of calculation results, and removing the environmental variable data whose calculation results do not meet the regression conditions from the regression equation.

[0085] Step S24, retaining the environmental variable data whose calculation results meet the regression conditions in the regression equation as relevant variable data; and forming an experimental data set with the plurality of relevant variable data in the regression equation after screening.

[0086] Among them, the multiple calculation results of multiple environmental variable data corresponding to the regression equation as the independent variables of the regression equation are screened to determine whether the calculation results meet the regression conditions. The regression conditions are that the partial regression sum of squares is maximized and the significance test is significant. The partial regression sum of squares and significance can be judged separately, and the environmental variable data that do not meet the regression conditions are eliminated from the regression equation, and the environmental variable data that meet the regression conditions are still retained in the regression equation as related variable data.

[0087] By screening multiple calculation results of multiple environmental variable data that have not been introduced into the regression equation, it is possible to determine whether the calculation results meet the regression conditions. The regression conditions are that the partial regression sum of squares is maximized and the significance test is significant. The environmental variable data that meet the regression conditions are introduced into the regression equation as related variable data.

[0088] Optionally, when the introduction and elimination of multiple environmental variable data are completed, the screening process ends, and the experimental data set is composed of the multiple related variable data after screening.

[0089] exist Figure 2In the embodiment shown, through stepwise regression analysis, independent variables such as indoor concentration, outdoor concentration, indoor temperature, outdoor temperature, indoor and outdoor relative humidity, outdoor wind direction, outdoor wind speed, indoor pressure, outdoor pressure, wind chill index, thermal index, dew point temperature, and wet bulb temperature are screened one by one to obtain relevant variable data to constitute an experimental data set, thereby improving the pertinence and effectiveness of the experimental data set and reducing the adverse effects of irrelevant data on model training.

[0090] After step S2 is completed, step S3 is continued.

[0091] Step S3: dividing the experimental data set into a plurality of sub-stages based on the acquisition time corresponding to the experimental data set, and obtaining a plurality of corresponding sub-stage data sets.

[0092] Among them, since the experimental data set involves different acquisition times, considering the impact of acquisition time on the concentration prediction of fine particulate matter, the experimental data set is initially divided according to the acquisition time, which can automatically divide the experimental data set into multiple sub-stages, increasing the time correlation of the sub-stage data set corresponding to each sub-stage.

[0093] For example, when the collection time period of multiple data in the experimental data set is one year, due to the long time period, different times correspond to different weather and seasons. Different seasons and weather have a greater impact on the prediction of fine particulate matter concentration. The concentration of fine particulate matter has obvious seasonal characteristics. For example, the permeability factor of fine particulate matter in different seasons shows different values. Therefore, the experimental data can be divided into multiple sub-stages according to season, month, timing, etc., to obtain multiple sub-stage data sets connected in time series.

[0094] It is worth noting that, when performing segmentation, a wrapped k-means algorithm can be used to divide the experimental data set, which can automatically divide the data set without changing the time sequence of the experimental data set.

[0095] Optionally, see Figure 3 , Figure 3 A detailed flow diagram of step S3 provided in an embodiment of the present application, step S3 may further include steps S31-S34:

[0096] Step S31 : Initially divide the acquisition time of the experimental data set into multiple initial sub-stages.

[0097] Among them, based on the tracking division algorithm, initial division can be performed on the basis of the acquisition time of the experimental data set to obtain multiple initial sub-stages.

[0098] Step S32: Acquire a plurality of initial samples of the initial sub-stage.

[0099] Wherein, based on the tracking and division algorithm, the boundary data of each initial sub-stage can be obtained as an initial sample.

[0100] Step S33: Calculate the error data of the initial sample.

[0101] The initial sample also includes the cluster center of the sample. The error data in the initial sample is calculated based on the mean square error of the distance from each initial sample to the sample center and the minimum principle. The calculation method is as follows:

[0102]

[0103]

[0104]

[0105]

[0106] Among them, x j is an initial sample in the initial sub-stage, n j is the number of initial samples in the initial sub-stage, x is the standard sample, b j is x j Boundary data, μ j is x j The cluster center, H j is x j The unevenness of the initial sub-stage, l is another initial sub-stage, H is all the unevenness in the initial sub-stage, n l is the number of initial samples in another initial sub-stage, and ΔH(x, j, l) is the error data.

[0107] Step S34 , adjusting the error data based on the standard sample to adjust the boundary points of the initial sub-stage, thereby obtaining a plurality of adjusted sub-stages and a corresponding sub-stage data set in each of the sub-stages.

[0108] Among them, error adjustment is performed on the basis of the initial sub-stage. Based on the root mean square error and minimum principle of the distance from the sample points of each sub-stage to the cluster center, the boundary points of the initial sub-stage can be adjusted to obtain multiple adjusted sub-stages and multiple sub-stage data sets corresponding to the multiple sub-stages that are connected in time series.

[0109] Optionally, the adjustment is calculated as follows:

[0110]

[0111]

[0112] H1=H+ΔH(x,j,l);

[0113] Among them, μ j1 is the adjusted x j The cluster center, μ l is the cluster center of another initial sub-stage, μ l1 is the corresponding adjusted cluster center, and H1 is the adjusted root mean square error.

[0114] It is worth noting that when the root mean square error no longer changes or the number of iteration steps reaches the maximum value, the adjustment is completed and multiple adjusted sub-stage data sets are obtained.

[0115] exist Figure 3 In the embodiment shown, by segmenting the experimental data set, the experimental data can be processed separately based on different acquisition times, thereby improving the temporal targeting of the sub-stage data set, so that the prediction model can be trained based on data from different time periods, thereby improving the timeliness of the concentration prediction model.

[0116] After step S3 is completed, step S4 is continued.

[0117] Step S4: Based on the sub-stage data set, the initial prediction model is trained to obtain a concentration prediction model.

[0118] Among them, for sub-stages with different time periods, the sub-stage data set corresponding to each sub-stage is used as training data and substituted into the corresponding initial prediction model for training to obtain a concentration prediction model that can make predictions for different times.

[0119] Optionally, see Figure 4 , Figure 4 A detailed flow diagram of step S4 is provided in an embodiment of the present application. Step S4 may further include steps S41-S42:

[0120] Step S41: In each sub-stage, the sub-stage data set is substituted into the initial prediction model for training to obtain the prediction error of the initial prediction model.

[0121] Among them, the training results of the initial prediction model in each sub-stage are fitted to obtain the prediction error of each sub-stage during each training.

[0122] Step S42: When the prediction error reaches a preset value or the number of training times of the initial prediction model reaches a threshold, the training is terminated to obtain a concentration prediction model.

[0123] Among them, when the prediction error obtained by training reaches a preset value and no longer changes, or when the number of training times of the initial prediction model reaches a threshold, the training is terminated to obtain the final concentration prediction model, which has sufficient interpretability, high accuracy and portability.

[0124] Optionally, the preset value and the threshold of the number of training times can be set by the user based on the actual situation of the initial prediction model to limit the number of training times.

[0125] exist Figure 4 In the embodiment shown, it is possible to make separate predictions for sub-stages at different times to reduce the adverse effects of different times on the concentration prediction results of fine particulate matter, so that the concentration prediction model can make targeted predictions for different times, thereby improving the performance and prediction accuracy of the concentration prediction model.

[0126] Optionally, see Figure 5 , Figure 5 A flow chart of another model training method provided in an embodiment of the present application. Before step S4, the model training method may further include steps Sa-Sc:

[0127] Step Sa: establishing a mechanism model corresponding to each of the sub-stages based on the penetration information of the fine particulate matter, wherein the mechanism model is a dynamic model representing the concentration change of the fine particulate matter.

[0128] Before training, a mechanism model representing the concentration change of fine particulate matter corresponding to each sub-stage can be established based on the penetration information of fine particulate matter.

[0129] It is worth noting that when establishing a mechanism model, you can first obtain the penetration information of fine particulate matter from different environments. The penetration information can include the penetration laws of fine particulate matter based on different sources in different environments and in different ways. For example, indoor fine particulate matter comes from indoor emission sources and the penetration of outdoor fine particulate matter. The indoor emission sources are mainly human activities such as indoor smoking and cooking. The outdoor fine particulate matter enters the room mainly due to the osmotic pressure movement caused by the pressure difference between indoor and outdoor, the osmotic diffusion movement caused by the concentration difference of fine particulate matter indoor and outdoor, natural ventilation indoors and outdoor, and mechanical ventilation indoors and outdoor. The following mathematical models are established for various sources of indoor fine particulate matter. Based on the FICK equation, the penetration law of fine particulate matter from the outdoors into the indoors due to osmotic diffusion movement can be described as:

[0130] J V =F inf *(C out -C in )*A*v;

[0131] Among them, JV is the mass flux of fine particulate matter from outdoor to urban area per unit time, F inf is the penetration rate of fine particulate matter from outdoor to urban areas, C out is the outdoor fine particulate matter concentration (ug / m 3 ), C in is the concentration of fine particles in the room, v is the speed of fine particles passing through the boundary layer (m / s), and A is the effective area of ​​the cross section of the particle passing through the boundary layer (m 2 ).

[0132] Based on the infiltration information, the dynamic change information of fine particulate matter is calculated. Among them, due to the pressure difference between indoor and outdoor, the infiltration pressure movement is generated. The transfer of indoor and outdoor particles can be described as:

[0133]

[0134]

[0135]

[0136]

[0137] Among them, z is a point in the boundary layer, z0 represents the point where the indoor and outdoor pressures are equal, P out is the outdoor pressure value, P in is the pressure value in the room, L is the length of the boundary layer, P out-in is the pressure value at point z, J V1 is the mass flux of fine particles lost from outdoor to indoor space under the action of osmotic pressure per unit time, J V2 C is the mass flux of fine particles lost from outdoor to indoor space under the action of osmotic pressure per unit time. out-in It indicates the change in the concentration of fine particulate matter in the room per unit time under the action of osmotic pressure, that is, the dynamic change information of fine particulate matter.

[0138] Based on the dynamic change information, a mechanism model corresponding to each sub-stage is established. The mechanism model can reflect the source and change process of fine particulate matter in this sub-stage to the greatest extent. The establishment method is as follows:

[0139]

[0140] Where Δt is the sampling time interval, K1 is the coefficient of fine particulate matter entering indoors from the outdoors under natural and mechanical ventilation conditions, K2 is the coefficient of fine particulate matter diffusing from indoors to the outdoors under natural and mechanical ventilation conditions, and C s is the contribution value of indoor emission sources, It is the dynamic change process of fine particulate matter concentration, that is, the mechanism model corresponding to each sub-stage.

[0141] Step Sb: establishing an error compensation model corresponding to each of the mechanism models based on a deep neural network.

[0142] Among them, since there are errors in the mechanism model, in order to improve the accuracy of the initial prediction model when making predictions, an MLP (Multi Layer Perceptron) error compensation model corresponding to the mechanism model of each sub-stage can be established on the basis of the deep neural network. When establishing the error compensation model, it is possible to input and output variable information respectively on the basis of the initial error model to determine the structural information such as the input layer, hidden layer and output layer of the deep neural network corresponding to the model. After determining the structural information of the deep neural network, on the basis of the structure, according to the structural characteristics of the deep neural network, an optimization algorithm such as Adam (Adaptive Momentum Estimation, an extended algorithm of the stochastic gradient descent method) or Dropout algorithm is added to avoid overfitting of the network in the model, and relevant network parameters are set to establish a corresponding error compensation model.

[0143] Step Sc: compensating the error of the mechanism model based on the error compensation model to obtain an initial prediction model.

[0144] The parameters of the mechanism model corresponding to each sub-stage are close to fixed values. However, due to the influence of multiple factors such as environmental variables, the parameters of the mechanism model at different times may deviate from the stage average. Therefore, an error compensation model can be used to compensate for the deviations of the mechanism model at different times in advance, thereby improving the accuracy of the initial prediction model.

[0145] Alternatively, deep neural networks have strong nonlinear fitting capabilities. By training a deep neural network multilayer perceptron, we can use relevant variables as input data and the error generated by the mechanism model as the target output. This can compensate for the prediction deviation of the mechanism model caused by multiple factors at each moment, thereby improving the calculation accuracy of the mechanism model.

[0146] Alternatively, the initial prediction model can be expressed as:

[0147] C=F inf *(C out -C in )*A*v+C out-in +K1*C out -K2*C in +C s +ΔC1;

[0148] Wherein, C is the initial prediction model after error compensation, and ΔC1 is the concentration compensation value generated by the neural network compensator in the error compensation model.

[0149] exist Figure 5 In the illustrated embodiment, the prediction accuracy of the initial prediction model can be effectively improved by modeling the concentration change of fine particulate matter and compensating for errors.

[0150] It is worth noting that after obtaining the concentration prediction model, in order to evaluate the performance of the concentration prediction model, a variety of data can be used to test the concentration prediction model.

[0151] For example, the performance of the concentration prediction model can be tested using parameters such as mean absolute error, normalized absolute error, root mean square error, and coefficient of determination. The testing method is as follows:

[0152]

[0153]

[0154]

[0155]

[0156] Where N represents the total number of samples, y i Indicates the actual concentration of indoor fine particulate matter, y i1 represents the concentration value predicted by the concentration prediction model, y2 represents the average concentration value of indoor fine particulate matter, MAE represents the mean absolute error, NAE represents the normalized absolute error, RMASE represents the root mean square error, and R2 represents the coefficient of determination.

[0157] See also Figure 6 , Figure 6 A flow chart of a method for predicting fine particulate matter concentration provided in an embodiment of the present application is provided. The method may include the following steps:

[0158] Step S5: Acquire environmental detection data corresponding to the target environment.

[0159] Among them, the corresponding detection data in the target environment that needs to be predicted can be obtained as environmental detection data to meet the user's various prediction needs.

[0160] Step S6: input the environmental detection data into a concentration prediction model for processing to obtain a concentration prediction result of fine particulate matter corresponding to the target environment.

[0161] Among them, the prediction model used in the fine particulate matter concentration prediction method is the concentration prediction model trained in the above-mentioned model training method.

[0162] exist Figure 6 In the embodiment shown, environmental detection data is used as input data and substituted into the concentration prediction model trained in the model training method for processing, so that the concentration prediction result of fine particulate matter in the target environment can be obtained, which effectively improves the accuracy, real-timeness and effectiveness of the concentration prediction result.

[0163] See also Figure 7 , Figure 7 This is a schematic diagram of the structure of a model training device provided in an embodiment of the present application. The model training device 700 includes:

[0164] An acquisition module 710 is configured to acquire an initial data set collected by a monitoring device, wherein the initial data set includes indoor concentration and outdoor concentration of fine particulate matter and corresponding environmental variable data.

[0165] A screening module 720 is configured to screen the initial data set to establish an experimental data set related to the fine particulate matter;

[0166] A segmentation module 730 is configured to divide the experimental data set into a plurality of sub-stages based on the acquisition time corresponding to the experimental data set, and obtain a plurality of corresponding sub-stage data sets;

[0167] The training module 740 is used to train the initial prediction model based on the sub-stage data set to obtain a concentration prediction model.

[0168] In an optional embodiment, the screening module 720 may further include a regression submodule, a calculation submodule, a removal submodule, and a retention submodule;

[0169] A regression submodule, configured to configure a regression equation based on the indoor concentration or the outdoor concentration;

[0170] A calculation submodule, used for sequentially substituting the plurality of environmental variable data into the regression equation to perform calculations and obtain corresponding calculation results;

[0171] A removal submodule, configured to screen the plurality of calculation results and remove the environmental variable data whose calculation results do not meet the regression conditions from the regression equation;

[0172] The retaining submodule is used to retain the environmental variable data whose calculation results meet the regression conditions in the regression equation as related variable data; and to form an experimental data set with multiple related variable data in the regression equation after screening.

[0173] In an optional embodiment, the segmentation module 730 may further include a division submodule, a sampling submodule, an error calculation submodule, and an adjustment submodule;

[0174] A division submodule, used for initially dividing the acquisition time of the experimental data set to obtain multiple initial sub-stages;

[0175] A sampling submodule, configured to obtain a plurality of initial samples of the initial sub-stages;

[0176] An error calculation submodule, used to calculate the error data of the initial sample;

[0177] The adjustment submodule is used to adjust the error data based on the standard sample to adjust the boundary points of the initial sub-stage to obtain multiple adjusted sub-stages and a corresponding sub-stage data set in each of the sub-stages.

[0178] In an optional embodiment, the model training device 700 may further include a modeling module and an error module;

[0179] A modeling module, configured to establish a mechanism model corresponding to each of the sub-stages based on the penetration information of the fine particulate matter, wherein the mechanism model is a dynamic model representing the concentration change of the fine particulate matter;

[0180] The modeling module is further used to establish an error compensation model corresponding to each of the mechanism models based on a deep neural network;

[0181] The error module is used for the error compensation model to compensate the error of the mechanism model to obtain an initial prediction model.

[0182] In an optional embodiment, the modeling module is also used to obtain the penetration information of the fine particulate matter from different environments; based on the penetration information, calculate the dynamic change information of the fine particulate matter; based on the dynamic change information, establish a mechanism model corresponding to each sub-stage.

[0183] In an optional embodiment, the training module 740 may further include an input submodule and an end submodule;

[0184] An input submodule, configured to substitute the substage data set into the initial prediction model for training in each substage, and obtain the prediction error of the initial prediction model;

[0185] The end submodule is used to end the training and obtain the concentration prediction model when the prediction error reaches a preset value or the number of training times of the initial prediction model reaches a threshold.

[0186] Since the principle of solving the problem by the device in the embodiment of the present application is similar to that of the embodiment of the aforementioned model training method, the implementation of the device in this embodiment can refer to the description in the embodiment of the aforementioned model training method, and the repeated parts will not be repeated.

[0187] See also Figure 8 , Figure 8 This is a schematic diagram of the structure of a fine particulate matter concentration prediction device provided in an embodiment of the present application. The fine particulate matter concentration prediction device 800 includes:

[0188] Detection module 810, used to obtain environmental detection data corresponding to the target environment;

[0189] The prediction module 820 is used to input the environmental detection data into the concentration prediction model for processing to obtain a concentration prediction result of fine particulate matter corresponding to the target environment.

[0190] Among them, the prediction model used in the prediction module 820 is the concentration prediction model trained in the above-mentioned model training method.

[0191] Since the principle of solving the problem by the device in the embodiment of the present application is similar to that of the embodiment of the aforementioned fine particulate matter concentration prediction method, the implementation of the device in this embodiment can refer to the description in the embodiment of the aforementioned fine particulate matter concentration prediction method, and the repeated parts will not be repeated.

[0192] An embodiment of the present application also provides an electronic device, which includes a memory and a processor, wherein the memory stores program instructions, and when the processor reads and runs the program instructions, it executes the steps of any one of the model training methods provided in this embodiment.

[0193] It should be understood that the electronic device may be a personal computer, a tablet computer, a smart phone, a personal digital assistant, or other electronic device with logic computing capabilities.

[0194] An embodiment of the present application also provides a computer-readable storage medium, in which computer program instructions are stored. When the computer program instructions are read and executed by a processor, the steps of any one of the model training methods provided in this embodiment are executed.

[0195] To sum up, in summary, the embodiments of the present application provide a model training method, a fine particulate matter concentration prediction method, a device and an electronic device. By segmenting the data set, the pertinence and effectiveness of the data set are effectively improved, thereby improving the prediction accuracy of the concentration prediction model and improving the performance of the prediction model. Predictions are made based on the concentration prediction model, which can effectively improve the accuracy, real-timeness and efficiency of fine particulate matter concentration prediction.

[0196] In the several embodiments provided in this application, it should be understood that the disclosed devices can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the block diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices according to the multiple embodiments of the present application. In this regard, each box in the block diagram can represent a module, a program segment or a part of a code, and the module, program segment or a part of the code contains one or more executable instructions for implementing the specified logical functions. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram, and the combination of the block diagrams, can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.

[0197] In addition, the functional modules in each embodiment of the present application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.

[0198] If the function is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Therefore, this embodiment also provides a computer program instruction stored in a readable storage medium, and when the computer program instruction is read and executed by a processor, the steps of any method described in the block data storage method are executed. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program code, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0199] The foregoing is merely an embodiment of the present application and is not intended to limit the scope of protection of the present application. Various modifications and variations are possible for those skilled in the art. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included within the scope of protection of the present application. It should be noted that similar reference numerals and letters represent similar items in the following figures. Therefore, once an item is defined in one figure, it does not need to be further defined or explained in subsequent figures.

[0200] The above is only a specific implementation method of the present application, but the scope of protection of the present application is not limited thereto. Any technician familiar with this technical field can easily think of changes or replacements within the technical scope disclosed in this application, which should be covered by the scope of protection of the present application.

[0201] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, the elements defined by the phrase "comprising..." do not exclude the presence of other identical elements in the process, method, article, or device comprising the elements.

Claims

1. A model training method, characterized in that: include: Obtaining an initial data set collected by a monitoring device, the initial data set including indoor concentration and outdoor concentration of fine particulate matter and corresponding multiple environmental variable data; screening the initial data set to establish an experimental data set related to the fine particulate matter; Based on the acquisition time corresponding to the experimental data set, the experimental data set is divided into multiple sub-stages, and multiple corresponding sub-stage data sets are obtained; Based on the sub-stage data set, the initial prediction model is trained to obtain a concentration prediction model; Before training the initial prediction model based on the sub-stage data set to obtain the concentration prediction model, the method further includes: establishing a mechanism model corresponding to each of the sub-stages based on the penetration information of the fine particulate matter, wherein the mechanism model is a dynamic model representing the concentration change of the fine particulate matter; establishing an error compensation model corresponding to each of the mechanism models based on a deep neural network; and compensating for the error of the mechanism model based on the error compensation model to obtain the initial prediction model; The establishment method of the mechanism model includes: ; in, is the penetration rate of fine particles from outdoor to indoor, The concentration of fine particulate matter outdoors , The concentration of fine particulate matter indoors , is the speed of fine particles passing through the boundary layer m / s, The effective area of ​​the particle's cross-section through the boundary layer , It indicates the change in the concentration of fine particulate matter in the room per unit time under the action of osmotic pressure. is the sampling time interval, is the coefficient of fine particulate matter entering indoors from outdoors under natural and mechanical ventilation conditions, is the coefficient of fine particulate matter diffusion from indoor to outdoor under natural and mechanical ventilation conditions, is the contribution value of indoor emission sources, The mechanism model corresponding to each sub-stage of the dynamic change process of fine particulate matter concentration; The initial prediction model is: ; in, is the initial prediction model after error compensation, is the concentration compensation value generated by the neural network compensator in the error compensation model.

2. The method according to claim 1, characterized in that The screening of the initial data set to establish an experimental data set related to the fine particulate matter includes: configuring a regression equation based on the indoor concentration or the outdoor concentration; Substituting the plurality of environmental variable data into the regression equation in sequence to perform calculations and obtain corresponding calculation results; Screening the plurality of calculation results, and removing the environmental variable data whose calculation results do not meet the regression conditions from the regression equation; retaining the environmental variable data whose calculation results satisfy the regression condition in the regression equation as relevant variable data; The experimental data set is formed by using the multiple related variable data in the regression equation after screening.

3. The method according to claim 1, characterized in that The step of dividing the experimental data set into a plurality of sub-stages based on the acquisition time corresponding to the experimental data set, and obtaining a plurality of corresponding sub-stage data sets includes: Initially dividing the acquisition time of the experimental data set to obtain multiple initial sub-stages; obtaining a plurality of initial samples of the initial sub-stages; Calculating error data of the initial sample; The error data is adjusted based on the standard sample to adjust the boundary points of the initial sub-stage, thereby obtaining a plurality of adjusted sub-stages and a corresponding sub-stage data set in each of the sub-stages.

4. The method according to claim 1, wherein The establishing of a mechanism model corresponding to each sub-stage based on the penetration information of the fine particulate matter includes: obtaining penetration information of the fine particulate matter from different environments; Calculating dynamic change information of the fine particulate matter based on the penetration information; Based on the dynamic change information, a mechanism model corresponding to each sub-stage is established.

5. The method according to claim 1, characterized in that The initial prediction model is trained based on the sub-stage data set to obtain a concentration prediction model, including: In each sub-stage, substituting the sub-stage data set into the initial prediction model for training, and obtaining the prediction error of the initial prediction model; When the prediction error reaches a preset value, or the number of training times of the initial prediction model reaches a threshold, the training is terminated to obtain a concentration prediction model.

6. A method for predicting fine particulate matter concentration, characterized in that: include: Obtain environmental detection data corresponding to the target environment; The environmental detection data is input into the concentration prediction model described in any one of claims 1 to 5 for processing to obtain a concentration prediction result of fine particulate matter corresponding to the target environment.

7. A model training device, characterized in that: The device comprises: An acquisition module is used to acquire an initial data set collected by the monitoring device, wherein the initial data set includes indoor concentration and outdoor concentration of fine particulate matter and corresponding multiple environmental variable data; A screening module, configured to screen the initial data set to establish an experimental data set related to the fine particulate matter; A segmentation module, configured to divide the experimental data set into a plurality of sub-stages based on the acquisition time corresponding to the experimental data set, and obtain a plurality of corresponding sub-stage data sets; A training module, configured to train the initial prediction model based on the sub-stage data set to obtain a concentration prediction model; A modeling module is used to establish a mechanism model corresponding to each of the sub-stages based on the penetration information of the fine particulate matter, wherein the mechanism model is a dynamic model representing the concentration change of the fine particulate matter; and to establish an error compensation model corresponding to each of the mechanism models based on a deep neural network; An error module, configured to compensate for the error of the mechanism model based on the error compensation model to obtain an initial prediction model; The establishment method of the mechanism model includes: ; in, is the penetration rate of fine particles from outdoor to indoor, The concentration of fine particulate matter outdoors , The concentration of fine particulate matter indoors , is the speed of fine particles passing through the boundary layer m / s, The effective area of ​​the particle's cross-section through the boundary layer , It indicates the change in the concentration of fine particulate matter in the room per unit time under the action of osmotic pressure. is the sampling time interval, is the coefficient of fine particulate matter entering indoors from outdoors under natural and mechanical ventilation conditions, is the coefficient of fine particulate matter diffusion from indoor to outdoor under natural and mechanical ventilation conditions, is the contribution value of indoor emission sources, The mechanism model corresponding to each sub-stage of the dynamic change process of fine particulate matter concentration; The initial prediction model is: ; in, is the initial prediction model after error compensation, is the concentration compensation value generated by the neural network compensator in the error compensation model.

8. A fine particulate matter concentration prediction device, characterized in that: The device comprises: A detection module is used to obtain environmental detection data corresponding to the target environment; A prediction module is used to input the environmental detection data into the concentration prediction model described in any one of claims 1 to 5 for processing, so as to obtain a concentration prediction result of fine particulate matter corresponding to the target environment.

9. An electronic device, characterized in that: The electronic device includes a memory and a processor, wherein program instructions are stored in the memory, and when the processor runs the program instructions, the steps of the method according to any one of claims 1 to 5 are executed.

Citation Information

Patent Citations

  • Gas sensor array concentration detection method based on fuzzy division and model integration

    CN105938116A

  • EMD and LSTM fused urban PM2.5 concentration prediction method

    CN111144286A