In this chapter, we created a model that can take images of faces as input and generate faces as output. We used images from the labeled faces in the wild dataset. Using a GAN model, we generated an image with random values and then sampled an actual image. To generate an image, we took random values and reshaped them to the dimensions of the images in our dataset. We then fed this image—composed of random values—along with an actual image, to a model that reshaped the data down to a simple probability score, representing the likelihood that an image is real or fake. Through multiple iterations, the generator was trained to create images that were increasingly likely to be classified as real by the discriminator model. Â
In our next chapter, we will learn about another unsupervised deep learning technique called reinforcement learning. It is similar...