atlas

Research map / Image generation / Fast diffusion sampling

Finding NeMo: Localizing Neurons Responsible For Memorization in Diffusion Models

NeurIPS 2024 · Image generation › Fast diffusion sampling · approach: Diffusion models as perception tools · 2 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Introduces NeMo, a gradient-free method that localizes memorization of individual training images to a few (often single) neurons in Stable Diffusion's cross-attention value layers and deactivates them to stop verbatim replication while preserving image quality.

Problem

Diffusion models can memorize and reproduce training images verbatim, raising privacy and copyright concerns; existing mitigations act on inputs or require retraining and do not localize where memorization resides in the model.

Approach

Localize memorization down to individual neurons in cross-attention value layers by combining out-of-distribution z-score activation detection (initial candidate set) with a layer-wise and neuron-wise refinement using an SSIM-based memorization score on initial noise predictions; then deactivate the identified neurons to permanently mitigate memorization without retraining.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
deactivate localized memorization neuronsStable Diffusion v1.4 · Verbatim memorized promptsSSCD_Gen: 1.0\pm 0.0 -> 0.10\pm 0.07Helped
deactivate localized memorization neuronsStable Diffusion v1.4 · Template memorized promptsSSCD_Gen: 1.0\pm 0.0 -> 0.05\pm 0.04Helped
deactivate localized memorization neuronsStable Diffusion v1.4 · Verbatim memorized promptsA_CLIP: 0.32\pm0.02 -> 0.31\pm0.02No clear effect
skip refinement (ablation)NeMo · Verbatim memorized promptsnumber of identified neurons: 4\pm 3 -> 26.5 \pm 22.5Mixed
skip refinement (ablation)NeMo · Template memorized promptsnumber of identified neurons: 21\pm 18 -> 674.5 \pm 624.5Mixed
remove top-k neuron selection (ablation)NeMo · Verbatim memorized promptsSSCD_Gen: 0.10\pm 0.07 -> 0.21\pm0.13Hurt
remove top-k neuron selection (ablation)NeMo · Template memorized promptsSSCD_Gen: 0.05\pm 0.04 -> 0.41\pm0.32Hurt
use classifier-free guidance during detection (ablation)NeMo · Verbatim memorized promptsSSCD_Gen: 0.10\pm 0.07 -> 0.14\pm0.07Hurt
use classifier-free guidance during detection (ablation)NeMo · Template memorized promptsSSCD_Gen: 0.05\pm 0.04 -> 0.12\pm0.07Hurt
scale neuron activations by 0.75 instead of deactivating (ablation)NeMo · Verbatim memorized promptsSSCD_Gen: 0.10\pm 0.07 -> 0.995\pm0.00Hurt
scale neuron activations by 0.75 instead of deactivating (ablation)NeMo · Template memorized promptsSSCD_Gen: 0.05\pm 0.04 -> 0.966\pm0.03Hurt
scale neuron activations by -0.25 instead of deactivating (ablation)NeMo · Verbatim memorized promptsSSCD_Gen: 0.10\pm 0.07 -> 0.12\pm0.06No clear effect

Surprising findings

Limitations

Experimental setup

Datasets: LAION-2B-en COCO

Benchmarks: COCO

Metrics: SSCD_Orig SSCD_Gen D_SSCD CLIP score alignment FID CLIP-FID KID

Baselines: Prompt embedding adjustment Attention scaling Adding random tokens Random neuron deactivation

Builds on: Stable Diffusion Wen et al. memorization detection SSCD classifier-free guidance

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy