A generative adversarial network (GAN) is a deep learning model where two neural networks are set up to compete against each other (hence ‘adversarial’) to generate the most accurate and authentic data from a training dataset.
In a GAN, one network (called the generator network) takes input data samples and modifies it as much as possible to generate brand new data. Thereafter, the other network (called the discriminator network) attempts to predict if the generated data is real or fake i.e. whether or not it belongs to the original dataset. It is a zero-sum framework where the generator’s win is the discriminator’s loss – and vice versa.
If the discriminator deems the data as fake, the generator network generates a new, improved data value. This cycle continues until equilibrium i.e. the discriminator network classifies the data as real and can no longer tell it apart from the original. The generator network attempts to maximize the probability of an erroneous determination by the discriminator network while the discriminator seeks to minimize the probability of error.
The applications of GAN include:
- Generating images:
- Digital entertainment – Develop an immersive and realistic visual experience in video games and animation by creating new images, faces and characters from text-based prompts and/or modifying existing images in an extensive database.
- Create foundational training data for other models – Create synthetic foundational data that can then be used to train an actual task-specific model such as a fraud-detection system on distinguishing between genuine and suspicious transactions.
- Predict and fill missing information:
- Convert low-resolution or black-and-white images into high resolution or color images.
- Generate images of sub-surface (underground) areas by training models on existing subsurface images and using terrain maps.
- Create 3D-models from 2D scanned images or photos. For example, X-rays and body scans to generate realistic images of organs for simulation or surgical planning.
- Create original music from a collection of songs.