Generative Adversarial Networks(GANs in short) are unsupervised learning models that belong to a set of algorithms called generative models. These models are typically used to generate information, such as pictures. GANs learn how to mimic the given data distribution. That is, GANs can be taught to create worlds similar to our own in any domain: images, music, speech, prose and thus are extensively used in image generation, video generation and voice generation.

Through this article, we will demonstrate how the Deep Convolutional GAN (DCGAN) can be used to generate the new car models when trained on the dataset having images of car models. In this article we deal with:

  • The architecture and working of a GAN
  • How a DCGAN is different from Vanilla GAN
  • Code to build car models using DCGAN

So let’s get started!


The architecture and working of a GAN

The GAN architecture contains two neural networks that compete with one another to generate data that is closely related to the real data. The two models used in GANs are the generative model and the discriminative model.

Think of the discriminative model as your regular classification model. It takes in the input data, understands the features of it and predicts the data into a label or category. These models are concerned with the correlation between input and target and map the features to labels.

Contrary to this, the generative model attempts to predict the image, given a label or category. They try to model the distribution of individual labels. So, how do these two models work together?

Let us understand the working of these models with an example. Suppose you want to generate handwritten digits like the MNIST dataset. Now, the job of the generative model is to create new data that is as close as possible to the real one and pass it onto the discriminator. The goal of the generator is to lie and not get caught! It hopes that the synthetic images it has generated will be deemed authentic by the discriminator, though they are fake.

The discriminator, on the other hand, has to analyse the real data and the fake ones and classify them as authentic or not (0 or 1).


#developers corner #gan #deep learning

Hands-On Guide To Generate Car Models Using Deep Convolutional GAN
1.15 GEEK