Lune

ICML2023Top-tier venue

Can Neural Network Memorization Be Localized?

Pratyush Maini, Michael Curtis Mozer, Hanie Sedghi, Zachary Chase Lipton, J. Zico Kolter, Chiyuan Zhang

Abstract

Recent efforts at explaining the interplay of memorization and generalization in deep overparametrized networks have posited that neural networks memorize\textit{memorize}"hard"examples in the final few layers of the model. Memorization refers to the ability to correctly predict on atypical\textit{atypical} examples of the training set. In this work, we show that rather than being confined to individual layers, memorization is a phenomenon confined to a small set of neurons in various layers of the model. First, via three experimental sources of converging evidence, we find that most layers are redundant for the memorization of examples and the layers that contribute to example memorization are, in general, not the final layers. The three sources are gradient accounting\textit{gradient accounting} (measuring the contribution to the gradient norms from memorized and clean examples), layer rewinding\textit{layer rewinding} (replacing specific model weights of a converged model with previous training checkpoints), and retraining\textit{retraining} (training rewound layers only on clean examples). Second, we ask a more generic question: can memorization be localized anywhere\textit{anywhere} in a model? We discover that memorization is often confined to a small number of neurons or channels (around 5) of the model. Based on these insights we propose a new form of dropout -- example-tied dropout\textit{example-tied dropout} that enables us to direct the memorization of examples to an apriori determined set of neurons. By dropping out these neurons, we are able to reduce the accuracy on memorized examples from 100%→3%100\%\to3\%, while also reducing the generalization gap.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

26 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Finding NeMo: Localizing Neurons Responsible For Memorization in Diffusion Models cites What Neural Networks Memorize and Why: Discovering the Long Tail via Influence Estimation
  • Finding NeMo: Localizing Neurons Responsible For Memorization in Diffusion Models cites Extracting Training Data from Large Language Models
  • Decomposing and Editing Predictions by Modeling Model Computation cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Decomposing and Editing Predictions by Modeling Model Computation cites What Neural Networks Memorize and Why: Discovering the Long Tail via Influence Estimation
  • Decomposing and Editing Predictions by Modeling Model Computation cites The Pitfalls of Simplicity Bias in Neural Networks
  • Extracting Training Data from Large Language Models cites What Neural Networks Memorize and Why: Discovering the Long Tail via Influence Estimation
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers26

  1. Assessing the Brittleness of Safety Alignment via Pruning and Low-Rank ModificationsBoyi Wei, Kaixuan Huang, Yangsibo Huang, Tinghao Xie et al.ICML 2024 · 215 citations
  2. Finding NeMo: Localizing Neurons Responsible For Memorization in Diffusion ModelsDominik Hintersdorf, Lukas Struppek, Kristian Kersting, Adam Dziedzic et al.NeurIPS 2024 · 46 citations
  3. Decomposing and Editing Predictions by Modeling Model ComputationHarshay Shah, Andrew Ilyas, Aleksander MadryICML 2024 · 25 citations
  4. Hubble: a Model Suite to Advance the Study of LLM MemorizationJohnny Wei, Ameya Godbole, Mohammad Aflah Khan, Ryan Yixiang Wang et al.ICLR 2026 · 22 citations
  5. Layer-wise linear mode connectivityLinara Adilova, Maksym Andriushchenko, Michael Kamp, Asja Fischer et al.ICLR 2024 · 22 citations

Builds on16

  1. An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
  2. Extracting Training Data from Large Language ModelsNicholas Carlini, Florian Tramèr, Eric Wallace, Matthew Jagielski et al.USENIX Security 2021 · 2,866 citations
  3. Early-Learning Regularization Prevents Memorization of Noisy LabelsSheng Liu, Jonathan Niles-Weed, Narges Razavian, Carlos Fernandez-GrandaNeurIPS 2020 · 798 citations
  4. What Neural Networks Memorize and Why: Discovering the Long Tail via Influence EstimationVitaly Feldman, Chiyuan ZhangNeurIPS 2020 · 674 citations
  5. The Pitfalls of Simplicity Bias in Neural NetworksHarshay Shah, Kaustav Tamuly, Aditi Raghunathan, Prateek Jain et al.NeurIPS 2020 · 503 citations

Related papers

  1. On the Over-Memorization During Natural, Robust and Catastrophic OverfittingRunqi Lin, Chaojian Yu, Bo Han, Tongliang LiuICLR 2024 · 21 citations
  2. Generalisation First, Memorisation Second? Memorisation Localisation for Natural Language Classification TasksVerna Dankers, Ivan TitovACL Findings 2024
  3. How does the Memorization of Neural Networks Impact Adversarial Robust Models?Han Xu, Xiaorui Liu, Wentao Wang, Zitao Liu et al.KDD 2023 · 1 citation
  4. Random Label Prediction Heads for Studying Memorization in Deep Neural NetworksMarlon Becker, Jonas Konrad, Luis Garcia Rodriguez, Benjamin RisseICLR 2026
  5. To Grok or not to Grok: Disentangling Generalization and Memorization on Corrupted Algorithmic DatasetsDarshil Doshi, Aritra Das, Tianyu He, Andrey GromovICLR 2024 · 23 citations
Dusk over the sea between two cliffs drawn in fine vertical lines