Generative adversarial network overview

GANs make use of two networks:

  • Generator network
  • Discriminator network

For the generator network, noisy data, which is usually random numbers that have been generated from a standard normal distribution are provided as input. A flow chart showing an overview of a generative adversarial network is as follows:

As indicated in the preceding flowchart, the generator network uses noisy data as input and tries to create an image that we can label as fake. These fake images, along with the labels representing them as fake, are provided as input to the discriminator network. Along with the labeled fake images, we can also provide real images with labels as input to the discriminator network.

During the training process, the discriminator network tries to differentiate between a fake image created by the generator network and a real image. While developing a generative adversarial network, this process continues so that a generator network tries its best to generate an image that a discriminator network cannot classify as fake. At the same time, the discriminator network gets better and better at correctly discriminating between a fake and a real image.

Success is achieved when the generator network learns to consistently produce images that are not available in the training data and the discriminator network is unable to classify them as fake. For the real images in this chapter, we will make use of MNIST train data that contains images of handwritten digits.

In the upcoming sections, we will illustrate the steps we need to follow in order to develop a generative adversarial network for the handwritten digit five, which is available in the MNIST data.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset