The loss function penalizes the network for creating output faces that differ from input faces. The decoder model can be seen as a generative model which is able to generate specific features x’.īoth encoder and decoder are usually trained as a whole. The encoder model turns the input x into a small dense representation z, similar to how a convolutional neural network works by using filters to learn representations. Working components of an autoencoder (self-created) Its goal is to find a way to encode the celebrity faces into a compressed form (latent space) in such a way that the reconstructed version is as close as possible to the input. It gets that name because it automatically finds the best way to encode the input so that the decoded version is as close as possible to the input.Īn Autoencoder is made of a pair of two connected neural networks: an encoder model and a decoder model. Nevertheless, we can train two networks, one that learns the representation, and one that reconstructs from the representation by minimizing the reconstruction loss function. In some cases, we do not have these labels. Networks can learn the specific representations that matter when classifying an image as a dog or cat, assuming we provide them with the correct labels.
A reason why they became popular is their ability to learn representations. Neural networks are one of the many possible methods we can use to obtain a function approximation. By looking at thousands of celebrity faces, a neural network could learn to generate faces of humans who do not exist.