TL;DR
A diffusion model is trained to predict something from a noisy input. The usual choice is the noise that was added. v-prediction asks the network for a different target: a weighted difference of the noise and the clean data. Salimans and Ho introduced it in 2022, and it keeps the target at a similar size whether the input is nearly clean or nearly pure noise. That makes training steadier and makes it easier to sample in only a few steps.
Builds on: Diffusion Model, Signal-to-Noise Ratio, Gaussian (Normal) Distribution · Leads to: Progressive Distillation, Imagen Video
Where it's used
Image generators. Some Stable Diffusion 2 checkpoints, the ones trained at 768 pixels, were released as v-prediction models. A sampler has to know which target a network was trained for, or the output comes out washed out or noisy.
Video. Imagen Video uses v-parameterisation in its cascade of diffusion models. CogVideoX also uses v-prediction, together with a fix for the final noise level, so a video model with many frames per clip gets a well-scaled training target.
Few-step samplers. The method was introduced alongside Progressive Distillation, which trains a fast student to do in one step what a teacher does in several. The student's targets must stay well behaved when each step is large, and v-prediction is what keeps them stable.
How it works
Take one number as the data, to keep the arithmetic visible. Let be the clean value and the noise. Pick a point on the schedule where and . These satisfy , so .
- Start with the clean value and the noise. and . Nothing is mixed yet. Check: both are plain numbers.
- Mix them into the noisy input. . Check: the network sees one number and must work out how it was made.
- Build the v target. . Check: is another mix of the same two quantities, with the signs and weights changed.
- Ask the network for v and score it. Suppose it predicts . The loss is . Check: the loss is zero only when the prediction matches exactly.
- Turn the prediction into a clean estimate. . Check: this is close to the true , and the error came from the prediction error of in .
- Recover the noise from the same output. . Check: one network output gives both the clean estimate and the noise, so the choice of target does not limit what the sampler can use.
The plot shows the two weights that define the target. Their squares always add to one, so the target never loses its scale.
- alpha, weight on the noise-free part
- sigma, weight on the noise
The math
A squared-error objective trains the network on whichever target is chosen. Write the noisy input as a mix of data and noise, with and .
For data , noise and a noisy input with , the v-target is
A network is trained to output it.
Steps 1 and 2 in symbols: the noisy input
The noisy input is the same mix as in the diffusion model lesson, . The condition means the two weights are the sine and cosine of one angle. That is why the plot is a quarter circle. The condition is what keeps the variance of fixed when the data and noise both have unit variance.
Step 3 in symbols: the target
The target is the rotated pair with weights and . Because the weights come from the same angle as the input, the target can be written from the input and the prediction alone. Two inverse formulas recover the clean value and the noise:
Check that the first one is correct. Substitute and : . The noise terms cancel, which is the whole point of the construction.
Step 4 in symbols: the loss
Training minimises the expectation of a loss, here the squared error:
Each draw of , data and noise gives one squared-error term, the same shape as the noise-prediction loss. Only the target changed.
Steps 5 and 6: why the target is better scaled
Suppose instead the network predicts the noise, and the clean estimate is . An error in becomes an error in . Near the high-noise end is close to zero, so this error is amplified. With v-prediction the clean estimate is , so an error in becomes , which is never larger than because .
If the data and noise both have unit variance and are independent, then at every step. The target has the same size everywhere on the schedule.
Worked examples
Take , , , .
- Check the weights: .
- Noisy input: .
- Target: .
- Recover the clean value: .
- Interpretation: the round trip returns the original exactly, so the target throws away no information about the clean value.
Use the same point as the example above, with , and let the network predict where the truth is .
- Loss term: .
- Clean estimate: , against the true .
- Noise estimate: , against the true .
- Interpretation: the single prediction error of in shows up as errors of about in the clean value and in the noise. The two readings move together because they come from the same output.
A late step in a long schedule has , so and . Suppose the network is off by in its output, whichever target it was trained on.
- Noise-prediction route: , so the error in is .
- v-prediction route: , so the error in is .
- Compare: the same 0.1 mistake is fifty times more damaging on the noise route, because .
- Interpretation: this is why noise prediction struggles at the very noisy end of a schedule, where the clean estimate is most sensitive to the network's output. v-prediction keeps that sensitivity bounded.
Try it: at , so , the same error in the noise output is amplified to what size in ? How many times larger is it than the v-route error? Answer: , which is times the v-route error of about , because .
Common mistakes and tradeoffs
It is tempting to think v is a new kind of noise. In fact it is a mix of the noise and the clean data with the weights and . It adds no new randomness, and the clean data is recovered from it exactly once the noisy input is known.
It is tempting to think switching to v needs a new network or new training data. In fact the architecture and the loss have the same form. Only the target changes, and the sampler converts the output to whichever quantity it needs.
It is tempting to think v is always better. In fact the gain is largest at the high-noise end and for few-step sampling. With many steps on standard images, noise prediction often works just as well, so the choice is a matter of which regime the model is for.
| Situation | Noise prediction | v-prediction |
|---|---|---|
| Many sampling steps, moderate resolution | Works well | Works well |
| Few-step sampling or distillation | Less stable at the noisy end | Keeps the target well scaled |
| Very long schedules reaching pure noise | Clean estimate amplified near the end | Bounded sensitivity |
A real cost is that the checkpoint fixes the parameterisation. A sampler that assumes noise prediction, given a v-prediction checkpoint, reads as and produces degraded output. Always convert with the formulas above.
History
Ho, Jain and Abbeel's 2020 paper trained diffusion models to predict the noise, and that became the standard recipe. Its clean-estimate formulas already contained the pieces that v-prediction later rearranged. When Salimans and Ho set out to distil long samplers into short ones in 2022, they found the noise target fragile at the noisy end, and they proposed predicting the weighted difference instead. Later image and video systems adopted v-prediction for some checkpoints and cascades.
Recap
- A diffusion network can predict the noise, the clean data, or the weighted difference v, and each choice is a rearrangement of the same mix.
- v is , and the clean value and noise are recovered from it with two inverse formulas.
- Because , the target keeps a steady size, and errors do not blow up when the input is nearly pure noise.
- Few-step samplers and distillation benefit most, so the choice matters most in that regime.
To go further, read about Progressive Distillation for the few-step setting this target was built for, then Imagen Video to see the parameterisation used at video scale.
Check yourself
QuestionRecall: what is the v-target in terms of the noise , the clean data , and the weights and ?Show answer
. It is a weighted difference of the noise and the clean data, with the noise weighted by and the clean data by .
QuestionCompute: with , , and , find and , then recover from them.Show answer
. Then . Recovering gives , the original clean value.
QuestionWhy: why does the noise-prediction route make the clean estimate fragile at the very noisy end of a schedule?Show answer
The clean estimate is , and is close to zero there. Dividing by a small number multiplies any error in the network's output, so a small error in the noise output becomes a large error in the clean estimate. The v-route multiplies the error by instead, which is at most 1.
QuestionApplied: a checkpoint was trained with v-prediction, but the sampler assumes noise prediction. What goes wrong, and what is the fix?Show answer
The sampler treats the network output as if it were , so each step removes the wrong component of the input. Samples come out washed out or noisy. The fix is to convert the output before using it: , or to use a sampler that reads v directly.