Understanding the Impact of Negative Prompts: When and How Do They Take Effect?

Yuanhao Ban, Ruochen Wang, Tianyi Zhou, Minhao Cheng, Boqing Gong +1 more
6/1/2024

No confident code implementation found for this paper. 1 possible match can be shown below.

Abstract

The concept of negative prompts, emerging from conditional generation models like Stable Diffusion, allows users to specify what to exclude from the generated images.%, demonstrating significant practical efficacy. Despite the widespread use of negative prompts, their intrinsic mechanisms remain largely unexplored. This paper presents the first comprehensive study to uncover how and when negative prompts take effect. Our extensive empirical analysis identifies two primary behaviors of negative prompts. Delayed Effect: The impact of negative prompts is observed after positive prompts render corresponding content. Deletion Through Neutralization: Negative prompts delete concepts from the generated image through a mutual cancellation effect in latent space with positive prompts. These insights reveal significant potential real-world applications; for example, we demonstrate that negative prompts can facilitate object inpainting with minimal alterations to the background via a simple adaptive algorithm. We believe our findings will offer valuable insights for the community in capitalizing on the potential of negative prompts.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 1 weaker match is hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Cite this paper

@article{ban2024understanding,
  title  = {Understanding the Impact of Negative Prompts: When and How Do They Take Effect?},
  author = {Yuanhao Ban and Ruochen Wang and Tianyi Zhou and Minhao Cheng and Boqing Gong and Cho-Jui Hsieh},
  year   = {2024},
  eprint = {2406.02965},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2406.02965},
  journal = {ECCV 2024 2024}
}

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/2406.02965.svg)](https://codeofpaper.com/paper/2406.02965)

Discussion