Lune

CVPR2026顶会

SafeRoPE: Risk-specific Head-wise Embedding Rotation for Safe Generation in Rectified Flow Transformers

Xiang Yang, Feifei Li, Mi Zhang, Geng Hong, Xiaoyu You, Min Yang

摘要

Recent Text-to-Image (T2I) models based on rectified-flow transformers (e.g., SD3, FLUX) achieve high generative fidelity but remain vulnerable to unsafe semantics, especially when triggered by multi-token interactions. Existing mitigation methods largely rely on fine-tuning or attention modulation for concept unlearning; however, their expensive computational overhead and design tailored to U-Net-based denoisers hinder direct adaptation to transformer-based diffusion models (e.g., MMDiT). In this paper, we conduct an in-depth analysis of the attention mechanism in MMDiT and find that unsafe semantics concentrate within interpretable, low-dimensional subspaces at head level, where a finite set of safety-critical heads is responsible for unsafe feature extraction. We further observe that perturbing the Rotary Positional Embedding (RoPE) applied to the query and key vectors can effectively modify some specific concepts in the generated images.Motivated by these insights, we propose SafeRoPE, a training-free and fine-grained safe generation framework for MMDiT. Specifically, SafeRoPE first constructs head-wise unsafe subspaces by decomposing unsafe embeddings within safety-critical heads, and computes a Latent Risk Score (LRS) for each input vector via projection onto these subspaces. We then introduce head-wise RoPE perturbations that can suppress unsafe semantics without degrading benign content or image quality. SafeRoPE combine both head-wise LRS and RoPE perturbation to perform risk-specific head-wise rotation on embeddings, enabling precise suppression of unsafe outputs while maintaining generation fidelity. Extensive experiments demonstrate that SafeRoPE achieves the SOTA performance in balancing effective harmful content mitigation and utility preservation for safe generation of MMDiT.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

可以从这些问题问起

Lune 可以查阅

全文 · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • High-Resolution Image Synthesis with Latent Diffusion Models 引用了 Zero-Shot Text-to-Image Generation
  • GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models 引用了 Zero-Shot Text-to-Image Generation
  • GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models 引用了 Learning Transferable Visual Models From Natural Language Supervision
  • Zero-Shot Text-to-Image Generation 引用了 Learning Transferable Visual Models From Natural Language Supervision
  • Photorealistic Text-to-Image Diffusion Models with Deep Language Understanding 引用了 High-Resolution Image Synthesis with Latent Diffusion Models
  • Photorealistic Text-to-Image Diffusion Models with Deep Language Understanding 引用了 GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models
  • Photorealistic Text-to-Image Diffusion Models with Deep Language Understanding 引用了 Zero-Shot Text-to-Image Generation
  • Photorealistic Text-to-Image Diffusion Models with Deep Language Understanding 引用了 Learning Transferable Visual Models From Natural Language Supervision
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

它引用的 Paper33

  1. Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh 等ICML 2021 · 47,906 次引用
  2. High-Resolution Image Synthesis with Latent Diffusion ModelsRobin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser 等CVPR 2022 · 13,123 次引用
  3. Photorealistic Text-to-Image Diffusion Models with Deep Language UnderstandingChitwan Saharia, William Chan, Saurabh Saxena, Lala Li 等NeurIPS 2022 · 8,965 次引用
  4. Zero-Shot Text-to-Image GenerationAditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray 等ICML 2021 · 6,356 次引用
  5. GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion ModelsAlexander Quinn Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam 等ICML 2022 · 4,691 次引用

相关 Paper

  1. FreeFlux: Understanding and Exploiting Layer-Specific Roles in RoPE-Based MMDiT for Versatile Image EditingTianyi Wei, Yifan Zhou, Dongdong Chen, Xingang PanICCV 2025
  2. Head-wise Adaptive Rotary Positional Encoding for Fine-Grained Image GenerationJiaye Li, Baoyou Chen, Hui Li, Zilong Dong 等CVPR 2026
  3. Unified Safe In-context Image Generation in Multimodal Diffusion Transformers via Restricting Unsafe Information FlowsXiang Yang, Feifei Li, Mi Zhang, Geng Hong 等ICML 2026
  4. What Concepts Lie Within? Detecting and Suppressing Risky Content in Diffusion TransformersChenyu Zhang, Lanjun Wang, Yueyang Cheng, Ruidong Chen 等CCS 2026 · 1 次引用
  5. Responsible Text-to-Image Diffusion: Interpretable and Linearly Controllable Semantics for Fair and Safe GenerationSayedmoslem Shokrolahi, Jae-Mo Kang, Il-Min KimICML 2026
黄昏的海面,两侧是细线勾勒的悬崖