AI Hero Club
← Course Overview

LEARNING PLAN/ Progress

Diffusion Models and Flow Matching

Derive DDPM, scores, and Flow Matching from probability and noise. Train a two-dimensional velocity network, then use numerical integration and statistical tests to expose generation failures.

Start with a question, derive the mechanism, then test your implementation with new inputs.

Spread Model and Slow Matching
8 Chapter / Same full itemChapter study advice 22 hours 40 minutesSeparate exercise and project reserve 17 hours 20 minutes

Times are author estimates that include derivation and practice. They have not been measured with learners; work through the sections at your own pace.

WHAT YOU WILL BUILD

What will you build to demonstrate understanding?

  • Indication DDPM forward edge and reverse Gaussian back-check
  • Connect noise prediction, score and probability stream ODE
  • Prove the low Matching target by conditionalities
  • Training of 2D speed network and auditing of gradients for full parameters
  • Failed to compare Euler/Heun accuracy, call cost and distribution
What should you know before starting?
  • Reads and writes Python and Jang Operations
  • Possibility of average, co-opportunities and conditions
  • Understanding the guides, gradients and basic credits

Use the prerequisites to choose a starting point. You can read freely and return to earlier lessons whenever you need them.

THE LEARNING ROUTE

A clear path, one step at a time.

Marked Complete by You0 / 8

Saved in this browser only. Marking a lesson complete does not mean the project has passed verification.

01

Objectives and proliferation mechanisms

From the two-dimensional distribution, deduce DDPM forward and backward.

01

Probability Objectives, Mixtures and Noise Paths

If a random generator draws four clusters, how can we tell whether it learned their internal distributions rather than four centers?

150 minutes ↗
02

DDPM Forward Chains, Cumulative Noise and Training Targets

After repeated Gaussian noise additions, how can we directly express the sample distribution and training target at any step?

160 minutes ↗
03

DDPM Posteriors, Variational Objectives and Reverse Sampling

Given a noisy sample and a clean endpoint, how do we compute the previous-step Gaussian posterior and connect it to training?

180 minutes ↗
02

Continuous Path and Solver

Connects to score, probability stream withlow Matching, comparing points error.

04

Scores, Denoising Identities and Probability-flow ODEs

Why does the same density evolution use a score coefficient of one-half in the probability-flow ODE and one in the reverse SDE?

180 minutes ↗
05

Conditional Flow Matching and Marginal Velocity Fields

Each conditional straight path has its own velocity. Why can regression on those targets recover the marginal velocity field?

180 minutes ↗
06

Euler, Heun and Separable Sampling Errors

If coarse steps make a correct velocity field generate poor samples, how do we separate network error from integration error?

170 minutes ↗
03

Training and distribution inspection

A 2-dimensional speed network is actually trained to test generation and failure at the same site.

07

Train a 2D Velocity Network and Verify Numerical Gradients

When regressing random endpoint differences, how do we check that every network parameter learns and explain a nonzero loss floor?

170 minutes ↗
08

Statistical Validation, Deliberate Failures and Joint Verification

When one frozen model sometimes looks good, how can multiple seeds and complementary metrics expose distributional failures?

170 minutes ↗

BUILD / TEST / TRANSFER

Four two-dimensional neurogenesis labs.

Train two-dimensional low Matching network using PyTorch 2.6 at CPU single-line to compare teachers, Euler/Heun grids and failure baselines with the same frozen checkpoint.

Runtime Requirements
Python 3.12 and PyTorch 2.6.0 are recommended. A CPU is sufficient; see the project README for installation instructions.

Download the Project ↓

Read the README after extracting the archive, then follow its environment and run instructions. Reference implementations and learning tasks are provided separately.

Project Checklist

This is a personal checklist, not an automatic grade. Keep your inputs, results, failures and reproduction commands.