Air quality prediction method based on contrast multi-view clustering

By comparing multi-view clustering methods for processing air quality data and utilizing three data augmentation techniques and alternating learning of network models, the accuracy and robustness issues of air quality prediction in existing technologies are resolved, achieving high-precision and stable air quality prediction.

CN115758205BActive Publication Date: 2026-02-10CHONGQING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211378423.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-04
Publication Date
2026-02-10
Estimated Expiration
2042-11-04

AI Technical Summary

Technical Problem

Most existing air quality prediction methods use simple neural network models to train a large number of parameters, resulting in information loss and poor robustness, and the prediction results are unreliable under small differences in data.

Method used

A contrastive multi-view clustering method is adopted, which processes air quality data through three data augmentation methods and uses encoder and classifier network models to learn alternately to generate multi-views for air quality prediction.

Benefits of technology

It improves the accuracy and robustness of air quality forecasts, enhances the generalization ability of data, effectively extracts the potential features of air quality data, and reduces data sensitivity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115758205B_ABST
    Figure CN115758205B_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of air pollution monitoring, and particularly relates to an air quality prediction method based on contrast multi-view clustering; the method comprises the following steps: obtaining historical air quality data and to-be-measured air quality data, and classifying the historical air quality data according to air quality indexes; adopting three different data enhancement modes to process the historical air quality data and the to-be-measured air quality data respectively, so as to obtain three kinds of historical enhanced data information and three kinds of to-be-measured enhanced data information; and adopting a contrast multi-view clustering model to classify and predict the air quality of meteorological monitoring stations; the method can improve the accuracy of the to-be-measured air quality data, and can accurately classify the air quality according to the air quality data of target meteorological monitoring stations.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of air pollution monitoring technology, specifically relating to an air quality prediction method based on comparative multi-view clustering. Background Technology

[0002] In recent years, with the increasing number of environmental problems, public attention has gradually focused on air quality, which has now become one of the environmental issues of common concern to society and the public. Multiple factors, such as the distribution of pollution sources, meteorological factors, and the types of pollutants, influence the concentration of pollutants in urban air, and different cities exhibit different distribution characteristics of pollutant concentrations. Air quality prediction models can accurately reflect the distribution trends and spatial characteristics of pollutants in the near-surface atmosphere, and have practical scientific significance for urban air quality prediction and prevention. This is beneficial to promoting socio-economic development. Analyzing air pollutants helps to better understand the composition of air pollutants and the causes of air pollution. Predicting air quality further enhances the scientific rigor, stability, and predictability of optimizing and improving environmental policies, promotes the construction of civilized pilot zones, and thus promotes socio-economic development.

[0003] Therefore, in-depth discussions on the relationships between pollutant concentrations and between meteorological factors and pollutant concentrations, and on predicting air quality, are of great significance for studying urban environmental pollution, air quality issues, and researching effective preventive measures for these problems. Air quality has become a key research subject for scholars in various countries, and many domestic and international scholars have conducted research on it. From the initial Oak Ridge Air Quality Index prediction, to predictions using neural network models, linear regression models, and then to predictions using remote sensing satellite technology, air quality prediction has undergone a technological revolution.

[0004] Based on current experience in the NLP field, the larger the amount of data used in self-supervised pre-training and the more complex the model, the more knowledge the model can absorb, and the better the performance for downstream tasks. However, most existing air quality prediction methods use simple neural network models to train on large amounts of data, which may not only lose a lot of effective information but also incorporate erroneous information into the model. Moreover, data-driven neural network models may be very sensitive to small differences in data, lacking robustness, and thus the prediction results may become unreliable. Summary of the Invention

[0005] To address the above problems, this invention provides an air quality prediction method based on contrastive multi-view clustering, the method comprising:

[0006] Acquire historical air quality data and air quality data to be measured, and classify the historical air quality data according to air quality indicators;

[0007] Three different data augmentation methods were used to process historical air quality data and air quality data to be measured, resulting in three types of historical augmented data information and three types of air quality data to be measured.

[0008] Three types of historical augmented data are input into the encoder network model for re-representation learning to generate three types of historical augmented views;

[0009] Using the classification results of historical air quality data, the category of a third historical augmented view is learned from the categories of two historical augmented views, and the three historical augmented views are learned alternately. The encoder network model is trained by comparative learning.

[0010] The historical augmented view trained by contrastive learning is input into the classifier network model, and the classification results of historical air quality data are combined to train the classifier network model.

[0011] The three sets of augmented data to be tested are input into the trained encoder network model and the trained classifier network model. After clustering, the classification prediction results of the air quality data to be tested are obtained. The beneficial effects of this invention are:

[0012] (1) The present invention has the effect of high precision, and can accurately classify the air quality situation based on the air quality data of the target meteorological monitoring station.

[0013] (2) The present invention uses three different enhancement methods to enhance air quality data. In the training phase, the method of alternating learning of three different historical enhanced views can improve the accuracy of encoder network model and classifier network model. In the testing phase, the method of clustering three different enhanced views to be tested can improve the accuracy of the air quality data to be tested.

[0014] (3) The present invention designs a network model based on contrastive learning to re-represent the air quality data of meteorological monitoring stations, which can fully extract the potential features of air quality data and improve data utilization efficiency.

[0015] (4) This invention is the first to use the contrastive learning method in the field of air quality prediction. It not only enhances the generalization ability of the data, but also effectively extracts useful information from the air quality data, eliminates redundant information, improves the similarity between samples, and achieves efficient data analysis and processing.

[0016] (5) The encoder of the model of the present invention is mainly composed of ResNet. A fully connected layer is added before the final output to predict the data of multiple views separately and then perform clustering processing, which can make the prediction model more robust. Attached Figure Description

[0017] Figure 1 This is a flowchart illustrating an air quality prediction method based on comparative multi-view clustering according to an embodiment of the present invention.

[0018] Figure 2 This is a schematic diagram of the comparative learning structure according to an embodiment of the present invention;

[0019] Figure 3 This is a diagram of the first two layers of the ResNet encoder according to an embodiment of the present invention;

[0020] Figure 4 This is a diagram illustrating the construction of the ResNet residual module in an embodiment of the present invention. Detailed Implementation

[0021] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0022] The present invention aims to use a new data vector representation generated by contrastive learning to achieve data robustness, noise resistance, and reduced data sensitivity.

[0023] For ease of understanding, Figure 1 This is a flowchart of an air quality prediction method based on contrastive multi-view clustering according to an embodiment of the present invention, as shown below. Figure 1 As shown, the method includes:

[0024] 101. Acquire historical air quality data and air quality data to be measured, and classify the historical air quality data according to air quality indicators;

[0025] In this embodiment of the invention, the air quality data is divided into historical air quality data and air quality data to be measured. The historical air quality data is air quality data with partially or fully known AQI indicators, including AQI indicators, air temperature, air humidity, and the geographical location of meteorological monitoring stations. The air quality data to be measured is air quality data with partially or fully unknown AQI indicators, including air temperature, air humidity, and the geographical location of meteorological monitoring stations.

[0026] In this embodiment of the invention, when classifying the air quality results of historical air quality data, offline processing can be used, that is, the air quality of each meteorological monitoring station can be set to five levels: A, B, C, D, and E according to the AQI index.

[0027] 102. Three different data augmentation methods were used to process historical air quality data and air quality data to be measured, resulting in three types of historical augmented data information and three types of air quality data to be measured.

[0028] In this embodiment of the invention, both historical air quality data and air quality data to be measured need to be augmented. This is different from traditional neural network models. The purpose of augmenting historical air quality data in this invention is mainly to optimize the encoder network model and classifier network model, while the purpose of augmenting air quality data to be measured is mainly to optimize the input air quality data to be measured and enhance the expressive power of the air quality data to be measured.

[0029] In this embodiment of the invention, considering the significant impact of data augmentation on the final training results, we need to reduce irrelevant features in the dataset. For image data, the common practice is to perform operations such as translation, cropping, scaling, and rotation on the images. Although this invention does not process image datasets, it can still perform data augmentation through other means to prevent the neural network from learning irrelevant features, thereby fundamentally improving the overall performance. In addition to conventional data augmentation methods, this embodiment provides three preferred data augmentation methods, including: 1) using a generative adversarial network to generate augmented data from the input air quality data; 2) adding noise generated by a generative adversarial network to the input air quality data to generate augmented data; 3) using an unsupervised training method of a variational autoencoder and a perturbation training mechanism to generate augmented data from the input air quality data.

[0030] For method 1), this embodiment utilizes adversarial training of a GAN network to generate new augmented data. Generative Adversarial Networks (GANs) are deep learning models and one of the most promising unsupervised learning methods on complex distributions in recent years. The model produces reasonably good outputs through the game-like learning of at least two modules within the framework: a generative model and a discriminative model. In the original GAN ​​theory, it is not required that G and D be neural networks; they only need to be able to fit the corresponding generative and discriminative functions. However, in practice, deep neural networks are generally used as G and D. A good GAN application requires a good training method; otherwise, the freedom of the neural network model may lead to unsatisfactory outputs.

[0031] The steps we take to train augmented data using a GAN network are as follows:

[0032] The first step is to randomly sample from the air quality noise data distribution, input it into the generative model, and obtain a set of fake data, denoted as D(z);

[0033] The second step is to randomly sample from the real data distribution, i.e., the input air quality data distribution, and use this as the real data, denoted as x.

[0034] The data generated in one of the first two steps is used as the input to the discriminant network (therefore, the input to the discriminant model consists of two types of data, true and false). The output of the discriminant network is the probability that the input belongs to the real data, with 1 for true and 0 for false. Generative adversarial methods are achieved through binary classification.

[0035] The third step is to calculate the generation loss function and the discriminant loss function based on the discrimination probability.

[0036] Fourth, based on the loss functions of the discriminant and generator models, the parameters of the GAN model can be updated using the backpropagation algorithm. (First, the parameters of the discriminant model are updated, and then the parameters of the generator are updated using the resampled noisy data). Gradient update:

[0037]

[0038] Wherein, logD(x) (i) ) is the real sample x (i) The discrimination; z (i) The noise to be sampled is first fed into the generator G(), then into the discriminator D() for discrimination, and finally the gradient of the discriminator parameters is calculated. This indicates the gradient calculation, where θ and d are the discriminator parameters.

[0039] For method 2), this embodiment can use the error loss in method 1) to generate new enhanced data. Specifically, a generative adversarial network is used to calculate the error loss between the input air quality data and the generated air quality data. The derivative of the error loss is calculated to obtain the gradient loss. The ratio of the gradient loss to the number of times the generative adversarial network generates data is used as noise, and the noise is superimposed on the input air quality data to generate enhanced data. This method not only utilizes different enhancement methods to obtain different types of enhanced data, but also saves computational costs. At the same time, it only adds a small perturbation to the input air quality data and does not affect the data classification effect.

[0040] For method 3), VAE's unsupervised training method and perturbation training mechanism make the training data and perturbation data have a high similarity in the Latent Space (KL divergence loss), which allows us to perform data augmentation very well.

[0041] In simple terms, VAE (Variable Embedding) adds a perturbation (or constraint) to the learned encoder's encoding to generate a new embedding. The process is as follows:

[0042] The first step is to use a deep learning network to project the input X into a latent space using an encoding method (that is, an encoding model, called the Encoder process). In this way, we can obtain the latent state encoding (Representation in Latent Space) of all input X.

[0043] The second step involves constructing two layers (μ, σ) to be learned based on the hidden state encoding described above. A random number ε is set, and a new perturbation data point z is randomly obtained according to the parameters (μ, σ). This process is repeated multiple times to obtain a dataset (Z', X').

[0044] The third step is to train a neural network with input and output (Z', X'). The process of remapping the perturbation data z back to the original input data x is called the Decoder process.

[0045] 103. Input the three types of historical augmented data information into the encoder network model, perform re-representation learning, and generate three types of historical augmented views;

[0046] Figure 2 This is a schematic diagram of the comparative learning structure in an embodiment of the present invention, as shown below. Figure 2 As shown, after applying three data augmentation methods to the original air quality data X, three different historical augmented data X1, X2, and X3 are obtained. The three historical augmented data are then passed through the encoder of the encoder network model to obtain coded features z1, z2, and z3. The coded features z1, z2, and z3 are then passed through the projector of the encoder network model to output historical augmented views v1, v2, and v3. Finally, the corresponding dot product results q1, q2, and q3 can be obtained from the classification results.

[0047] In this embodiment of the invention, the encoder network model can adopt the existing ResNet encoder network, and the ResNet network architecture is as follows:

[0048] The first building block consists of a regular convolutional layer and a max pooling layer.

[0049] The second building layer consists of three residual modules. The architecture diagram of the first two layers is as follows: Figure 3

[0050] The third, fourth, and fifth construction layers all begin with a downsampling residual module, followed by 3, 5, and 2 residual modules respectively. Their construction diagrams are shown below. Figure 4 .

[0051] The predicted view data is updated in a different way:

[0052] The hierarchical encoding method gradually slows down the update process of the predicted view data.

[0053] Assuming the upper encoder parameter θ q The lower-level encoder parameter is θ k The parameter update method of the lower-level encoder is defined as follows:

[0054] θ k =mθ k +(1-m)θ q ,

[0055] Here, m∈(0,1), as mentioned above, setting m to a larger value makes the encoder parameters of the predicted view data update more smoothly.

[0056] In this embodiment of the invention, by inputting historical augmented data information into the encoder network model, the encoder network model can be used to encode the historical augmented data information, that is, to relearn the representation, and generate a historical augmented view. This historical augmented view can reflect more effective information about air quality data.

[0057] 104. Using the classification results of historical air quality data, the category of the third historical augmented view is learned from the categories of the two historical augmented views, and the three historical augmented views are learned alternately. The encoder network model is trained by comparative learning.

[0058] In this embodiment of the invention, the classification product of each historical augmented view and the corresponding classification result is calculated respectively. The classification distance between the classification product of two historical augmented views and the classification product of the third historical augmented view is used to train the encoder network model by reducing the classification distance between the two historical augmented views and the third historical augmented view.

[0059] Specifically, based on the previous results of classifying historical air quality data according to air quality indicators, this embodiment multiplies the data representations of historical enhanced views v1, v2, and v3 with the data classification results, obtaining multiplication results q1, q2, and q3 respectively. Two of these enhanced views are then used to predict the category of the third enhanced view, narrowing the distance between their respective categories. Therefore, this invention does not directly compare the features of air quality influencing factors, but rather compares the similarity of the multiplication results. Through backpropagation, the parameters of the convolutional layers can be iteratively learned, thereby achieving accurate training results.

[0060] Considering the potential errors introduced by the above method, this invention can also perform a prediction for each of the three layers. For each prediction, a fully connected layer (after global average pooling) is added after both predicted views. This layer has a fixed-dimensional output. This output vector is normalized using its L2 norm.

[0061] The loss function used to train the encoder network model is expressed as:

[0062] Loss = dis(v i cv k c)+dis(v j cv k c)

[0063] Where dis represents the distance function, v i and v j This indicates two of the history enhancement views, v k Let represent the third historical augmented view, and c represent the classification result of the historical augmented view. Here, ijk represents the air quality data of the same meteorological monitoring station at the same time. Although different data augmentations are performed on the air quality data at the same time, their classification results c should be consistent. Therefore, we use two historical augmented views to learn the characteristics of the third historical augmented view, thereby improving the robustness and accuracy of the network model.

[0064] 105. Input the historical augmented view trained by contrastive learning into the classifier network model, and train the classifier network model by combining the classification results of historical air quality data;

[0065] In this embodiment of the invention, the classifier network model is trained in a supervised manner using known classification results of historical air quality data, thereby improving the accuracy of the classifier network model.

[0066] 106. Input the three augmented data information to be tested into the trained encoder network model and the trained classifier network model, and obtain the classification prediction results of the air quality data to be tested through clustering.

[0067] In this embodiment of the invention, steps 103-105 involve training the encoder network model and the classifier network model using historical augmentation data. Once the model training is complete, the augmentation data to be tested can be predicted and classified. That is, the augmentation data to be tested is input into the trained encoder network model for re-representation learning, generating three augmentation views to be tested. The augmentation views to be tested are then input into the trained classifier network model, and the classification prediction results of the air quality data to be tested are obtained through clustering.

[0068] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, which may include ROM, RAM, disk, or optical disk, etc.

[0069] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. An air quality prediction method based on contrastive multi-view clustering, characterized in that, The method includes: Acquire historical air quality data and air quality data to be measured, and classify the historical air quality data according to air quality indicators; Three different data augmentation methods are used to process historical air quality data and air quality data to be measured, resulting in three types of historical augmented data information and three types of air quality data to be measured. The three different data augmentation methods include: using a generative adversarial network (GAN) to generate augmented data from the input air quality data; adding noise generated by a GAN to the input air quality data to generate augmented data; and using an unsupervised training method with a variational autoencoder and a perturbation-based training mechanism to generate augmented data from the input air quality data. Three types of historical augmented data are input into the encoder network model for re-representation learning to generate three types of historical augmented views; Using the classification results of historical air quality data, the category of a third historical augmented view is learned from the categories of two historical augmented views, and the three historical augmented views are learned alternately. The encoder network model is trained through contrastive learning. The contrastive learning training of the encoder network model includes: calculating the classification product of each historical augmented view and its corresponding classification result; using the classification distance between the classification product of two historical augmented views and the classification product of the third historical augmented view; and training the encoder network model by reducing the classification distance between the two historical augmented views and the third historical augmented view. The loss function used to train the encoder network model is expressed as follows: in, Represents the distance function. and This indicates two of the history enhancement views. This indicates the third history enhancement view. This indicates the classification results of the historical augmented view; The historical augmented view trained by contrastive learning is input into the classifier network model, and the classification results of historical air quality data are combined to train the classifier network model. The three sets of augmented data to be tested are input into the trained encoder network model and the trained classifier network model. After clustering, the classification prediction results of the air quality data to be tested are obtained.

2. The air quality prediction method based on comparative multi-view clustering according to claim 1, characterized in that, The historical air quality data includes AQI index, air temperature, air humidity, and the geographical location of meteorological monitoring stations; the air quality data to be measured includes air temperature, air humidity, and the geographical location of meteorological monitoring stations.

3. The air quality prediction method based on comparative multi-view clustering according to claim 1, characterized in that, The process of generating enhanced data from the input air quality data using a generative adversarial network includes: randomly sampling the distribution of air quality noise data; inputting the randomly sampled air quality noise data into the generation model to output false air quality data; randomly sampling the distribution of the input air quality data as real air quality data; and inputting the false air quality data and real air quality data into the discrimination model to obtain the discrimination probability, respectively. The generation loss function and the discrimination loss function are calculated based on the discrimination probability. The generation model and the discrimination model are trained adversarially, and the parameters of the adversarial generative network are updated using the backpropagation algorithm. When the generation loss function and the discrimination loss function converge, the augmented data corresponding to the input air quality data is obtained using the generative adversarial network.

4. The air quality prediction method based on comparative multi-view clustering according to claim 1, characterized in that, The process of adding noise generated by a generative adversarial network to the input air quality data to generate enhanced data includes: using a generative adversarial network to calculate the error loss between the input air quality data and the generated air quality data; differentiating the error loss to obtain the gradient loss; using the ratio of the gradient loss to the number of times the generative adversarial network generates data as noise; and superimposing the noise onto the input air quality data to generate enhanced data.

5. The air quality prediction method based on comparative multi-view clustering according to claim 1, characterized in that, The method of generating augmented data by using an unsupervised training method of variational autoencoder and a perturbation training mechanism for the input air quality data includes: projecting the input air quality data x onto a certain latent space through a deep learning network to obtain a latent state encoding; constructing two learning layers based on the latent state encoding to learn the first parameter μ and the second parameter σ respectively; and randomly obtaining a new perturbation data based on the first parameter μ and the second parameter σ. Repeat the iterations multiple times to obtain a perturbation dataset; use the perturbation dataset as augmentation data.

Citation Information

Patent Citations

  • Variation auto-encoder and extreme learning machine-based air quality prediction method

    CN108197736A

  • Air quality prediction optimization method based on generative adversarial network

    CN114565136A