[SIGIR18] Tutorial on GANs for IR (part2)

My reflection on the GANs for IR tutorial [1], presented by Professor Weinan Zhang.

 

Generative Adversarial Networks (GANs)[2]

Although we don’t know p(x), we can build a discriminator to judge the generated data. If the generated data looks real, the discriminator will accept it. If it does not look real, it will reject it. This is the main idea of GANs.

GANs has two components: a generator G and a discriminator D. The generator takes a noise z sampled from a noise prior p(z) and outputs a generated data \hat x:

\hat x = G(z; \theta)

Where z \sim p(z). The discriminator is a function D(x; \phi) that outputs a probability of x being real. In term of implementation, both generator and discriminator are neural networks.

A good discriminator D should be able to tell if the input data is drawn from the true distribution or is articially contructed.

For the real data, the likelihood of x being detected as real by D should be high:

\max_{\theta} E_{x \sim p_{\text{true}}}\big[f( D(x; \theta))\big]

For the generated data: the likelihood of D detects $\hat x$ as a real data should be low ( or as generated data should be high):

\max_{\theta} E_{\hat x \sim \hat p(x; \phi)}\big[ f( 1 - D(\hat x; \theta)) \big]

Function f is typically a log function because D can be modeled as a bernoulli distribution.

Meanwhile, generator G should try to generate a new data that D cannot detect. It means G needs to maximize the likelihood that D will make a bad detection:

\max_{\phi} E_{\hat x \sim \hat p(x)}\big[ f( 1 - D(\hat x; \theta)) \big]

Hence, the objective function of GANs is bi-level:

\max_{\theta, \phi}E_{x \sim p_{\text{true}}}\big[f( D(x; \theta))\big]  + E_{\hat x \sim \hat p(x)}\big[ f( 1 - D(\hat x; \theta)) \big]

Typically, we can iteratively train discriminator and generator. However, training GANs is tricky and very unstable.

With the optimal discriminator D, the lowerbound of the objective function (payoff) is -\log(4).

Reference:

[1] http://wnzhang.net/tutorials/sigir2018/docs/sigir18-irgan-full-tutorial.pdf

[2] Goodfellow, I., et al. 2014. Generative adversarial nets. In NIPS 2014.