CE-SDWV: Effective and Efficient Concept Erasure for Text-to-Image Diffusion Models via a Semantic-Driven Word Vocabulary

Jiahang Tu, Qian Feng, Jiahua Dong, Hanbin Zhao, Chao Zhang +2 more
1/26/2025
cs.CVcs.AI

Official code: TtuHamg/CE-SDWV (2 stars, last commit 2025-09-25).

Abstract

Large-scale text-to-image (T2I) diffusion models have achieved remarkable generative performance about various concepts. With the limitation of privacy and safety in practice, the generative capability concerning NSFW (Not Safe For Work) concepts is undesirable, e.g., producing sexually explicit photos, and licensed images. The concept erasure task for T2I diffusion models has attracted considerable attention and requires an effective and efficient method. To achieve this goal, we propose a CE-SDWV framework, which removes the target concepts (e.g., NSFW concepts) of T2I diffusion models in the text semantic space by only adjusting the text condition tokens and does not need to re-train the original T2I diffusion model's weights. Specifically, our framework first builds a target concept-related word vocabulary to enhance the representation of the target concepts within the text semantic space, and then utilizes an adaptive semantic component suppression strategy to ablate the target concept-related semantic information in the text condition tokens. To further adapt the above text condition tokens to the original image semantic space, we propose an end-to-end gradient-orthogonal token optimization strategy. Extensive experiments on I2P and UnlearnCanvas benchmarks demonstrate the effectiveness and efficiency of our method. Code is available at https://github.com/TtuHamg/CE-SDWV.

View on arXivView PDF

Code Implementations(1)

TtuHamg/CE-SDWVOfficial100%

The official code for "CE-SDWV: Effective and Efficient Concept Erasure for Text-to-Image Diffusion Models via a Semantic-Driven Word Vocabulary".

21Python, Jupyter NotebookSep 25, 20251 years ago

Similar Papers

Cite this paper

@article{tu2025cesdwv,
  title  = {CE-SDWV: Effective and Efficient Concept Erasure for Text-to-Image Diffusion Models via a Semantic-Driven Word Vocabulary},
  author = {Jiahang Tu and Qian Feng and Jiahua Dong and Hanbin Zhao and Chao Zhang and Nicu Sebe and Hui Qian},
  year   = {2025},
  eprint = {2501.15562},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2501.15562v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2501.15562.svg)](https://codeofpaper.com/paper/2501.15562)

Discussion