QK-Edit: Revisiting Attention-based Injection in MM-DiT for Image and Video Editing
Tiancheng Shen, Zilong Huang, Xiangtai Li, Zhijie Lin, Jiyang Liu, Yitong Wang, Jiashi Feng, Ming-Hsuan Yang, Jun Hao Liew
Abstract
Multimodal Diffusion Transformers (MM-DiTs) have recently emerged as a powerful framework for unified text-vision synthesis, surpassing traditional U-Net architectures in generative tasks. One key innovation lies in its Multimodal Self-Attention (MM-SA) interaction, where image and text tokens are concatenated and processed via self-attention. However, this mechanism poses significant challenges for editing, rendering conventional U-Net-based attention manipulation methods ineffective. To address this limitation, we propose QK-Edit, a training-free framework that exploits the unique attention dynamics of MM-DiTs for precise text-guided image and video editing. By introducing a novel query-key manipulation strategy, our method isolates and adjusts critical attention components to achieve an optimal balance between prompt fidelity and structural consistency. This enables seamless edits across various tasks, including object addition, object removal, object replacement, changing background, changing material, changing color, and style transformation. Notably, it can be easily implemented with feature replacement in inference. QK-Edit demonstrates superior editing performance on state-of-the-art models, such as FLUX and HunyuanVideo, effectively bridging the gap between generative power and editable flexibility in MM-DiTs, and paving the way for scalable multimodal content creation.
Create a lesson
Metadata
- Categories
- cs.CV, cs.AI
- Comments
- Accepted at ICCV 2025
Related papers
SPARC: Geometry-Guided Attention Pruning for Long-Horizon Camera-Controlled Video Generation
Shared title terminologycs.CVZesong Yang, Weikai Chen, Liyuan Cui et al.
LayoutRecall: Preserving Appearance in Multi-Round 3D Layout-Controlled Image Editing
Shared title terminologycs.CVYankuan Chi, Xin Lin, Baihan Yang et al.
DualCast: Dual-Image Conditioned Diffusion Transformers for Digital Human E-Commerce Video Generation
Shared title terminologycs.CVLifan Jiang, Yifan Huang, Jixuan Zhang et al.
What Is Redundant at High Resolution? Efficient Attention and Feed-Forward Design for All-in-One Image Restoration
Shared title terminologycs.CVDongheon Lee, DongJae Lee, Sewhan Chun et al.
Attention-Based Spatio-Temporal Approach for Fire and Smoke Detection
Shared title terminologycs.CVAlireza Mirrashid, Mohammad Khoshbin, Ali Atghaei et al.
BluePixel: Toward Native 4K Agentic Image Editing
Shared title terminologycs.CVShanyan Guan, Shiyu Li, Xin Li et al.