1. Overview of Generative Models
- Definition: Generative models are machine learning models that learn to generate data similar to a given dataset (e.g., images, text, or audio).
- Goal:
- Learn the underlying data distribution.
- Generate new samples that resemble the training data.
2. Generative Adversarial Networks (GANs)
How GANs Work
GANs involve two networks:
- Generator (G):
- Generates synthetic data (e.g., images) from random noise.
- Tries to create data that is indistinguishable from real data.
- Discriminator (D):
- A binary classifier that distinguishes real data from fake data generated by G.
- Adversarial Process:
- G: Maximizes the probability that D classifies its outputs as real.
- D: Tries to minimize misclassifications by distinguishing real vs. fake data.
Loss Functions
-
Discriminator Loss:
-
Generator Loss:
- z: Latent variable sampled from a random distribution.
Applications of GANs
- Image Generation:
- Generate realistic images from random noise (e.g., faces, landscapes).
- Example: StyleGAN creates high-quality human faces.
- Image-to-Image Translation:
- Transform images from one domain to another.
- Examples:
- Day-to-Night conversion.
- Edges-to-Images.