Diffusion Models, the Light Maths Version
Follow the maths of diffusion models: noise schedules, denoising objectives and guidance
A taste of a lesson
In the guidance formula, why does a big w make colours oversaturated instead of just following the prompt better?
Look at the formula: e_guided = e_uncond + w * (e_cond - e_uncond). The bracket is the direction that makes the image more prompt like. With w = 1 you get the plain conditional prediction. With w = 7 you move seven times along that direction, past anything the model saw in training. Each step overshoots, pixel values get pushed to extremes, and you see saturation and harsh contrast. Quick exercise: if e_uncond = 0.2 and e_cond = 0.5 for one value, what is e_guided at w = 3?
Written by the teacher as an example. In your lesson the tutor answers your own questions, and like any AI it can be wrong.
What you will be able to do
- Write and explain the forward noising equation
- Explain why the training loss is a squared error on predicted noise
- Describe sampling, latent diffusion and text conditioning
- Compute and interpret classifier free guidance
Lesson plan
- 1 Noise and the forward process Understand how images are gradually turned into Gaussian noise. Start
- 2 The training objective See why predicting the noise with squared error loss teaches denoising. Start
- 3 Sampling: running it backwards Follow how samplers turn noise into an image step by step. Start
- 4 Latents and text conditioning Explain latent diffusion and how prompts enter the network. Start
- 5 Classifier free guidance Compute guided predictions and explain the effect of the guidance weight. Start
- 6 Flow matching and what comes next Relate flow based models and distillation to classic diffusion. Start
Try asking
About this tutor
For technical learners, developers and students who want to understand diffusion models properly but without a full research background. With light maths (Gaussian noise, averages, simple equations) you will learn the forward noising process, what the network is trained to predict, why the training loss is a simple squared error, how sampling reverses the process, how latent diffusion and text conditioning work, what classifier free guidance computes, and how newer flow based formulations relate. You will be able to read model cards and paper summaries with understanding.
Reviews
Students can review a tutor after a paid lesson. Nobody has yet.
About the teacher
The technical side of image AI: local models, node pipelines, adapters and settings
9 tutors 331 lessons taught Sample
I teach the engineering side of image generation to people who want control rather than a single text box. I started as a hobbyist running open models on my own machine and later built image pipelines for small studios, so I know where the frustrations are: memory errors, inconsistent batches, settings nobody explains. I teach from first principles, then from...
See Quentin's profile and tutorsMore like this
Other tutors on the same or nearby topics.