Search

Search papers and lessons

Imagen Video: High Definition Video Generation with Diffusion Models

Jonathan Ho, William Chan, Chitwan Saharia et al. · 2022

Imagen Video turns a text prompt into a 1280x768, 5.3-second video by running a cascade of seven diffusion models, then speeds sampling up by distilling the cascade to 8 steps per model.

On this page

  • Colour = topic mix
  • Probability
  • Calculus
  • Discrete math
  • Generative models
  • Linear algebra
  • Architectures
  • ReadReady to readNot yet

TL;DR

Imagen Video is a text-to-video system. It takes a prompt, encodes it with a frozen language model, and then runs a cascade of seven diffusion models: one base model makes a small, low-resolution clip, and six super-resolution models raise its resolution and frame rate. The authors report 1280 by 768 pixels, 128 frames at 24 frames per second, and a clip about 5.3 seconds long. Two design choices carry much of the weight: predicting a velocity-style target called v-prediction, and distilling the guided cascade so it samples in 8 steps per model.

Builds on: Cascaded Diffusion Model, Classifier-Free Guidance, v-Prediction, Progressive Distillation · Leads to: Stable Video Diffusion and CogVideoX, which are later video generators you can compare with it

Why it mattered

Before this work, text-to-video generation was mostly shown at low resolution and short length. The paper scales the image recipe that had worked for text-to-image models into video, and it reports that the same recipe yields high definition clips with a high degree of control over style and content.

The paper's numbers make the scale concrete. The models are trained on 14 million video-text pairs and 60 million image-text pairs, plus the public LAION-400M image-text set. The full cascade produces about 126 million pixel values per clip, and distillation makes sampling about 18 times faster. The paper also argues that several findings from image diffusion carry over to video, which matters to anyone working on diffusion models in general.

The lineage is short. Ho et al. (2020) set the sampling and noise-prediction recipe that became the common starting point for DDPM-style models. Ho et al. (2022) extended it to video with the Video U-Net. Imagen then showed that a frozen language-model encoder with cascaded super-resolution gave high fidelity for text-to-image. Imagen Video, published in October 2022, combined these pieces for text-to-video, and it was one of several text-to-video systems from that period.

The problem

A video is a stack of frames, and each frame must look right on its own, must agree with its neighbours, and must match the text. Earlier video generators handled one or two of these well. Models that generate one frame after another can drift over time. Models that generate a whole block at once cost much more memory as the block grows. A single model that produces 128 frames at full resolution is far too large to train and sample efficiently.

The paper's answer is to split the problem. A small model makes the coarse version, and specialised models add detail, one step at a time. That is the idea of a cascade, applied to space and to time together.

How it works

Here is the pipeline for one prompt, in the order it runs.

  1. Text encoding. The prompt goes through a frozen T5-XXL text encoder, which produces a sequence of embeddings. The encoder is never trained further, so its language understanding is fixed.
  2. Base video model. Starting from random noise, a diffusion model denoises a block of 16 frames at 40 by 24 pixels. Each denoising step is conditioned on the text embeddings through Classifier-Free Guidance. Temporal attention lets the frames see each other, which keeps motion coherent.
  3. Temporal super-resolution (TSR). The clip is too short and too sparse in time. A TSR model fills in intermediate frames between the ones it is given.
  4. Spatial super-resolution (SSR). Other models enlarge every frame. The SSR models condition on the smaller clip by concatenating an upsampled copy to the noisy input, and they are also conditioned on the text.
  5. Alternate and repeat. The pipeline interleaves spatial and temporal stages until the output reaches 128 frames at 1280 by 768. The stages are trained separately, so they can be trained in parallel.
  6. Distilled sampling. After training, the whole cascade is distilled so that each of the seven models needs only 8 sampling steps.

Each stage sees a noisy input and a cleaner conditioning signal, and it only has to add detail that is consistent with that signal. Nothing in the chain needs to get the whole video right in one jump.

flowchart LR
  P[Text prompt] --> T5[Frozen T5-XXL encoder]
  T5 --> B[Base model: 16 frames, 40x24]
  B --> TSR[Temporal super-resolution]
  TSR --> SSR[Spatial super-resolution, repeated]
  SSR --> V[128 frames, 1280x768, 24 fps]

The math

The paper works in continuous time. A forward process gradually adds noise to a clip x\mathbf{x}, producing a noisy version zt\mathbf{z}_t for each time tt between 0 and 1. With a noise schedule given by two functions αt\alpha_t and σt\sigma_t, the noisy version is

zt=αtx+σtϵ,ϵ∼N(0,I)\mathbf{z}_t = \alpha_t \mathbf{x} + \sigma_t \boldsymbol{\epsilon}, \qquad \boldsymbol{\epsilon} \sim \mathcal{N}(\mathbf{0}, \mathbf{I})

where ϵ\boldsymbol{\epsilon} is standard Gaussian noise. The paper uses a continuous-time version of the cosine schedule (Nichol and Dhariwal, 2021), with αt=cos⁡(πt/2)\alpha_t = \cos(\pi t / 2) and σt=sin⁡(πt/2)\sigma_t = \sin(\pi t / 2), so that αt2+σt2=1\alpha_t^2 + \sigma_t^2 = 1 and the noise grows smoothly as tt goes from 0 to 1.

00.20.40.60.8100.20.40.60.81tweight
  • alpha(t), signal
  • sigma(t), noise
The cosine schedule: at t = 0 the clip is clean, at t = 1 it is almost pure noise. The two weights always satisfy alpha squared plus sigma squared equal to 1.

Step 2 in symbols: the denoising target

The model x^θ\hat{\mathbf{x}}_\theta is trained to recover the clean clip from the noisy one. The paper parameterises the model by a target vt\mathbf{v}_t instead of the noise itself:

vt=αtϵ−σtx\mathbf{v}_t = \alpha_t \boldsymbol{\epsilon} - \sigma_t \mathbf{x}

Given the network's prediction v^θ\hat{\mathbf{v}}_\theta, the clean clip is recovered as

x^=αtzt−σtv^θ\hat{\mathbf{x}} = \alpha_t \mathbf{z}_t - \sigma_t \hat{\mathbf{v}}_\theta

The paper chose this target because it stays numerically stable across all tt, and because it avoids colour shifts that the noise target produced at high resolution.

Step 2 in symbols, continued: guidance

With a text embedding c\mathbf{c}, the model gives a conditional prediction x^θ(zt,c)\hat{\mathbf{x}}_\theta(\mathbf{z}_t, \mathbf{c}) and an unconditional one x^θ(zt)\hat{\mathbf{x}}_\theta(\mathbf{z}_t), the latter obtained by dropping the text during training. Classifier-free guidance with strength ww combines them:

x~θ(zt,c)=(1+w) x^θ(zt,c)−w x^θ(zt)\tilde{\mathbf{x}}_\theta(\mathbf{z}_t, \mathbf{c}) = (1 + w)\, \hat{\mathbf{x}}_\theta(\mathbf{z}_t, \mathbf{c}) - w\, \hat{\mathbf{x}}_\theta(\mathbf{z}_t)

For w>0w > 0 the sample is pushed further towards the text, which trades diversity for fidelity. Large ww pushes values outside the valid pixel range. Plain clipping to that range causes saturation artifacts, and dynamic clipping was not enough in the paper's experiments, so the paper alternates between a large and a small ww across sampling steps ("oscillating guidance").

Step 6 in symbols: distillation halves the steps

Progressive distillation trains a model that takes N/2N/2 steps to match two steps of the previous model. Repeating the halving reduces the number of steps while keeping the output close to the original. The paper first trains one model to match the guided output, which is the conditional and unconditional predictions combined with the guidance weight. It then applies progressive distillation to that single model, halving the steps each round until each of the seven models uses 8 steps.

Worked examples

Example
1. Tiny: one v-prediction step with numbers

Take a scalar "clip" x=2x = 2, with α=0.6\alpha = 0.6 and σ=0.8\sigma = 0.8, so α2+σ2=1\alpha^2 + \sigma^2 = 1. Let the noise be ϵ=1\epsilon = 1.

  1. Noisy value: z=αx+σϵ=0.6×2+0.8×1=1.2+0.8=2.0z = \alpha x + \sigma \epsilon = 0.6 \times 2 + 0.8 \times 1 = 1.2 + 0.8 = 2.0.
  2. Target: v=αϵ−σx=0.6×1−0.8×2=0.6−1.6=−1.0v = \alpha \epsilon - \sigma x = 0.6 \times 1 - 0.8 \times 2 = 0.6 - 1.6 = -1.0.
  3. Suppose the model predicts v^=−1.0\hat v = -1.0 exactly. Recover the clean value: x^=αz−σv^=0.6×2.0−0.8×(−1.0)=1.2+0.8=2.0\hat x = \alpha z - \sigma \hat v = 0.6 \times 2.0 - 0.8 \times (-1.0) = 1.2 + 0.8 = 2.0.
  4. Check: x^=2.0=x\hat x = 2.0 = x. The recovery is exact when the prediction is exact.

Interpretation: the model's job is one number, vv, from which both the clean value and the noise can be read off.

Example
2. Standard: classifier-free guidance by hand

Take a pixel where the conditional prediction is x^θ(zt,c)=4.0\hat x_\theta(\mathbf{z}_t, \mathbf{c}) = 4.0, the unconditional prediction is x^θ(zt)=3.0\hat x_\theta(\mathbf{z}_t) = 3.0, and guidance strength w=6w = 6.

  1. Weight on the conditional prediction: 1+w=71 + w = 7.
  2. Weight on the unconditional prediction: w=6w = 6.
  3. Combined value: x~=7×4.0−6×3.0=28−18=10\tilde x = 7 \times 4.0 - 6 \times 3.0 = 28 - 18 = 10.
  4. Interpretation: the guided value (10) lies well beyond the conditional prediction (4), in the direction the text pushes. This is why large ww can push values outside the pixel range. The paper projects them back into range at every step, and adds oscillating guidance because plain clipping saturates the image.

Answer: 10.

Example
3. Realistic: how many pixels in one clip

The earlier work the paper builds on produced 64-frame clips at 128 by 128 pixels. Imagen Video produces 128 frames at 1280 by 768.

  1. Earlier clip: 64×128×128=1,048,57664 \times 128 \times 128 = 1{,}048{,}576 pixel values in total.
  2. New clip: 128×1280×768=125,829,120128 \times 1280 \times 768 = 125{,}829{,}120 values, about 126 million, which matches the paper.
  3. Ratio: 125,829,120/1,048,576=120125{,}829{,}120 / 1{,}048{,}576 = 120.
  4. Duration check: 128 frames at 24 frames per second last 128/24≈5.3128 / 24 \approx 5.3 seconds, which matches the paper's clip length.

Try it: a 64-frame clip at 256 by 256 pixels has how many values, and how many times more than the earlier 64-frame, 128 by 128 clip? Answer: 64×256×256=4,194,30464 \times 256 \times 256 = 4{,}194{,}304 values, which is 4 times the earlier clip.

Results

The paper reports results mainly as qualitative samples and as a small table of automatic metrics. The samples show artistic styles learned from images, such as van Gogh and watercolour looks, and objects rotating with rough 3D structure. The authors call the 3D consistency inexact, so these are reported as observations rather than measurements.

On scaling, the base video model improves on both FVD and CLIP scores when its parameter count grows from 500 million to 1.6 billion to 5.6 billion. The paper reads this as evidence that video modelling is far from saturated at current sizes.

On parameterisation, a v-prediction super-resolution model converges faster in sample quality than an epsilon-prediction model of the same design, and the epsilon model shows colour shifts across frames.

On distillation, the original cascade at 256 base steps and 128 super-resolution steps takes 618 seconds per batch, with a CLIP score of 25.19 and CLIP R-Precision of 92.12 under constant guidance w = 6. The fully distilled pipeline, with 8 steps per stage, takes 35 seconds, with a CLIP score of 25.03 and R-Precision of 89.68. The ground-truth videos score 24.27 and 86.18. The distilled cascade is about 18 times faster and about 36 times more efficient in FLOPs, because it no longer evaluates the model twice per step for guidance.

Limits. These are automatic metrics on the authors' test prompts, and the paper does not claim the distilled model is identical to the original. The samples are curated and the 3D behaviour is imperfect.

Common mistakes and tradeoffs

It is tempting to think a video is just a stack of good images. In fact, the frames must agree with each other, so the base model uses temporal attention to mix information across frames, and the super-resolution models use temporal convolutions to keep neighbouring frames consistent. Per-frame quality alone does not give a coherent clip.

It is tempting to think one large model should generate the whole video. In fact, the cascade is used because memory and compute grow quickly with resolution and frame count. Splitting the work lets each model stay small, and the models can be trained in parallel.

It is tempting to think stronger guidance is always better. In fact, large guidance weights cause saturation, and dynamic clipping alone did not fix it in the paper's experiments. Alternating high and low weights helped. Guidance also reduces diversity, so it is a choice, not a free gain.

It is tempting to think distillation simply trades quality for speed. In fact, the paper reports similar quality by its automatic measures after a large speed-up. The match is close, not perfect.

Use a cascade like this when the target resolution and length are too large for a single model. Do not use it when a short, low-resolution clip is enough, since the extra stages add engineering work and sampling cost. Alternatives include latent video models, which run the diffusion in a compressed space, and autoregressive models, which generate frame after frame.

Reading guide

The paper's sections, and the lessons each one needs:

After this, the Video Diffusion Models paper gives the base architecture in full, and the Imagen paper gives the text-to-image recipe this one scales.

Check yourself

QuestionWhy does Imagen Video use a cascade of models instead of one model for the full 128-frame, 1280 by 768 clip?Show answer
A single model at that size is expensive to train and to sample from. The cascade splits the work: a small base model makes a coarse clip, and specialised super-resolution models add spatial and temporal detail. Each stage is smaller and can be trained in parallel.
QuestionUsing the paper's cosine schedule, what are alpha and sigma at t = 0.5, and what is alpha squared plus sigma squared?Show answer
Alpha is cos(pi/4), about 0.707, and sigma is sin(pi/4), about 0.707. Their squares are each 0.5, so alpha squared plus sigma squared is 1.
QuestionIn the classifier-free guidance formula with w = 2, the conditional prediction is 5 and the unconditional prediction is 3. What is the guided value?Show answer
The guided value is (1 + 2) times 5 minus 2 times 3, which is 15 minus 6, so 9.
QuestionA team distils a diffusion model from 256 sampling steps down to 8 by halving the steps each round. How many rounds are needed, and why does the paper's approach first distil the guided pair?Show answer
Each round halves the steps: 256 to 128, 128 to 64, 64 to 32, 32 to 16, and 16 to 8. That is five rounds. The paper distils the guided conditional and unconditional pair into one model first, because classifier-free guidance otherwise costs two model evaluations per step, and merging them removes that cost before the step-halving starts.

Sources

Read the full paper

Jonathan Ho, William Chan, Chitwan Saharia et al., 2022. arXiv:2210.02303