QwenImage 2.1 adds KV caching, measured 2.55x faster image generation
RisingSayak · x · 2026-09-21
A technical thread breaks down how QwenImage 2.1 (7B DiT) incorporates KV caching to speed up denoising:
- Core idea: separate the fixed context (text and reference images) from target-image positions that change every denoising step; the fixed prefix is cached once so later steps get much cheaper.
- Sequence construction: Qwen3-VL text tokens are interleaved with condition-image latents, with target-image latents last. During prefill, each layer saves only prefix K/V.
- Contrast with MMDiT/FLUX2: classic MMDiT joint attention is bidirectional (FLUX2 caches only reference-image tokens), but QwenImage 2.1's information flow is directional, so the entire prefix (text + reference images) can be reused. In decode, each layer computes target Q/K/V and prepends cached prefix K/V.
- Benchmarks: on a warmed A100 with two 1024×1024 references at 40 steps, DiT time dropped from 50.57s to 19.86s (2.55x), at the cost of memory rising from 32.3G to 36.0G, which the author says can be further optimized.
Related event: Qwen-Image 2.1 Lands on SGLang with 2.55x Speedup from KV Cache(2 posts)→
More from Multimodal
- Indie Britpop AI music video built with Nano Banana Pro, Kling, and free lip-sync via WAN2GP + LTX 2.5 — cocktailpeanut · 2026-11-12
- P2Echo: one text-prompted model segments multi-view echocardiography with high accuracy and low cost — UBC-V · 2026-11-12
- Redditor makes fast-motion short film with H3 and ships Longshot Studio v0.18.5 with face swap — R34vspec · 2026-11-12
- Reimagining Knight Rider's opening as a Netflix drama with Claude Fable 5.2 — justin_hart · 2026-11-12
- Gemini 4 Carbon builds a full 3D aquarium in Blender and Three.js in ~6 hours — sunjiao123sun_ · 2026-11-12
- Awaken Open-Sourced: Turn a Half-Duplex Speech LLM Full-Duplex With Just a Small LoRA — alexcovo_eth · 2026-11-12