The GAN's — short for Generative Adversarial Network — adversarial game is famously hard to keep stable. Diffusion models sidestep the contest entirely with a strange trick: deliberately destroy the data with noise, step by step, until nothing recognizable is left — then train a model to undo exactly one small step of that destruction at a time.
The forward process (top row) is fixed and requires no learning at all — just mix in a little more noise at every step, according to a fixed schedule, until the data is almost unrecognizable. The reverse process (bottom row) undoes it one step at a time. With a perfect denoiser, reversing recovers the original value exactly — the same numbers, in reverse order.
Forward, adding noise at step : , where is how much noise this step adds and . Reverse, removing it, given a predicted noise from a trained model:
- — the (increasingly noisy) value at step .
- — the value one step earlier: less noisy, one step closer to the original data.
- — how much noise step adds to the signal, fixed by a schedule.
- — shorthand for : how much of the previous signal survives this step.
- — the trained model's predicted noise at step , used to undo the forward step.
- Reverse is the forward equation, solved backward
This is exactly the forward equation solved for .
- A perfect predictor exactly inverts it
If equals the true at every step, this exactly inverts the forward process.
- Training reduces to one question
The entire training problem reduces to one question: can a network predict, from a noisy , what noise was added to get there?
Drag the denoiser's quality down from perfect (1) toward clueless (0, always predicting zero noise). The reconstructed value drifts further from the true — but even at quality , it lands closer to than the pure-noise starting point did, because the scaling alone pulls values back toward a reasonable range at every step. A real diffusion model's whole job is training that noise predictor well enough to close this gap.
- Forward — destroy the signal
With noise schedule (so ) and fixed noise samples :
- Reverse with a perfect denoiser
Running the reverse formula with set to the exact same true noise, from backward:
Exactly retraces those numbers backward.
- Reverse with a useless denoiser
Same formula, but every , from backward:
The right neighborhood, but nowhere near exact, because every step's error compounds into the next.
Raise the denoiser’s quality until the reconstructed x0 is within 0.1 of the true value, 5.
No adversary, no minimax game — just a single, well-behaved supervised prediction task (predict the noise) repeated at every step, chained together to generate a full sample. That stability is the main reason diffusion models became the dominant approach for high-quality image generation. This closes Part IV: from raw pixels and sequences, through convolutions, recurrence, attention, and now generative models, every architecture in modern deep learning traces back to the same gradient descent and chain rule from Part II and III. Architectures get a second pass later in the course — GRUs, ResNets, BERT, Vision Transformers, and more — once evaluation, tuning, and a few more classical models have had their turn.