Air quality prediction method based on multivariate data fusion and AGGA network model

By adopting multivariate data fusion and AGGA network model in air quality prediction, using AE, GAT and attention-filled GRU processing time and spatial correlation, the problem of low accuracy in multivariate data prediction is solved, and higher prediction accuracy and application practice value is achieved.

CN119537796APending Publication Date: 2025-02-28HUAIYIN INSTITUTE OF TECHNOLOGY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411200994.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-29
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

Existing air quality prediction methods ignore temporal and spatial correlations when processing multivariate data, resulting in low prediction accuracy and robustness.

Method used

Using a method based on multivariate data fusion and AGGA network model, dimensionality reduction is performed through the AE automatic encoder, and the graph attention network and the GRU two-time attention mechanism integrated with the attention mechanism are used to deal with time continuity and spatial propagation characteristics.

Benefits of technology

It improves the accuracy of multivariate data air quality prediction, can dynamically process time continuity and spatial propagation characteristics, and meets the need to quickly and accurately generate prediction results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119537796A_ABST
    Figure CN119537796A_ABST
Patent Text Reader

Abstract

The invention discloses an air quality prediction method based on multivariate data fusion and an AGGA network model. Acquiring air pollution data, meteorological data and geographical environment data; performing dimension reduction on the air pollution data by using an AE model to obtain an air pollution data feature sequence; inputting the meteorological data and the geographical environment data into a graph attention network (GAT) to obtain new spatial features; performing multivariate fusion on the new spatial features, the air pollution data feature sequence, the air pollution data, the meteorological data and the geographical environment data to obtain a new time-space sequence with attention; integrating the attention mechanism into a hidden layer of the GRU to establish a GRUA; training the new space-time sequence by using GRUA to obtain a trained AGGA model; and performing air quality prediction by adopting the trained AGGA model. According to the method, the time correlation and the space correlation among multivariate data of each monitoring station are effectively improved, and the time continuity and the space propagation characteristics are comprehensively processed, so that the space-time prediction accuracy of the air quality of the multivariate data is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to an air quality prediction method, and in particular to an air quality prediction method based on multivariate data fusion and an AGGA network model. Background Art

[0002] With the economic development, scientific and technological progress, the rapid improvement of industrialization, and the continuous advancement of urbanization, industries related to chemical industry have entered a new stage of development. As a result, the emission of various pollutants in the air has increased year by year, which has led to increasingly serious air pollution problems. Harmful substances that can be inhaled in the air will not only increase the incidence of respiratory diseases among urban residents and threaten their health, but also react chemically with water vapor in the air to form acid rain, causing further damage to the urban environment. Air pollutants are mainly composed of particulate matter (including PM 2.5 and PM 10 ) and gaseous mixtures (including CO, SO2, NO2 and O3). An important indicator for measuring air quality is the Air Quality Index (AQI). Air pollution has become the biggest environmental threat to human health alongside climate change, so it is very meaningful to be able to accurately and effectively predict air quality.

[0003] Due to the international attention paid to environmental protection, the prediction of AQI can help people understand the air pollution situation in advance and take corresponding health protection measures. It can also warn of the occurrence of air pollution in advance, which helps the relevant government management departments to formulate emergency measures and environmental protection measures in a targeted manner, evaluate and monitor the effects of air pollution control measures, and guide further environmental management and decision-making. Therefore, air quality prediction has become an important research topic for ecological protection, improving climate change, and assisting relevant government personnel in making scientific decisions.

[0004] The significant characteristics of air quality spatiotemporal series data, such as high nonlinearity and non-stationarity, make high-precision prediction methods face huge challenges. Existing single prediction models often use unit data for prediction, such as LSTM, RNN, GCN, TCN and other models, ignoring the mutual influence between multivariate data, which leads to low accuracy and robustness of air quality prediction; in addition, many deep learning hybrid models have made certain improvements in air quality prediction compared to single prediction models, but they do not pay enough attention to temporal continuity and spatial propagation characteristics, resulting in poor local prediction accuracy in different time slices. Summary of the invention

[0005] The purpose of the present invention is to use the AE autoencoder to reduce the dimension from the perspectives of time and space based on the temporal correlation and spatial correlation of multivariate data from different monitoring stations, use the graph attention network and the GRU double attention mechanism integrated with the attention mechanism to focus on key information, grasp the global spatial and temporal dependencies, complete the spatiotemporal correlation modeling, comprehensively and dynamically process the temporal continuity and spatial propagation characteristics, and further improve the prediction accuracy of multivariate data air quality.

[0006] The air quality prediction method based on multivariate data fusion and AGGA network model of the present invention comprises:

[0007] (1) Obtain air pollution data, meteorological data, and geographic environment data;

[0008] (2) Clean and integrate the acquired air pollution data, meteorological data, and geographic environment data;

[0009] (3) Use the AE model to reduce the dimension of air pollution data and obtain the characteristic sequence of air pollution data;

[0010] (4) Input meteorological data and geographic environment data into GAT to obtain new spatial features;

[0011] (5) Multi-integrate the new spatial features, air pollution data feature sequences, air pollution data, meteorological data, and geographic environment data to obtain a new spatiotemporal sequence with attention;

[0012] (6) Integrate the attention mechanism into the hidden layer of GRU;

[0013] (7) Apply GRU to train the new spatiotemporal sequence to obtain the trained AGGA model;

[0014] (8) Use the trained AGGA model to predict air quality.

[0015] Furthermore, in step (1), the factors affecting air quality include natural factors and human factors. Natural factors include meteorological data and geographical environment data; human factors include air pollution data; the meteorological data include temperature, air pressure, humidity, wind speed, and underlying surface; the geographical environment data include latitude and longitude, and altitude; the air quality data include AQI, PM 10 、PM 2.5 , O3, SO2 and NO2.

[0016] Furthermore, step (2) includes: cleaning the acquired air pollution data, meteorological data and geographical environment data, converting the data into a unified format, and storing the processed data in npy format.

[0017] Further, step (3) comprises:

[0018] (3.1) Constructing the encoder

[0019] The encoder includes an input layer, a hidden layer, and an output layer. The number of dimensions of the input layer depends on the number of air pollution data. The hidden layer is two fully connected layers. The number of dimensions of the hidden layer is set to the number of features that affect air quality in the original sequence data. The number of nodes in the hidden layer is less than the number of nodes in the input layer, and the number of nodes in the input layer is equal to the number of nodes in the output layer. The activation function is set to Leaky ReLU, which is used to make nonlinear changes to the output of each layer.

[0020] (3.2) Constructing the decoder

[0021] The decoder includes an input layer, a hidden layer and an output layer, wherein the input layer receives the output of the encoder, the hidden layer corresponds to the hidden layer structure of the encoder, uses the same number of layers and nodes, and the number of nodes in the output layer is equal to the feature dimension of the original sequence data, which is used to reconstruct the original data;

[0022] (3.3) Use air pollution data as training data to train the weight parameters of the autoencoder, and the loss function is set to the mean absolute error loss function MAE:

[0023] Furthermore, step (4) includes: constructing a graph structure for the spatial sequence variables in the multivariate spatiotemporal sequence variables and inputting it into GAT to obtain new spatial features.

[0024] (4.1) Determine the city location using the city’s latitude and longitude information by representing the city’s monitoring sites as nodes in the graph;

[0025] (4.2) With the location of the monitoring station as the center and a circle with a radius of R, all the detection stations within the circle have a corresponding relationship with the station. The edge between two points can be used to construct a graph to obtain the spatial graph structure of the monitoring station;

[0026] (4.3) Perform feature transformation;

[0027] For each node’s feature vector, a linear transformation is first performed to initialize a weight matrix W, whose shape is (dimension of input feature, dimension of hidden feature). The node feature vector is multiplied by the weight matrix W to obtain the linear transformation result of the node feature, which is mapped to a hidden feature space.

[0028] (4.4) Calculate the attention coefficient between nodes;

[0029] For node i and its neighbor node j, the attention coefficient α(i,j) between them is calculated using the following formula:

[0030] α(i,j)=softmax(LeakyReLU(aT[W·h i ||W·h j ]))

[0031] Among them, h i is the feature vector of node i, a is the attention weight vector, T represents the transposition operation, and vector a is transposed, [W·h i ||W·h j ] represents the connection and splicing of node features, W is the weight matrix, and LeakyReLU is an activation function that can increase the nonlinear ability of the network.

[0032] (4.5) Perform weighted aggregation of the attention coefficient and the feature vector of the neighboring nodes;

[0033] h′ i =σ(∑(α(i,j)·W·h j ]))

[0034] Among them, σ represents the activation function, W is the weight matrix, and α(i,j) is the attention coefficient between nodes.

[0035] (4.6) Output updated features;

[0036] Furthermore, step (5) includes: splicing the new features processed by GAT, the air pollution data features after dimensionality reduction, and the historical air quality features along the feature dimension to form a new feature, thereby realizing multivariate spatiotemporal data fusion.

[0037] Furthermore, step (6) constructs a GRU that incorporates attention;

[0038] The internal structure of the gated recurrent neural network GRU is composed of two gates: the update gate and the reset gate, which are used to memorize and filter information. The GRU module combines the node representation. If the hidden state at the previous moment is The current input is By inputting the sequence and the previous hidden state Perform a series of linear transformations to calculate the attention weights:

[0039]

[0040] Among them, W a , W x , U h is the weight matrix

[0041] Then calculate the context vector, using the attention weight vector For the input sequence The specific expression of weighted combination is shown in the following formula:

[0042]

[0043] Among them, the update gate determines the impact of the hidden state of the previous moment on the current moment, and determines the degree of retention of the information passed in from the previous moment unit. The reset gate is responsible for controlling how the hidden state of the previous moment is combined with the input of the current moment, and realizes the screening of the information passed in at the previous moment in the dual attention air quality prediction model. The candidate hidden state is a temporary hidden state. The final hidden state is the weighted sum of the hidden state of the previous moment and the candidate hidden state, and the trade-off relationship is controlled by the update gate. The operation of GRU in this article can be described as shown in the following formula: The reset gate screens past information through the following steps.

[0044]

[0045] in Represents the reset gate, represents the input data at time step t, is the data of the previous time step t-1, and these data are combined with the weight matrix W r Perform multiplication, the context vector with attention weights and the weight matrix C r After multiplication, the two data are added and passed through the Sigmoid activation function to control the output result between 0 and 1. Represents the update gate, and its process is the same as Similarly. ⊙ represents element-by-element multiplication. Represents the memory information of the current time step, which stores the relevant information of the past time steps through the reset gate, Represents the final memory information of the current time step. This paper takes the output of the feature data after graph structure encoding and the detection value of the current air quality monitoring station as input information The final output information is obtained after the entire GRU unit operation.

[0046] Furthermore, in step (8), evaluating the prediction results includes: using the trained dual-attention air quality prediction model to predict the urban air quality data at a specified time step, and using the root mean square error RMSE, R 2 The score and mean absolute percentage error (MAPE) are used to evaluate the predicted and actual air quality values. 2 The closer it is to 0, the poorer the model fitting effect is. It is necessary to return to step (7) to adjust the model hyperparameters. 2 The closer it is to 1, the better the model fitting effect.

[0047] Further,

[0048]

[0049] Where n is the number of sequences, y i is the real urban air quality value, is the predicted value of the model, It is the mean of the actual urban air quality values.

[0050] Compared with the prior art, the present invention has the following significant advantages:

[0051] The present invention fully considers the temporal correlation and spatial correlation of multivariate data from different monitoring sites, uses AE autoencoder for dimensionality reduction from the perspectives of time and space, uses graph attention network and GRU double attention mechanism integrated with attention mechanism to focus on key information, grasp the global spatial and temporal dependencies, complete the spatiotemporal correlation modeling, comprehensively and dynamically process the temporal continuity and spatial propagation characteristics, and further improve the prediction accuracy of multivariate data air quality.

[0052] The present invention has good dynamic continuity when processing multivariate urban air quality data, can meet the needs of quickly and accurately generating prediction results, has high practical application value for urban air quality prediction, can help people understand the air pollution situation in advance and take corresponding health protection measures. It can also warn of the occurrence of air pollution in advance, help relevant government management departments to formulate emergency measures and environmental protection measures in a targeted manner, evaluate and monitor the effects of air pollution control measures, and guide further environmental management and decision-making. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 It is a flowchart of the air quality prediction method based on multivariate data fusion and AGGA network model;

[0054] Figure 2 (a) is a schematic diagram of the attention coefficient calculation process. Figure 2 (b) is a schematic diagram of the weighted aggregation process;

[0055] Figure 3 This is a schematic diagram of the gated recurrent unit structure that incorporates attention. DETAILED DESCRIPTION

[0056] The present invention will be further described below in conjunction with the accompanying drawings.

[0057] like Figure 1 As shown, the air quality prediction method based on multivariate data fusion and AGGA network model specifically includes the following steps.

[0058] (1) Air quality data were obtained from the website of scholar Wang Xiaolei (https: / / quotsoft.net / air) and the China National Environmental Monitoring Center (http: / / www.cnemc.cn / ), meteorological data were obtained from the European Centre for Medium-Range Weather Forecasts (https: / / www.ecmwf.int), and geographic environment data were obtained from the National Geographic Information Center (https: / / www.ngcc.cn / );

[0059] The factors affecting urban air quality include natural factors and human factors. Natural factors include meteorological data and geographical environment data, while human factors include air pollution data. Meteorological data include temperature, air pressure, humidity, wind speed, and underlying surface; geographical environment data include latitude and longitude, and altitude; air quality data include AQI, PM 10 、PM 2.5 , O3, SO2 and NO2.

[0060] (2) Clean and integrate the acquired air pollution data, meteorological data, and geographic environment data;

[0061] Step (2) specifically includes:

[0062] The acquired air pollution data, meteorological data and geographical environment data are cleaned, the data are converted into a unified format, and the processed data are stored in npy format.

[0063] (3) Use the AE model to reduce the dimension of the air pollution data set and obtain the characteristic sequence of air pollution data;

[0064] Step (3) specifically includes:

[0065] (3.1) Constructing the encoder

[0066] The encoder includes an input layer, a hidden layer, and an output layer. The number of dimensions of the input layer depends on the number of air pollution data. The hidden layer is two fully connected layers. The number of dimensions of the hidden layer is set to the number of features that affect air quality in the original sequence data. The number of nodes in the hidden layer is less than the number of nodes in the input layer, and the number of nodes in the input layer is equal to the number of nodes in the output layer. The activation function is set to Leaky ReLU, which is used to make nonlinear changes to the output of each layer.

[0067] (3.2) Constructing the decoder

[0068] The decoder includes an input layer, a hidden layer and an output layer, wherein the input layer receives the output of the encoder, the hidden layer corresponds to the hidden layer structure of the encoder, uses the same number of layers and nodes, and the number of nodes in the output layer is equal to the feature dimension of the original sequence data, which is used to reconstruct the original data;

[0069] (3.3) Use air pollution data as training data to train the weight parameters of the autoencoder, and the loss function is set to the mean absolute error loss function MAE:

[0070] (4) Input meteorological data and geographic environment data into GAT to obtain new spatial features;

[0071] (4.1) Determine the city location using the city’s latitude and longitude information by representing the city’s monitoring sites as nodes in the graph;

[0072] (4.2) With the location of the monitoring station as the center and a circle with a radius of R, all the detection stations within the circle have a corresponding relationship with the station. The edge between two points can be used to construct a graph to obtain the spatial graph structure of the monitoring station;

[0073] (4.3) Perform feature transformation;

[0074] For each node’s feature vector, a linear transformation is first performed to initialize a weight matrix W, whose shape is (dimension of input feature, dimension of hidden feature). The node feature vector is multiplied by the weight matrix W to obtain the linear transformation result of the node feature, which is mapped to a hidden feature space.

[0075] (4.4) Figure 2 As shown in (a), the attention coefficient between nodes is calculated;

[0076] For node i and its neighbor node j, the attention coefficient α(i,j) between them is calculated using the following formula:

[0077] α(i,j)=softmax(LeakyReLU(aT[W·h i ||W·h j ]))

[0078] Among them, h i is the feature vector of node i, a is the attention weight vector, T represents the transposition operation, and vector a is transposed, [W·h i ||W·h j ] represents the connection and splicing of node features, W is the weight matrix, and LeakyReLU is an activation function that can increase the nonlinear ability of the network.

[0079] (4.5) Figure 2 As shown in (b), the attention coefficient is weightedly aggregated with the feature vector of the neighboring node;

[0080] h′ i =σ(∑(α(i,j)·W·h j ]))

[0081] Among them, σ represents the activation function, W is the weight matrix, and α(i,j) is the attention coefficient between nodes.

[0082] (4.6) Output updated features;

[0083] (5) The new spatial features processed by GAT and the feature sequence of air pollution data are integrated with air pollution data, meteorological data and geographic environment data to obtain a new spatiotemporal sequence with attention.

[0084] (6) Figure 3 As shown, an air quality prediction model of the AGGA network model is constructed, and the attention mechanism is integrated into the hidden layer of the GRU. Step (6) specifically includes:

[0085] (6.1) Construct the AGGA air quality prediction model;

[0086] The AGGA air quality prediction model is composed of AE, GAT and GRU with attention. GAT is used to learn the spatial correlation between air quality monitoring sites, and GRU with attention is used to learn the temporal correlation. The new spatiotemporal sequence fused in step (5) is input into the dual-attention air quality prediction model for calculation.

[0087] (6.2) Constructing GRU with attention integration;

[0088] The internal structure of the gated recurrent neural network GRU is composed of two gates: the update gate and the reset gate, which are used to memorize and filter information. The GRU module combines the node representation. If the hidden state at the previous moment is The current input is By inputting the sequence and the previous hidden state Perform a series of linear transformations to calculate the attention weights:

[0089]

[0090] Among them, W a , W x , U h is the weight matrix

[0091] Then calculate the context vector, using the attention weight vector For the input sequence The specific expression of weighted combination is shown in the following formula:

[0092]

[0093] Among them, the update gate determines the impact of the hidden state of the previous moment on the current moment, and determines the degree of retention of the information passed in from the previous moment unit. The reset gate is responsible for controlling how the hidden state of the previous moment is combined with the input of the current moment, and realizes the screening of the information passed in at the previous moment in the dual attention air quality prediction model. The candidate hidden state is a temporary hidden state. The final hidden state is the weighted sum of the hidden state of the previous moment and the candidate hidden state, and the trade-off relationship is controlled by the update gate. The operation of GRU in this article can be described as shown in the following formula: The reset gate screens past information through the following steps.

[0094]

[0095]

[0096] in Represents the reset gate, represents the input data at time step t, is the data of the previous time step t-1, and these data are combined with the weight matrix W r Perform multiplication, the context vector with attention weights and the weight matrix C r After multiplication, the two data are added and passed through the Sigmoid activation function to control the output result between 0 and 1. Represents the update gate, and its process is the same as Similarly. ⊙ represents element-by-element multiplication. Represents the memory information of the current time step, which stores the relevant information of the past time steps through the reset gate, Represents the final memory information of the current time step. This paper takes the output of the feature data after graph structure encoding and the detection value of the current air quality monitoring station as input information The final output information is obtained after the entire GRU unit operation.

[0097] (7) The new spatiotemporal sequence after multivariate data fusion is used to train the AGGA network model to obtain the AGGA air quality prediction model;

[0098] (8) The trained AGGA air quality prediction model is used to predict the urban air quality data at a specified time step, and the root mean square error (RMSE), R 2 The score and mean absolute percentage error (MAPE) are used to evaluate the predicted and actual urban air quality values; if R 2 The closer it is to 0, the poorer the model fitting effect is. It is necessary to return to step (7) to adjust the model hyperparameters. 2 The closer they are, the better the model fit.

[0099]

[0100] Where n is the number of sequences, y i is the real urban air quality value, is the predicted value of the model, It is the mean of the actual urban air quality values.

Claims

1. The air quality prediction method based on multivariate data fusion and AGGA network model is characterized by: include: (1) Obtain air pollution data, meteorological data, and geographic environment data; (2) Clean and integrate the acquired air pollution data, meteorological data, and geographic environment data; (3) Use the AE model to reduce the dimension of air pollution data and obtain the characteristic sequence of air pollution data; (4) Input meteorological data and geographic environment data into GAT to obtain new spatial features; (5) Multi-integrate the new spatial features, air pollution data feature sequences, air pollution data, meteorological data, and geographic environment data to obtain a new spatiotemporal sequence with attention; (6) Integrate the attention mechanism into the hidden layer of GRU; (7) Apply GRU to train the new spatiotemporal sequence to obtain the trained AGGA model; (8) Use the trained AGGA model to predict air quality.

2. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1, characterized in that: The meteorological data include temperature, air pressure, humidity, wind speed, and underlying surface; the geographical environment data include latitude and longitude, and altitude; the air quality data include AQI, PM 10 、PM 2.5 , O3, SO2 and NO2.

3. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: Step (2) includes: cleaning the acquired air pollution data, meteorological data and geographic environment data, converting the data into a unified format, and storing the processed data in npy format.

4. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: Step (3) includes: (3.1) Constructing the encoder The encoder includes an input layer, a hidden layer, and an output layer. The number of dimensions of the input layer depends on the number of air pollution data. The hidden layer is two fully connected layers. The number of dimensions of the hidden layer is set to the number of features that affect air quality in the original sequence data. The number of nodes in the hidden layer is less than the number of nodes in the input layer, and the number of nodes in the input layer is equal to the number of nodes in the output layer. The activation function is set to Leaky ReLU, which is used to make nonlinear changes to the output of each layer. (3.2) Constructing the decoder The decoder includes an input layer, a hidden layer and an output layer, wherein the input layer receives the output of the encoder, the hidden layer corresponds to the hidden layer structure of the encoder, uses the same number of layers and nodes, and the number of nodes in the output layer is equal to the feature dimension of the original sequence data, which is used to reconstruct the original data; (3.3) Use air pollution data as training data to train the weight parameters of the autoencoder, and the loss function is set to the mean absolute error loss function MAE:

5. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: Step (4) comprises: (4.1) Determine the city location using the city’s latitude and longitude information by representing the city’s monitoring sites as nodes in the graph; (4.2) With the location of the monitoring station as the center and a circle with a radius of R, all the detection stations within the circle have a corresponding relationship with the station. The edge between two points can be used to construct a graph to obtain the spatial graph structure of the monitoring station; (4.3) Perform feature transformation; For each node’s feature vector, a linear transformation is first performed to initialize a weight matrix W, whose shape is (dimension of input feature, dimension of hidden feature). The node feature vector is multiplied by the weight matrix W to obtain the linear transformation result of the node feature, which is mapped to a hidden feature space. (4.4) Calculate the attention coefficient between nodes; For node i and its neighbor node j, the attention coefficient α(i,j) between them is calculated using the following formula: α(i,j)=softmax(LeakyReLU(aT[W h i ||W h j ])) Among them, h i is the feature vector of node i, a is the attention weight vector, T represents the transposition operation, and vector a is transposed, [W·h i ||W·h j ] represents the connection and splicing of node features, W is the weight matrix, and LeakyReLU is an activation function that can increase the nonlinear ability of the network; (4.5) Perform weighted aggregation of the attention coefficient and the feature vector of the neighboring nodes; h′ i =σ(∑(α(i,j)·W·h j ])) Among them, σ represents the activation function, W is the weight matrix, and α(i,j) is the attention coefficient between nodes; (4.6) Output the updated features.

6. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: Step (5) includes: splicing the new spatial features processed by GAT, the air pollution data feature sequence and the air pollution data, meteorological data and geographic environment data to form a new feature, thereby realizing multivariate spatiotemporal data fusion and obtaining a new spatiotemporal sequence.

7. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: Step (6) comprises: Constructing a GRU with attention: The internal structure of the gated recurrent neural network GRU is composed of two gates: the update gate and the reset gate, which are used to realize the memory and screening of information. The GRU module will combine the node representation. If the hidden state at the previous moment is The current input is By inputting the sequence and the previous hidden state Perform a series of linear transformations to calculate the attention weights: Among them, W a , W x , U h is the weight matrix, Then calculate the context vector, using the attention weight vector For the input sequence The specific expression of weighted combination is shown in the following formula: Among them, the update gate determines the impact of the hidden state of the previous moment on the current moment, and determines the degree of retention of the information transmitted from the unit at the previous moment, while the reset gate is responsible for controlling how the hidden state of the previous moment is combined with the input of the current moment, and realizes the screening of the information transmitted at the previous moment. In the dual-attention air quality prediction model, the candidate hidden state is a temporary hidden state, and the final hidden state is the weighted sum of the hidden state of the previous moment and the candidate hidden state. The trade-off relationship is controlled by the update gate. The operation of GRU is described as shown in the following formula. The reset gate filters the past information through the following steps: in Represents the reset gate, represents the input data at time step t, is the data of the previous time step t-1, and these data are combined with the weight matrix W r Perform multiplication, the context vector with attention weights and the weight matrix C r The multiplication operation is performed, and then the two data are added and passed through the Sigmoid activation function to control the output result between 0 and 1. Represents the update gate, and its process is the same as Similarly, ⊙ represents element-by-element multiplication, Represents the memory information of the current time step, which stores the relevant information of the past time steps through the reset gate, Represents the final memory information of the current time step, and uses the output of the feature data after graph structure encoding and the detection value of the current air quality monitoring station as input information The final output information is obtained after the entire GRU unit operation.

8. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 1 is characterized in that: In step (8), evaluating the prediction results includes: using the trained dual-attention air quality prediction model to predict the urban air quality data at a specified time step, and using the root mean square error RMSE, R 2 The score and mean absolute percentage error (MAPE) are used to evaluate the predicted and actual air quality values. 2 The closer it is to 0, the poorer the model fitting effect is. It is necessary to return to step (7) to adjust the model hyperparameters. 2 The closer it is to 1, the better the model fitting effect.

9. The air quality prediction method based on multivariate data fusion and AGGA network model according to claim 8, characterized in that: Where n is the number of sequences, y i is the real urban air quality value, is the predicted value of the model, It is the mean of the actual urban air quality values.