mlsanityData to 14 Oct 2026

Dynamic Attention Analysis for Backdoor Detection in Text-to-Image Diffusion Models

arXiv 2504.20518 ↗First posted 29 Apr 2025cs.CVcited by 3

On the map: Diffusion models → Robustness, privacy and adversarial aspects

also in 1 more
Abstract (arXiv)

Recent studies have revealed that text-to-image diffusion models are vulnerable to backdoor attacks, where attackers implant stealthy textual triggers to manipulate model outputs. Previous backdoor detection methods primarily focus on the static features of backdoor samples. However, a vital property of diffusion models is their inherent dynamism. This study introduces a novel backdoor detection perspective named Dynamic Attention Analysis (DAA), showing that these dynamic characteristics serve as better indicators for backdoor detection. Specifically, by examining the dynamic evolution of cross-attention maps, we observe that backdoor samples exhibit distinct feature evolution patterns at the <EOS> token compared to benign samples. To quantify these dynamic anomalies, we first introduce DAA-I, which treats the tokens' attention maps as spatially independent and measures dynamic feature using the Frobenius norm. Furthermore, to better capture the interactions between attention maps and refine the feature, we propose a dynamical system-based approach, referred to as DAA-S. This model formulates the spatial correlations among attention maps using a graph-based state equation and we theoretically analyze the global asymptotic stability of this method. Extensive experiments across six representative backdoor attack scenarios demonstrate that our approach significantly surpasses existing detection methods, achieving an average F1 Score of 79.27% and an AUC of 86.27%. The code is available at https://github.com/Robin-WZQ/DAA.

Key facts. Cited by 3 papers in the map (data through 14 Oct 2026). Placed in Robustness, privacy and adversarial aspects, one of 14 directions in Diffusion models. Builds on 46 of its 74 references that are in the map. First posted on arXiv 29 Apr 2025.

Builds on

46 of 74 references.

Closest ancestors · 8

Same direction, newest first

  1. 2024TERD: A Unified Framework for Safeguarding Diffusion Models Against Backdoors9 Sep
  2. 2024Defending Text-to-image Diffusion Models: Surprising Efficacy of Textual Perturbations Against Backdoor Attacks28 Aug
  3. 2024DisDet: Exploring Detectability of Backdoor Attack on Diffusion Models5 Feb
  4. 2023Elijah: Eliminating Backdoors Injected in Diffusion Models via Distribution Shift27 Nov
  5. 2023Unified Concept Editing in Diffusion Models25 Aug
  6. 2023Backdooring Textual Inversion for Concept Censorship21 Aug
  7. 2023Text-to-Image Diffusion Models can be Easily Backdoored through Multimodal Data Poisoning7 May
  8. 2023Erasing Concepts from Diffusion Models13 Mar

Other references · 38

  1. 2017Attention Is All You Needcited by 60,361
  2. 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,744
  3. 2020Denoising Diffusion Probabilistic Modelscited by 21,076
  4. 2015U-Net: Convolutional Networks for Biomedical Image Segmentationcited by 19,713
  5. 2021High-Resolution Image Synthesis with Latent Diffusion Modelscited by 18,863
  6. 2021LoRA: Low-Rank Adaptation of Large Language Modelscited by 14,380
  7. 2020Denoising Diffusion Implicit Modelscited by 9,781
  8. 2015Deep Unsupervised Learning using Nonequilibrium Thermodynamicscited by 7,058
  9. 2022Hierarchical Text-Conditional Image Generation with CLIP Latentscited by 6,585
  10. 2022Photorealistic Text-to-Image Diffusion Models with Deep Language Understandingcited by 6,355
  11. 2022Classifier-Free Diffusion Guidancecited by 5,847
  12. 2023Adding Conditional Control to Text-to-Image Diffusion Modelscited by 5,503
26 more
  1. 2023SDXL: Improving Latent Diffusion Models for High-Resolution Image Synthesiscited by 4,356
  2. 2022BLIP: Bootstrapping Language-Image Pre-training for Unified Vision-Language Understanding and Generationcited by 4,322
  3. 2022DreamBooth: Fine Tuning Text-to-Image Diffusion Models for Subject-Driven Generationcited by 3,300
  4. 2022Locating and Editing Factual Associations in GPTcited by 2,691
  5. 2022InstructPix2Pix: Learning to Follow Image Editing Instructionscited by 2,611
  6. 2022An Image is Worth One Word: Personalizing Text-to-Image Generation using Textual Inversioncited by 2,245
  7. 2022Scaling Autoregressive Models for Content-Rich Text-to-Image Generationcited by 1,295
  8. 2022Diffusion Models in Vision: A Surveycited by 1,015
  9. 2022Mass-Editing Memory in a Transformercited by 1,001
  10. 2022DiffusionDB: A Large-scale Prompt Gallery Dataset for Text-to-Image Generative Modelscited by 379
  11. 2020Input-Aware Dynamic Backdoor Attackcited by 313
  12. 2022Diffusion Models for Medical Image Analysis: A Comprehensive Surveycited by 273
  13. 2023LayoutDiffusion: Controllable Diffusion Model for Layout-to-image Generationcited by 259
  14. 2021More Control for Free! Image Synthesis with Semantic Diffusion Guidancecited by 212
  15. 2020Dataset Security for Machine Learning: Data Poisoning, Backdoor Attacks, and Defensescited by 180
  16. 2023StableVITON: Learning Semantic Correspondence with Latent Diffusion Model for Virtual Try-Oncited by 175
  17. 2023TryOnDiffusion: A Tale of Two UNetscited by 141
  18. 2021Talk-to-Edit: Fine-Grained Facial Editing via Dialogcited by 102
  19. 2021CAT: Cross Attention in Vision Transformercited by 92
  20. 2024Get What You Want, Not What You Don't: Image Content Suppression for Text-to-Image Diffusion Modelscited by 63
  21. 2022Rickrolling the Artist: Injecting Backdoors into Text Encoders for Text-to-Image Synthesiscited by 59
  22. 2024Towards Understanding the Working Mechanism of Text-to-Image Diffusion Modelcited by 48
  23. 2024Magnet: We Never Know How Text-to-Image Diffusion Models Work, Until We Learn How Vision-Language Models Functioncited by 19
  24. 2022Can There be Art Without an Artist?cited by 10
  25. 2024Towards Unified Robustness Against Both Backdoor and Adversarial Attackscited by 10
  26. 2024Dysca: A Dynamic and Scalable Benchmark for Evaluating Perception Ability of LVLMscited by 6

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 3.

3 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2026Learning Normal Diffusion Dynamics for Backdoor Defense in Text-to-Image Models
  2. 2026Scaling Exposes the Trigger: Input-Level Backdoor Detection in Text-to-Image Diffusion Models via Cross-Attention Scaling
  3. 2025Backdoor Defense in Diffusion Models via Spatial Attention Unlearning
  4. 2024T2IShield: Defending Against Backdoors on Text-to-Image Diffusion Models
  5. 2025Trigger without Trace: Towards Stealthy Backdoor Attack on Text-to-Image Diffusion Models
  6. 2026Tuning Just Enough: Lightweight Backdoor Attacks on Multi-Encoder Diffusion Models
  7. 2026TEMPO-Diffusion: Temporally Exposed Malicious Poisoning of Diffusion Models
  8. 2024UFID: A Unified Framework for Input-level Backdoor Detection on Diffusion Models