Wan2.2
A text/image-to-video model. It starts from white noise in a video latent (frames × height × width) and denoises it step by step into a video clip. The parts are a T5 text encoder, a 3D video VAE, and a DiT denoiser. The 14B version splits denoising between two experts.
text + image → video (I2V-A14B)
positive and negative prompts, and the start image
|
umT5 (multilingual T5) creates the positive and negative embeddings. It reads text only.
|
Wan-VAE (a 3D causal VAE) compresses video in both space and time: 4× in time, 8×8 in space. A clip of T frames becomes 1 + T/4 latent frames. The first frame gets its own latent frame.
Two latents are prepared:
Noise latent: white noise covering the whole clip. This is the starting point.
Condition latent: the VAE encodes the start image as frame 0, with empty frames after it. A mask marks which frames are given (frame 0) and which are to be generated (the rest).
The condition latent and the mask are concatenated with the noise latent along the channel dimension, so each position carries "noisy content + known content + is-it-known flag".
|
The DiT (Diffusion Transformer) is the flow-matching denoiser.
The concatenated latent is cut into 3D patches (1 × 2 × 2: time × height × width). Each patch becomes one token, so the whole video becomes one long token sequence.
Self-attention runs across all tokens over space and time. That's how motion stays consistent between frames and with the start image.
Cross-attention (like cross join in sql) to the umT5 text tokens is how the prompt steers. i.e. each video token reads from the text tokens to understand the instruction.
This differs from Qwen-Image's joint attention: here text is only a separate input for video tokens to look up, not part of the same video sequence.
It predicts the velocity from noise to video.
Conceptually: (noisy latent) + (step size) × (velocity) → (cleaner latent).
MoE: two experts, split by noise level
High-noise expert (~14B): handles early steps: layout, composition, large motion, camera movement.
Low-noise expert (~14B): handles late steps: texture, faces, lighting, fine detail.
They switch once at a noise threshold, based on the signal-to-noise ratio (SNR). Only one expert runs per step, so you get 27B of capacity at the compute cost of 14B.
|
CFG blends the positive and negative velocities.
Conceptually: (blended velocity) = (negative velocity) + w × (positive velocity − negative velocity).
|
The sampler takes a step along the blended velocity. The scheduler goes from σ = 1 to σ = 0, with a shift that spends more steps at high noise.
|
Loop back to the DiT, using the high-noise expert first and then the low-noise expert.
|
Complete all t steps.
|
Wan-VAE decodes the video latent into frames.
umT5 : multilingual text encoder, text -> embedding (text only)
Wan-VAE : 3D causal VAE, video ↔ latent, compressing time as well as space
DiT : transformer denoiser over spatio-temporal patch tokens; text enters by cross-attention
MoE : high-noise expert for layout and motion, low-noise expert for detail, switched by SNR
Flow matching / CFG / sampler : same roles as in Qwen-Image
Compared with Qwen-Image
Image vs video: the latent gains a time axis. Attention across time is what gives coherent motion.
How text enters: cross-attention (Wan) vs joint attention in one shared sequence (Qwen-Image MMDiT).
Text encoder: umT5, text only (Wan) vs Qwen2.5-VL, which can read images (Qwen-Image).
What the input image is: the first frame to animate (Wan I2V) vs a reference to copy from while editing (Qwen-Image-Edit).
MoE across noise levels is specific to Wan2.2 A14B.
LoRA
Same idea: y = Wx + aBAx, attached to the DiT's attention and MLP layers.
For A14B, train a LoRA for each expert: the high-noise LoRA controls motion and composition, the low-noise LoRA controls look and detail.
At run time, apply each one to its own expert. The LoRA only adapts the diffusion model; the text encoder is untouched.
Control / reference
The Wan family has separate models for this: VACE (structure, pose or reference-driven video, from Wan2.1) and Wan2.2-Animate-14B (motion taken from a driving video).
The basic I2V and TI2V models don't take control maps.