Training a GAN
In this section, we will learn how to train a typical GAN. Then, we will discuss the main challenges and difficulties.
A GAN is trained using unsupervised learning techniques where both submodels are trained simultaneously using a process called adversarial training. A typical GAN consists of two neural networks (usually convolutional neural networks): the generator and the discriminator. The generator takes in a random noise vector as input and generates a synthetic (fake) sample. The goal of the generator is to produce synthetic data that is realistic and indistinguishable from real data. The discriminator, on the other hand, is trained to distinguish between real and fake samples. It receives a sample and predicts its data source domain: real or fake. If the discriminator correctly identifies a real data sample, no error is backpropagated. However, if the discriminator fails to identify a synthetic sample, it is penalized, and the generator is rewarded. The generator...