English

Memorization and Generalization in Generative Diffusion under the Manifold Hypothesis

Disordered Systems and Neural Networks 2025-05-27 v2

Abstract

We study the memorization and generalization capabilities of Diffusion Models (DMs) when data lies on a structured latent manifold. Specifically, we consider a set of PP data points in NN dimensions confined to a latent subspace of dimension D=αDND = \alpha_D N, following the Hidden Manifold Model (HMM). We analyze the reverse diffusion process using the empirical score function as a proxy, and characterize it in the high-dimensional limit P=exp(αN)P = \exp(\alpha N), N1N \gg 1, by exploiting a connection with the Random Energy Model (REM). We show that a characteristic time tot_o marks the emergence of traps in the time-dependent potential, which however do not affect typical trajectories. The size of their basins of attraction is computed at all times. We derive the collapse time tc<tot_c < t_o, at which trajectories fall into the basin of a training point, signaling memorization. An explicit formula for tct_c as a function of PP and αD\alpha_D shows that the curse of dimensionality is avoided for structured data (αD1\alpha_D \ll 1), even with nonlinear manifolds. We also prove that collapse corresponds to the condensation transition in the REM. Generalization is quantified via the Kullback-Leibler divergence between the exact distribution and the reverse one at time tt. We find a distinct time tg<tc<tot_g < t_c < t_o minimizing this divergence. Surprisingly, the best generalization occurs inside the memorization phase. We conclude that generalization in DMs improves with data structure, as tg0t_g \to 0 faster than tct_c when αD0\alpha_D \to 0.

Keywords

Cite

@article{arxiv.2502.09578,
  title  = {Memorization and Generalization in Generative Diffusion under the Manifold Hypothesis},
  author = {Beatrice Achilli and Luca Ambrogioni and Carlo Lucibello and Marc Mézard and Enrico Ventura},
  journal= {arXiv preprint arXiv:2502.09578},
  year   = {2025}
}

Comments

28 pages, 8 figures

R2 v1 2026-06-28T21:43:32.979Z