# US 2022/0092433 A1 · Training method and device for generative adversarial network model, equipment, program and storage medium

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2022/0092433 A1
- Document ID: US20220092433A1
- Status: Published application
- Kind: A1
- Application number: 17/457,903
- Filed: 2021-12-06
- Published: 2022-03-24
- Earliest claimed: 2020-12-24
- Assignees: Beijing Baidu Netcom Science Technology Co., Ltd.
- Applicants: Beijing Baidu Netcom Science Technology Co., Ltd.
- Inventors: Hao LIU; Jindong HAN; Hengshu ZHU; Dejing DOU
- Web page: https://patentgrep.com/patent/US20220092433A1

## CPC

- G06N 3/088: Non-supervised learning, e.g. competitive learning
- G06N 3/044: Recurrent networks, e.g. Hopfield networks
- G06N 3/0442: characterised by memory or gating, e.g. long short-term memory [LSTM] or gated recurrent units [GRU]
- G06N 3/045: Combinations of networks
- G06N 3/0475: Generative networks
- G06N 3/08: Learning methods
- G06N 3/09: Supervised learning
- G06N 3/094: Adversarial learning
- G01N 33/0009: {General constructional details of gas analysers, e.g. portable test equipment (devices for withdrawing samples in the gaseous state G01N1/22)}
- G01W 1/02: Instruments for indicating weather conditions by measuring two or more variables, e.g. humidity, pressure, temperature, cloud cover or wind speed (G01W1/10 takes precedence)
- G06N 3/048: Activation functions
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G01N: INVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES (measuring or testing apparatus or processes other than immunoassay, involving enzymes or microorganisms C12M, C12Q)
- G01W: METEOROLOGY (radar, sonar, lidar or analogous systems, designed for meteorological use G01S13/95, G01S15/88, G01S17/95)

## Abstract

Provided are a training method and device for a heterogeneous generative adversarial network model, an equipment, a program and a storage medium. In the training method, measurement data of a heterogeneous station is acquired, the measurement data of the heterogeneous station is set as a training sample, and joint training is performed on the heterogeneous generative adversarial network model according to a total objective function. A generator is configured to predict environment data at a future occasion according to environment data of the heterogeneous station at a historical occasion so as to output predicted data. A discriminator is configured to be input the predicted data output by the generator and corresponding measurement data, and discriminate a similarity between the measurement data and the predicted data; a total objective function includes a first objective function of the generator and a second objective function of the discriminator.

## Claims

### Claim 1

A training method for a heterogeneous generative adversarial network model, wherein the heterogeneous generative adversarial network model comprises a generator and a discriminator, and the method comprises:
acquiring measurement data of a heterogeneous station, wherein the heterogeneous station comprises at least two types of stations, and each type of station among the at least two types of stations is configured to measure and obtain environment data corresponding to the each type as measurement data of the each type of station; and
setting the measurement data of the heterogeneous station as a training sample, and performing joint training on the heterogeneous generative adversarial network model according to a total objective function;
wherein the generator is configured to predict environment data at a future occasion according to environment data of the heterogeneous station at a historical occasion so as to output predicted data;
the discriminator is configured to be input the predicted data output by the generator and corresponding measurement data, and discriminate a similarity between the measurement data and the predicted data; and
the total objective function comprises a first objective function of the generator and a second objective function of the discriminator.

### Claim 2 (depends on 1)

The method according to claim 1, wherein the discriminator comprises at least one of:
a space discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of each station at a set occasion, and discriminate a space similarity between the measurement data and the predicted data at the set occasion;
a time discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of a set station at at least two occasions, and discriminate a time similarity between the measurement data and the predicted data of the set station; or
a macro discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of a plurality of stations at multiple occasions, and discriminate a macro similarity between the predicted data and the measurement data of the generator;
wherein the discriminator is provided with the second objective function.

### Claim 3 (depends on 2)

The method according to claim 2, wherein the total objective function is a weighted sum of second objective functions of a plurality of discriminators plus an accumulated sum of the first objective function.

### Claim 4 (depends on 3)

The method according to claim 3, wherein a formula of the total objective function is expressed as follows:
L=Lg+Σi=1KλiLdi,
wherein L is the total objective function, Lg is the first objective function of the generator, Ldi is a second objective function of a discriminator di, λi is a weight of the discriminator di, the discriminator di is the space discriminator, the time discriminator or the macro discriminator, and k is a number of discriminators.

### Claim 5 (depends on 2)

The method according to claim 2, wherein the space discriminator comprises a graph neural network, a pooling layer and a multilayer perceptron;
input data of the space discriminator is a prediction matrix formed by predicted data of each heterogeneous station at the set occasion and a measurement matrix formed by measurement data of the each heterogeneous station at the set occasion, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Ls of the space discriminator is expressed as follows:
Ls=log Ds(Yt;θs)+log(1−Ds(Ŷt;θs)),
wherein Ds( ) is a space discriminator function, Yt is a measurement matrix, Ŷt is a prediction matrix, and θs is a to-be-trained parameter of the space discriminator.

### Claim 6 (depends on 2)

The method according to claim 2, wherein the time discriminator comprises a gated recurrent model and a multilayer perceptron;
input data of the time discriminator is a prediction sequence formed by predicted data of a set station at a plurality of occasions and a measurement sequence formed by measurement data of the set station at the plurality of occasions, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Lt of the time discriminator is as follows:
Lt=log Dt(yi;θt)+log(1−Dt(ŷi;θt)),
wherein Dt( ) is a time discriminator function, yi is a measurement sequence, ŷi is a prediction sequence, and θt is a to-be-trained parameter of the time discriminator.

### Claim 7 (depends on 2)

The method according to claim 2, wherein the macro discriminator comprises a connecting layer, a gated recurrent model and a multilayer perceptron;
input data of the macro discriminator is a prediction matrix formed by predicted data of each heterogeneous station at a plurality of occasions and a measurement matrix formed by measurement data of the each heterogeneous station at the plurality of occasions;
the connecting layer is configured to splice a vector of each station in each matrix into an occasion vector, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Lm of the macro discriminator is expressed as follows:
Lm=log Dm(Y;θm)+log(1−Dm(Ŷ;θm)),
wherein Dm( ) is a macro discriminator function, Y is a vector of all stations at a prediction occasion, Ŷ is a vector of the all stations at a measurement occasion, and θm is a to-be-trained parameter of the time discriminator.

### Claim 8 (depends on 4)

The method according to claim 4, wherein a formula for calculating the weight λi is expressed as follows:
λ
i
=
exp
⁡
(
γ
i
)
∑
k
=
1
K
⁢
exp
⁡
(
γ
k
)
,
a formula for calculating γi is expressed as follows:
γi=sim(σ(Hi),σ(Ĥi)),
wherein sim( ) is a function based on an Euclidean distance, σ represents a sigmoid function, Hi is a hidden layer vector of the discriminator di when measurement data is input, and Ĥi is a hidden layer vector of the discriminator di when predicted data is input.

### Claim 9 (depends on 1)

The method according to claim 1, wherein the model of the generator is constructed based on a heterogeneous station graph, nodes in the heterogeneous station graph represent stations, types of the stations comprise an air quality monitoring station and a weather monitoring station, and edges are established between stations whose distance from each other within a set distance range.

### Claim 10 (depends on 1)

The method according to claim 1, wherein the setting the measurement data of the heterogeneous station as the training sample, and performing the joint training on the heterogeneous generative adversarial network model based on the total objective function comprises:
setting the measurement data of the heterogeneous station as the training sample, inputting the training sample into the generator, and training a model parameter in the generator based on the first objective function in the total objective function;
inputting the predicted data output by the generator and the corresponding measurement data into the discriminator, and training a model parameter in the discriminator based on the second objective function in the total objective function; and
updating the model parameter of the generator based on the total objective function according to a training result of the discriminator, and entering a next round of training.

### Claim 11

An electronic equipment, comprising:
at least one processor; and
a memory communicatively connected to the at least one processor; wherein
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform a training method for a heterogeneous generative adversarial network model, wherein the heterogeneous generative adversarial network model comprises a generator and a discriminator, and the method comprises:
acquiring measurement data of a heterogeneous station, wherein the heterogeneous station comprises at least two types of stations, and each type of station among the at least two types of stations is configured to measure and obtain environment data corresponding to the each type as measurement data of the each type of station; and
setting the measurement data of the heterogeneous station as a training sample, and performing joint training on the heterogeneous generative adversarial network model according to a total objective function;
wherein the generator is configured to predict environment data at a future occasion according to environment data of the heterogeneous station at a historical occasion so as to output predicted data;
the discriminator is configured to be input the predicted data output by the generator and corresponding measurement data, and discriminate a similarity between the measurement data and the predicted data; and
the total objective function comprises a first objective function of the generator and a second objective function of the discriminator.

### Claim 12 (depends on 11)

The electronic equipment according to claim 11, wherein the discriminator comprises at least one of:
a space discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of each station at a set occasion, and discriminate a space similarity between the measurement data and the predicted data at the set occasion;
a time discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of a set station at at least two occasions, and discriminate a time similarity between the measurement data and the predicted data of the set station; or
a macro discriminator, which is configured to be input predicted data output by the generator and corresponding measurement data of a plurality of stations at multiple occasions, and discriminate a macro similarity between the predicted data and the measurement data of the generator;
wherein the discriminator is provided with the second objective function.

### Claim 13 (depends on 12)

The electronic equipment according to claim 12, wherein the total objective function is a weighted sum of second objective functions of a plurality of discriminators plus an accumulated sum of the first objective function.

### Claim 14 (depends on 13)

The electronic equipment according to claim 13, wherein a formula of the total objective function is expressed as follows:
L=Lg+Σi=1KλiLdi,
wherein L is the total objective function, Lg is the first objective function of the generator, Ldi is a second objective function of a discriminator di, λi is a weight of the discriminator di, the discriminator di is the space discriminator, the time discriminator or the macro discriminator, and k is a number of discriminators.

### Claim 15 (depends on 12)

The electronic equipment according to claim 12, wherein the space discriminator comprises a graph neural network, a pooling layer and a multilayer perceptron;
input data of the space discriminator is a prediction matrix formed by predicted data of each heterogeneous station at the set occasion and a measurement matrix formed by measurement data of the each heterogeneous station at the set occasion, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Ls of the space discriminator is expressed as follows:
Ls=log Ds(Yt;θs)+log(1−Ds(Ŷt;θs)),
wherein Ds( ) is a space discriminator function, Yt is a measurement matrix, Ŷt is a prediction matrix, and θs is a to-be-trained parameter of the space discriminator.

### Claim 16 (depends on 12)

The electronic equipment according to claim 12, wherein the time discriminator comprises a gated recurrent model and a multilayer perceptron;
input data of the time discriminator is a prediction sequence formed by predicted data of a set station at a plurality of occasions and a measurement sequence formed by measurement data of the set station at the plurality of occasions, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Lt of the time discriminator is as follows:
Lt=log Dt(yi;θt)+log(1−Dt(ŷi;θt)),
wherein Dt( ) is a time discriminator function, yi is a measurement sequence, ŷi is a prediction sequence, and θt is a to-be-trained parameter of the time discriminator.

### Claim 17 (depends on 12)

The electronic equipment according to claim 12, wherein the macro discriminator comprises a connecting layer, a gated recurrent model and a multilayer perceptron;
input data of the macro discriminator is a prediction matrix formed by predicted data of each heterogeneous station at a plurality of occasions and a measurement matrix formed by measurement data of the each heterogeneous station at the plurality of occasions;
the connecting layer is configured to splice a vector of each station in each matrix into an occasion vector, and the multilayer perceptron is configured to calculate a probability that the input data is the measurement data; and
a formula of a second objective function Lm of the macro discriminator is expressed as follows:
Lm=log Dm(Y;θm)+log(1−Dm(Ŷ;θm)),
wherein Dm( ) is a macro discriminator function, Y is a vector of all stations at a prediction occasion, Ŷ is a vector of the all stations at a measurement occasion, and θm is a to-be-trained parameter of the time discriminator.

### Claim 18 (depends on 14)

The electronic equipment according to claim 14, wherein a formula for calculating the weight λi is expressed as follows:
λ
i
=
exp
⁡
(
γ
i
)
∑
k
=
1
K
⁢
exp
⁡
(
γ
k
)
,
a formula for calculating γi is expressed as follows:
γi=sim(σ(Hi),σ(Ĥi)),
wherein sim( ) is a function based on an Euclidean distance, σ represents a sigmoid function, Hi is a hidden layer vector of the discriminator di when measurement data is input, and Ĥi is a hidden layer vector of the discriminator di when predicted data is input.

### Claim 19 (depends on 11)

The electronic equipment according to claim 11, wherein the model of the generator is constructed based on a heterogeneous station graph, nodes in the heterogeneous station graph represent stations, types of the stations comprise an air quality monitoring station and a weather monitoring station, and edges are established between stations whose distance from each other within a set distance range.

### Claim 20 (depends on 11)

The electronic equipment according to claim 11, wherein the setting the measurement data of the heterogeneous station as the training sample, and performing the joint training on the heterogeneous generative adversarial network model based on the total objective function comprises:
setting the measurement data of the heterogeneous station as the training sample, inputting the training sample into the generator, and training a model parameter in the generator based on the first objective function in the total objective function;
inputting the predicted data output by the generator and the corresponding measurement data into the discriminator, and training a model parameter in the discriminator based on the second objective function in the total objective function; and
updating the model parameter of the generator based on the total objective function according to a training result of the discriminator, and entering a next round of training.

### Claim 21

A non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform a training method for a heterogeneous generative adversarial network model, wherein the heterogeneous generative adversarial network model comprises a generator and a discriminator, and the method comprises:
acquiring measurement data of a heterogeneous station, wherein the heterogeneous station comprises at least two types of stations, and each type of station among the at least two types of stations is configured to measure and obtain environment data corresponding to the each type as measurement data of the each type of station; and
setting the measurement data of the heterogeneous station as a training sample, and performing joint training on the heterogeneous generative adversarial network model according to a total objective function;
wherein the generator is configured to predict environment data at a future occasion according to environment data of the heterogeneous station at a historical occasion so as to output predicted data;
the discriminator is configured to be input the predicted data output by the generator and corresponding measurement data, and discriminate a similarity between the measurement data and the predicted data; and
the total objective function comprises a first objective function of the generator and a second objective function of the discriminator.
