A sparse station air quality prediction method based on a space-time hybrid model
By adopting a spatiotemporal hybrid model, the problems of data mutation and insufficient spatial features caused by extreme weather conditions in the air quality prediction of sparse stations are solved, and high-precision prediction of sparse stations is achieved, improving the robustness and prediction effect of the model.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NINGBO UNIV
- Filing Date
- 2023-04-12
- Publication Date
- 2026-04-28
AI Technical Summary
Existing technologies for air quality forecasting using sparse weather stations suffer from several problems: data abrupt changes caused by extreme weather conditions lead to decreased forecast accuracy; and the limited availability of information and insufficient spatial features at sparse weather stations result in low forecast accuracy.
A spatiotemporal hybrid model-based approach is adopted. Historical data from air quality monitoring stations are acquired, preprocessed and normalized, and then divided into training, validation and test sets. Multi-scale time-lag features of meteorological factors are extracted, and correlation analysis and Granger causality tests are performed. Spatial features are extracted by combining K-means clustering algorithm, and adaptive enhancement algorithm and attention long short-term memory network are used for collaborative training. Finally, the prediction results are output.
It effectively prevents data mutations caused by extreme weather conditions, improves the prediction accuracy of sparse stations, makes full use of the spatial characteristics of sparse stations, and enhances the robustness and prediction accuracy of the model.
Smart Images

Figure CN116561609B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of air quality prediction, and more particularly to a method for predicting air quality at sparse sites based on a spatiotemporal hybrid model. Background Technology
[0002] Traditional air quality forecasting methods are mainly divided into two categories: classical physical diffusion models and statistical data-driven models. Examples include Gaussian plume models and community multi-scale air quality models. These are based on atmospheric dynamics equations and atmospheric environmental chemistry equations; however, even small data errors in these models can lead to relatively large differences in the results. Furthermore, these models are relatively complex and computationally expensive.
[0003] Statistical data-driven models can be divided into two categories: linear statistical models and nonlinear statistical models. Methods based on linear statistical models establish the relationship between relevant features and air quality through linear models. Because linear statistical models cannot fit the nonlinear relationships between relevant features, nonlinear statistical models are more widely used for air quality forecasting. In comparison, nonlinear statistical models are more suitable for air quality forecasting. However, there is still room for improvement in their forecasting accuracy.
[0004] Deep learning possesses powerful capabilities in extracting features from large datasets. In the field of air quality forecasting, deep learning methods have been used to explore temporal correlations. In recent years, spatial features have also been incorporated into air quality forecasting; geographical location information between stations can form a station map, which can be integrated into the time-series data feature extraction process, thereby improving prediction accuracy. Therefore, an increasing number of researchers are using a combination of temporal correlations and spatial features to predict air quality. However, previous research still has the following shortcomings: air quality forecasting typically selects stations with dense surrounding networks as target stations, lacking support for air quality forecasting at sparse stations; the selection of relevant stations for target stations is usually achieved through spatial transformation, correlation analysis between station sequences, and distance-based methods. However, these methods are not suitable for selecting relevant stations at sparse sites; many studies lack analysis and handling of sequence mutations, and improving the prediction accuracy for mutation situations can improve overall prediction accuracy and model robustness. Summary of the Invention
[0005] The main problems to be solved by this invention are: how to prevent data mutations caused by extreme weather conditions from leading to a decrease in model prediction accuracy; and how to solve the problem of low prediction accuracy caused by insufficient available information and inadequate spatial features due to sparse stations.
[0006] The technical solution proposed by this invention to solve the above problems is: a sparse site air quality prediction method based on a spatiotemporal hybrid model, comprising the following steps:
[0007] Step (1): Obtain historical time series data of atmospheric pollutant concentrations and meteorological factors from various air quality monitoring stations. Atmospheric pollutants include sulfur dioxide, nitrogen dioxide, ozone, carbon monoxide, and fine particulate matter (PM2.5). 2.5 and PM 10 Meteorological factors include wind speed, precipitation, temperature, dew point, and air pressure. After preprocessing and normalizing the collected raw data, it is divided into training, validation, and test sets, as described in steps (1.1) to (1.5).
[0008] Step (1.1): Atmospheric pollutant concentration data acquisition: Historical data on the concentrations of various pollutants were collected at different monitoring stations. For the target station Target, the vector of atmospheric pollutant concentrations at each moment was: , In vectors , , , , , These represent the PM levels monitored by the target site at time t. 2.5 PM 10 Concentration values of carbon monoxide, nitrogen dioxide, sulfur dioxide, and ozone;
[0009] Step (1.2): Meteorological Factor Data Collection: Historical data of various meteorological factors are collected at different monitoring stations. For the target station Target, the vector formed by the meteorological factor values at each moment is as follows: In the vector , , , , These represent the values of wind speed, precipitation, temperature, dew point, and air pressure monitored at the target station Target at time t, respectively.
[0010] Step (1.3): Data preprocessing: Missing values in the time series data of collected air pollutant concentration data and meteorological factor values are filled using the average value interpolation method;
[0011] Step (1.4): Data Normalization: The time series data of each variable is normalized in the time dimension using the min-max normalization algorithm. Since the data scales of different air pollutants and meteorological factors are different, it is necessary to normalize each type of air pollutant and meteorological factor separately. For the time series data corresponding to each variable... The formula for the max-min normalization algorithm is as follows:
[0012]
[0013] in represent The maximum value in the historical time series, where represent The minimum value in a historical time series. This represents the normalized data;
[0014] Step (1.5): Data set partitioning: Divide the original time series data into training set, validation set and test set in a ratio of 7:2:1.
[0015] Step (2): Divide the historical time series of meteorological factor data into different scales along the time dimension, use an adaptive enhancement algorithm to extract time lag features at different time scales and evaluate the effect, and select the time lag scale at which each meteorological factor achieves the best effect as the optimal time lag scale. The specific implementation process is as described in steps (2.1) to (2.2):
[0016] Step (2.1): Divide the historical meteorological data time series into different scales along the time dimension: there are 6 different time lag scales, each with a 4-hour interval, i.e., the smallest time lag scale is 4 hours and the largest is 24 hours. The time series obtained according to the different time lag scales are as follows: Where t0 is the start time of the time series, and L is the time delay scale. The end time of the time series is used to find the optimal time lag for data abrupt changes to prevent the decrease in prediction accuracy caused by abrupt changes in atmospheric pollutant concentrations due to extreme weather conditions.
[0017] Step (2.2): Extract time lag features and compare with actual values: Input the time series described in step (2.1) into the adaptive enhancement model to predict future weather conditions, compare the predicted values with the actual values, and the time lag scale with the smallest error is the optimal time lag scale for the meteorological factor. This can prevent the problem of decreased prediction accuracy caused by sudden changes in atmospheric pollutant concentration due to extreme weather conditions to the greatest extent.
[0018] Step (3): Perform correlation analysis between the meteorological factor time series and the air pollutant concentration time series at the optimal time lag scale, retain only the air pollutant concentration and key features of each meteorological factor, and use them as feature groups in the time dimension. The specific implementation process is as described in steps 3.1 to 3.2:
[0019] Step (3.1): Perform Pearson correlation analysis on the meteorological factor time series corresponding to the optimal time lag scale and the atmospheric pollutant concentration time series. The calculation formula for the Pearson correlation analysis is as follows:
[0020]
[0021] Where Y and Z represent the time series of meteorological factors and the time series of atmospheric pollutant concentrations, respectively. and This represents the values of the two time series at time t. and The value represents the average of the two time series, T represents the time dimension, i.e. the number of time series data, and r is the obtained correlation coefficient value;
[0022] Step (3.2): The value range of the correlation coefficient is within... Within the range, positive numbers represent positive correlation, negative numbers represent negative correlation, and the closer the absolute value is to 1, the higher the correlation. Sequence pairs with correlation coefficients below 0.4 are removed, retaining only the concentrations of air pollutants and key features of each meteorological factor.
[0023] Step (4): Spatial features are extracted in the station dimension and region dimension using Granger causality test algorithm and K-means clustering algorithm respectively, so as to fully extract the spatial correlation between sparse stations and use them as feature groups in the spatial dimension. The specific implementation process is as described in steps (4.1) to (4.2):
[0024] Step (4.1): Extract spatial features at the site dimension using the Granger causality test algorithm: The calculation formula for the Granger causality test algorithm is as follows:
[0025]
[0026]
[0027] in and This represents the values of two time series, namely meteorological factors and air pollutants, at time t. and Representative at The value at time, where and These are the coefficients of the corresponding sequence, i = 0, 1, 2, and it is assumed that... and It is irrelevant noise;
[0028] Step (4.2): Use the K-means clustering algorithm to extract spatial features in the region dimension: use the coefficients of each station sequence calculated by the Granger causality test algorithm as coordinates, and divide stations with similar coordinates into the same region according to the K-means clustering algorithm. The station data in the same region are taken as the same spatial feature group.
[0029] Step (5): Input the feature groups of the time dimension and spatial dimension into the adaptive enhancement algorithm and the attention-based long short-term memory network algorithm for collaborative training, and finally cascade a fully connected layer to output the final prediction result.
[0030] Through the implementation steps described above, the advantages of the method of the present invention are as follows:
[0031] (1) Previous studies have often failed to address the problem of decreased prediction accuracy caused by data mutations due to extreme weather conditions. The method of this invention proposes a method to extract meteorological factors with multi-scale time lags to cope with sudden changes, which can achieve good prediction accuracy even when facing sudden changes.
[0032] (2) Previous air quality forecasts were based on a large number of stations and sufficient spatial features of the data. However, in the case of sparse stations, the forecast results were often not good. The method of this invention provides a method for selecting relevant stations in sparse stations based on spatial hierarchical division, which makes full use of the spatial features in the case of sparse stations and achieves better forecast accuracy.
[0033] (3) The hybrid model can make full use of the advantages of different models. The method of this invention creates a hybrid model that can give full play to the advantages of each sub-model in processing different feature groups, thereby improving the prediction accuracy. Attached Figure Description
[0034] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0035] Figure 1 This is a schematic diagram of the overall structure of the model in this invention;
[0036] Figure 2 This is a flowchart illustrating the overall method of the present invention; Detailed Implementation
[0037] To make the technical solutions and advantages of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings and specific examples.
[0038] As attached Figure 1 As shown, this invention provides a method for predicting air quality at sparse stations based on a spatiotemporal hybrid model. The specific implementation steps of this method are as follows:
[0039] Step (1): Obtain historical time series data of atmospheric pollutant concentrations and meteorological factors from various air quality monitoring stations. Atmospheric pollutants include sulfur dioxide, nitrogen dioxide, ozone, carbon monoxide, and fine particulate matter (PM2.5). 2.5 and PM 10 Meteorological factors include wind speed, precipitation, temperature, dew point, and air pressure. After preprocessing and normalizing the collected raw data, it is divided into training, validation, and test sets; the specific implementation process is as described in steps (1.1) to (1.5):
[0040] Step (1.1): Atmospheric pollutant concentration data acquisition: Historical data on the concentrations of various pollutants were collected at different monitoring stations. For the target station Target, the vector of atmospheric pollutant concentrations at each moment was: Each value in the vector represents the corresponding atmospheric pollutant concentration value monitored by the target station at time t; the final atmospheric pollutant concentration data dimension is... Where T represents the time dimension, from 00:00 on March 1, 2013 to 23:00 on February 28, 2017, totaling 35,064 data points. S represents the station dimension, i.e., the number of monitoring stations, specifically 12 monitoring stations. N represents the feature dimension, i.e., the number of air pollutants, specifically 6 air pollutants.
[0041] Step (1.2): Meteorological Factor Data Collection: Historical data of various meteorological factors are collected at different monitoring stations. For the target station Target, the vector formed by the meteorological factor values at each moment is as follows: In the vector , , , , These represent the wind speed, precipitation, temperature, dew point, and air pressure values monitored at the target station at time t, respectively; the final meteorological data dimensions are: Where T represents the time dimension, from 00:00 on March 1, 2013 to 23:00 on February 28, 2017, totaling 35,064 data points. S represents the station dimension, i.e., the number of monitoring stations, specifically 12 monitoring stations. M represents the feature dimension, i.e., the number of meteorological factors, specifically 5 meteorological factors.
[0042] Step (1.3): Data preprocessing: Missing values in the time series data of collected air pollutant concentrations and meteorological factors are filled using the average imputation method. When some variables of a single station are missing at a certain time, the average value of the same variable from other stations at the same time is used to fill the missing values; when all stations are missing variables at a certain time, the average value of the data before and after the time gap for each station is used to fill the missing values.
[0043] Step (1.4): Data Normalization: The time series data of each variable is normalized in the time dimension using the min-max normalization algorithm. For the time series data corresponding to each variable... The formula for the max-min normalization algorithm is as follows:
[0044]
[0045] After normalization by the maximum and minimum values, the range of data will be limited to (0,1), which can effectively prevent the gradient explosion problem and speed up the operation.
[0046] Step (1.5): Dataset partitioning: Before partitioning the dataset, data labels need to be generated for the original time series data. After generating corresponding labels for each data sample, the dataset will be partitioned. The specific implementation process is as described in steps (1.5.1) to (1.5.2):
[0047] Step (1.5.1): For supervised learning, we need to assign a corresponding label to each data sample. In time series prediction problems, the data samples are historical time series data with a fixed window size, and the labels are the future time series at a certain time step to be predicted. We select historical time series data with a window size as the original data and define variables... The length of the historical time series we want to use for prediction. This represents the future time step that needs to be predicted. At this point, the dimension of a data sample becomes... Where T represents the time dimension. S represents the historical data window size, S represents the site dimension, and F represents the feature dimension. The corresponding labels are: , This represents the time step of the prediction.
[0048] Step (1.5.2): Divide the dataset: Divide the original time series data into a training set, a validation set, and a test set in a 7:2:1 ratio. The training set is used to train the model parameters during model training, the validation set is used to validate the trained parameters to prevent overfitting during training and improve training efficiency, and the test set is used to evaluate the training results.
[0049] Step (2): Divide the historical time series data of meteorological factors into different scales along the time dimension, use an adaptive enhancement algorithm to extract the time lag features at different scales and compare them with the actual values to obtain the time lag scale at which each meteorological factor can achieve the best effect. The specific implementation process is as described in steps (2.1) to (2.2):
[0050] Step (2.1): Divide the historical meteorological data time series into different scales along the time dimension: there are 6 different time lag scales, each with a 4-hour interval, i.e., the smallest time lag scale is 4 hours and the largest is 24 hours. The time series obtained according to the different time lag scales are as follows: Where t0 is the start time of the time series, and L is the time delay scale. The end time of the time series is used to find the optimal time lag for data abrupt changes to prevent the decrease in prediction accuracy caused by abrupt changes in atmospheric pollutant concentrations due to extreme weather conditions.
[0051] Step (2.2): Extract time lag features and compare with actual values: Input the time series of the six different time lag scales into the adaptive enhancement model to predict future weather conditions. Compare the predicted values with the actual values. The time lag scale with the smallest error is the optimal time lag scale for the meteorological factor. This can prevent the problem of decreased prediction accuracy caused by sudden changes in atmospheric pollutant concentration due to extreme weather conditions to the greatest extent.
[0052] Step (3): After obtaining the optimal time lag scale for each meteorological factor, correlation analysis is performed between the time series of meteorological factors at the corresponding time scale and the time series of atmospheric pollutant concentrations. Only the atmospheric pollutant concentrations and key features of each meteorological factor are retained as feature groups for the time dimension. The specific implementation process is as described in steps (3.1) to (3.2):
[0053] Step (3.1): Perform Pearson correlation analysis on the meteorological factor time series corresponding to the optimal time lag scale and the atmospheric pollutant concentration time series. The calculation formula for the Pearson correlation analysis is as follows:
[0054]
[0055] Where Y and Z represent the time series of meteorological factors and the time series of atmospheric pollutant concentrations, respectively. and This represents the values of the two time series at time t. and The value represents the average of the two time series, T represents the time dimension, i.e. the number of time series data, and r is the obtained correlation coefficient value;
[0056] Selection and PM 2.5 Features with a correlation greater than 0.4 are considered key features, i.e., PM. 10 Sulfur dioxide, nitrogen dioxide, carbon monoxide, and dew point. In addition, PM2.5... 10 Carbon monoxide, ozone, and wind speed were selected as key characteristics for nitrogen dioxide, while PM2.5 was selected as a key characteristic for nitrogen dioxide. 10 Nitrogen dioxide, temperature, and wind speed were selected as key characteristics of ozone.
[0057] Step (3.2): The value range of the correlation coefficient is within... Between these values, positive numbers represent positive correlation, negative numbers represent negative correlation, and the closer the absolute value is to 1, the higher the correlation. Sequence pairs with correlation coefficients below 0.4 are removed, retaining only the concentrations of air pollutants and key features of each meteorological factor.
[0058] Step (4): Spatial features are extracted in the station dimension and region dimension using Granger causality test algorithm and K-means clustering algorithm respectively, so as to fully extract the spatial correlation between sparse stations and use them as feature groups in the spatial dimension. The specific implementation process is as described in steps (4.1) to (4.2):
[0059] Step (4.1): Extract spatial features at the site dimension using the Granger causality test algorithm: The calculation formula for the Granger causality test algorithm is as follows:
[0060]
[0061]
[0062] in and This represents the values of two time series, namely meteorological factors and air pollutants, at time t. and Representative at The value at time, where and These are the coefficients of the corresponding sequence, and it is assumed that... and It is irrelevant noise;
[0063] The Granger causality test results for other station sequences to the target station sequence are denoted by prob(Y), where prob(Y) represents the probability of rejecting the null hypothesis. Similarly, the Granger causality test results for the target station sequence to other station sequences are denoted by prob(Z). If the value of prob(Y) is less than 0.05, it indicates that early changes in the station sequence can lead to changes in the sequence at sparse stations.
[0064] Step (4.2): Extracting spatial features at the region level using the K-means clustering algorithm: At the region level, this study uses the Granger causality test results prob(Y) and prob(Z) as coordinate points for the K-means clustering algorithm to classify sites with similar features. Based on the similarity features of the sites and the principle of non-overlapping regions, sites with similar features are grouped into the same region to the greatest extent possible. Other sites located in the same region as the sparse sites are selected as related sites of the sparse sites. The features of these related sites are selected as spatial feature groups.
[0065] Step (5): Input the feature groups of the time and space dimensions into the adaptive enhancement algorithm and the attention-based long short-term memory network algorithm for collaborative training, and finally cascade a fully connected layer to output the final prediction result. The specific implementation process is as described in steps (5.1) to (5.2):
[0066] Step (5.1): The adaptive reinforcement algorithm is the most typical representative of reinforcement ensemble learning. The main logic of this algorithm is to combine multiple weak classifiers and combine them into a strong classifier by changing the weights of the weak classifiers. The specific implementation process is as described in steps (5.1.1) to (5.1.3):
[0067] Step (5.1.1): For each weak classifier, update the learning difficulty of each weak classifier according to the following formula:
[0068]
[0069] in This represents the error rate of the classifier. and These represent the learning difficulty of the classifier before and after the update. If the weak classifier classifies correctly, its learning difficulty will decrease according to the first formula; if the weak classifier classifies incorrectly, its learning difficulty will increase according to the second formula.
[0070] Step (5.1.2): The formula for calculating the weights of the weak classifier is:
[0071]
[0072] in This represents the error rate of the classifier. This represents the weight of the classifier.
[0073] Step (5.1.3): The final output is:
[0074]
[0075] in The output of the adaptive enhancement algorithm, Representing the Each classifier weight, Representing the The output of each classifier Indicates the number of classifiers.
[0076] Step (5.2): The attention-based Long Short-Term Memory (LSTM) network is built upon the LSM network by introducing an attention mechanism during the computation of its original hidden states. This adds an attention layer, enabling it to maintain higher attention weights for important features. The formula for calculating the attention weights is shown below:
[0077]
[0078]
[0079] in and These represent the hidden states of layer i and layer j, respectively. Represents the correlation calculation function. Represents hidden state and The correlation between them This represents the normalized attention weight value. Representing the Hidden state of layer and the first Correlation of hidden states in layers This represents the number of hidden layers.
[0080] Example: This section will combine specific data, including station latitude and longitude data and monitoring data from monitoring stations, to explain in detail the meaning of the specific parameters of the model, the data calculation process of the model, and the model training process. Finally, the experimental results of the model on mutation data and conventional data will be verified.
[0081] Dataset Introduction: The dataset was collected from 12 air quality monitoring stations in Beijing, covering the period from 00:00 on March 1, 2013 to 23:00 on February 28, 2017, totaling 35,064 data points. The station latitude and longitude data are shown below. The selected target station is the Gucheng station, geographically located in the southwest corner, far from areas with dense monitoring stations, and its spatial characteristics are insufficient, thus meeting the applicable scenario for the method of this invention targeting sparse stations.
[0082]
[0083] Model parameter settings: Input dimension is set to 12, hidden dimension to 64, data window size (Windows) to 24, prediction stride (Horizon) to single step, Long Short-Term Memory (LSTM) network to three layers with initial hidden states of 0. The optimizer is Adam, learning rate is 0.005, training iterations are 1000, loss function is mean absolute error, and evaluation metrics are mean absolute error (MAE) and root mean square error (RMSE). The formulas for calculating the evaluation metrics are shown below:
[0084]
[0085] Where S represents the site dimension, meaning the output prediction result has a total of S values. This represents the i-th value of the model's prediction result. This represents the i-th value of the sample data label, i.e., the true value.
[0086] The model's data computation process: The model's input is a fourth-order tensor. Where B represents the batch size, i.e., the number of data points fed into the model at one time; W represents the window size; S represents the number of sites; and F represents the dimension of the data features. The output hidden state data dimension is... Where H represents the predicted future step size. The attention layer accepts the hidden state output by the Long Short-Term Memory network as input and assigns weights to the hidden state according to the attention weight calculation formula.
[0087] The model training process is as follows: First, the training set is input into the model for training: training data is input into the model, the loss value between the model output and the data label is calculated according to the loss function formula, and the model parameters are updated according to the gradient update strategy of the Adam optimizer; the model loss is verified using the validation set: after each training session, validation set data is input to verify the model parameters to prevent overfitting; test set: after the model training is completed, test set data is input to evaluate the model's performance.
[0088] To verify the effectiveness of the proposed method in the face of data mutations (values changing by more than 50% in a short period of time): the proposed method was tested with other standard baseline algorithms under the same experimental settings using a dataset containing data mutations. The algorithm output results were compared using the same evaluation metrics, and the obtained evaluation metrics, mean absolute error (MAE) and root mean square error (RMSE), were listed in the table. The standard baseline algorithms included: Adaboost, Attention-LSTM, CNN-LSTM, and PSO-LSTM.
[0089]
[0090] The method proposed in this paper achieves a significant reduction in prediction error compared to other standard baseline algorithms when facing time series prediction problems with data mutations, reaching the optimal performance.
[0091] To verify the effectiveness of the proposed method on conventional data (excluding anomalous data): the proposed method was tested with other standard baseline algorithms under the same experimental settings using conventional data. The algorithm outputs were compared using the same evaluation metrics, and the obtained evaluation metrics, namely mean absolute error (MAE) and root mean square error (RMSE), were listed in the table. The standard baseline algorithms included: Adaboost, Attention-LSTM, and Particle Swarm Optimization-based LSTM.
[0092]
[0093] Compared with other standard baseline algorithms, the method proposed in this paper shows a significant reduction in error during single-step prediction when dealing with time series prediction problems of conventional data, achieving optimal results.
[0094] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A sparse-site air quality prediction method based on a spatiotemporal hybrid model, characterized in that, Includes the following steps: Step (1): Obtain historical time series data of atmospheric pollutant concentrations and meteorological factors from various air quality monitoring stations. Atmospheric pollutants include sulfur dioxide, nitrogen dioxide, ozone, carbon monoxide, and fine particulate matter (PM2.5). 2.5 and PM 10 Meteorological factors include wind speed, precipitation, temperature, dew point, and air pressure. After preprocessing and normalizing the collected raw data, it is divided into training set, validation set and test set; Step (2): Divide the historical time series of meteorological factor data into different scales in the time dimension, use the adaptive enhancement algorithm to extract the time lag features of different time scales and evaluate the effect, and select the time lag scale at which each meteorological factor achieves the best effect as the optimal time lag scale. Step (3): Perform correlation analysis between the meteorological factor time series and the atmospheric pollutant concentration time series under the optimal time lag scale, retain only the atmospheric pollutant concentration and key features of each meteorological factor, and use the key feature data with high correlation as the feature group of the time dimension. Step (4): Use Granger causality test algorithm and K-means clustering algorithm to extract spatial features in the station dimension and region dimension respectively, so as to fully extract the spatial correlation between sparse stations and use the station data in the same region as the feature group of the spatial dimension. Step (5): Input the feature groups of the time dimension and spatial dimension into the adaptive enhancement algorithm and the attention-based long short-term memory network algorithm for collaborative training, and finally cascade a fully connected layer to output the final prediction result.
2. The sparse site air quality prediction method based on a spatiotemporal hybrid model according to claim 1, characterized in that, The specific steps (1) are as follows: Step (1.1): Atmospheric pollutant concentration data acquisition: Historical data on the concentrations of various pollutants were collected at different monitoring stations. For the target station Target, the vector of atmospheric pollutant concentrations at each moment was: In the vector , , , , , These represent the PM levels monitored by the target site at time t. 2.5 PM 10 Concentration values of carbon monoxide, nitrogen dioxide, sulfur dioxide, and ozone; Step (1.2): Meteorological Factor Data Collection: Historical data of various meteorological factors are collected at different monitoring stations. For the target station Target, the vector formed by the meteorological factor values at each moment is as follows: In the vector , , , , These represent the values of wind speed, precipitation, temperature, dew point, and air pressure monitored at the target station Target at time t, respectively. Step (1.3): Data preprocessing: Missing values in the time series data of collected air pollutant concentration data and meteorological factor values are filled using the average value interpolation method; Step (1.4): Data Normalization: The time series data of each variable is normalized in the time dimension using the min-max normalization algorithm. Since the data scales of different air pollutants and meteorological factors are different, it is necessary to normalize each type of air pollutant and meteorological factor separately. For the time series data corresponding to each variable... The formula for the max-min normalization algorithm is as follows: in represent The maximum value in the historical time series, where represent The minimum value in a historical time series. This represents the normalized data; Step (1.5): Data set partitioning: Divide the original time series data into training set, validation set and test set in a ratio of 7:2:
1.
3. The sparse site air quality prediction method based on a spatiotemporal hybrid model according to claim 1, characterized in that, Step (2) specifically involves: Step (2.1): Divide the historical time series of meteorological factors into different scales along the time dimension: there are 6 different time lag scales, each with a 4-hour interval, i.e., the smallest time lag scale is 4 hours and the largest time lag scale is 24 hours; the time series obtained by dividing the data according to different time lag scales are as follows: Where t0 is the start time of the time series, and L is the time delay scale. The end time of the time series is used to find the optimal time lag for data abrupt changes to prevent the decrease in prediction accuracy caused by abrupt changes in atmospheric pollutant concentrations due to extreme weather conditions. Step (2.2): Extract time lag features and compare them with actual values: Input the time series described in step (2.1) into the adaptive enhancement model to predict future weather conditions, compare the predicted values with the actual values, and the time lag scale with the smallest error is the optimal time lag scale for the meteorological factor. This can prevent the problem of decreased prediction accuracy caused by sudden changes in atmospheric pollutant concentration due to extreme weather conditions to the greatest extent.
4. The sparse site air quality prediction method based on a spatiotemporal hybrid model according to claim 1, characterized in that, Step (3) specifically involves: Step (3.1): Perform Pearson correlation analysis on the meteorological factor time series corresponding to the optimal time lag scale and the atmospheric pollutant concentration time series. The calculation formula for the Pearson correlation analysis is as follows: Where Y and Z represent the time series of meteorological factors and the time series of atmospheric pollutant concentrations, respectively. and This represents the values of the two time series at time t. and The value represents the average of the two time series, T represents the time dimension, i.e. the number of time series data, and r is the obtained correlation coefficient value; Step (3.2): The range of the correlation coefficient is within Within the correlation coefficient, a positive number indicates a positive correlation, a negative number indicates a negative correlation, and the closer the absolute value is to 1, the higher the correlation. Sequence pairs with a correlation coefficient lower than 0.4 are removed, and only the concentration of air pollutants and key features of each meteorological factor are retained.
5. The sparse site air quality prediction method based on a spatiotemporal hybrid model according to claim 1, characterized in that, Step (4) specifically involves: Step (4.1): Extract spatial features at the site dimension using the Granger causality test algorithm: The calculation formula for the Granger causality test algorithm is as follows: in and This represents the values of two time series, namely meteorological factors and air pollutants, at time t. and Representative at The value at time, where and These are the coefficients of the corresponding sequence, i = 0, 1, 2, and it is assumed that... and It is irrelevant noise; Step (4.2): Use the K-means clustering algorithm to extract spatial features in the region dimension: use the coefficients of each station sequence calculated by the Granger causality test algorithm as coordinates, and divide stations with similar coordinates into the same region according to the K-means clustering algorithm. The station data in the same region are taken as the same spatial feature group.