Learning curves for deep structured Gaussian feature models

Jacob A. Zavatone-Veth, Cengiz Pehlevan

This paper explores a fundamental question in deep learning theory: how does the internal structure of a neural network's weights—specifically, correlations and anisotropy—affect its ability to generalize? While most theoretical models assume weights are independent and identically distributed (i.i.d.) Gaussian variables, real-world networks are rarely so simple.

TL;DR

The authors derive exact "learning curves" for deep linear networks with structured random weights using tools from statistical physics. They discover a striking asymmetry: while correlations in the first layer can actually help a model generalize, structure in any subsequent layer is generally detrimental to performance when the model is forced to interpolate the training data.

What Problem Does This Paper Address?

A major focus in modern machine learning is "benign overfitting"—the phenomenon where models with far more parameters than data points can perfectly fit (interpolate) noisy training data yet still perform well on new examples.

To study this, researchers often use Random Feature Models (RFMs), where only the last layer is trained. However, almost all existing mathematical proofs for RFMs assume the fixed weights in the hidden layers are isotropic (unstructured) Gaussians. This paper fills that gap by investigating weight anisotropy: what happens when the random weights have specific correlation structures? Does this structure change the fundamental scaling laws of how error drops as we add more data or wider layers?

Methods

The authors analyze depth-$L$ linear RFMs. In these models, the input passes through several layers of fixed, random linear transformations before a final trainable layer produces the output.

Key technical components include:

  • Matrix Gaussian Distributions: Instead of i.i.d. weights, the authors use weights drawn from distributions that allow for row and column correlations ($\Gamma_\ell, \Sigma_\ell$).
  • The Replica Trick: Borrowed from the statistical physics of disordered systems, this method allows the authors to calculate the "quenched" average generalization error in the thermodynamic limit (where the number of data points $p$ and neurons $n$ both go to infinity).
  • Ridgeless Limit: The study focuses on the limit where regularization goes to zero ($\lambda \to 0$), forcing the model to become a minimum-norm interpolant of the training data.
  • Gaussian Equivalence: They leverage the fact that the generalization error of these complex models can be mapped to simpler effective linear models.

Datasets

As a theoretical work, the paper does not use standard image or text benchmarks. Instead, it uses a Structured Gaussian Covariate Model.

  • Inputs: Synthetic data with a controllable covariance matrix $\Sigma_0$.
  • Targets: Generated by a "teacher" linear model with a fixed weight vector $w_*$ and added Gaussian noise $\eta$.
  • Power-Law Spectra: To mimic real-world data (like language or images), the authors specifically test cases where the eigenvalues of the data and weight covariance matrices follow power-law decays.

Key Insights and Ideas

  • The First Layer is Special: The authors prove that having structure in the first layer's weights is mathematically equivalent to changing the structure of the input data itself. This means the first layer can be "tuned" to better represent the data.
  • Deep Structure is Detrimental: For ridgeless regression, any correlation structure in layers $2$ through $L$ acts as a bottleneck. It effectively reduces the "useful" dimensionality of the features, leading to higher generalization error compared to unstructured weights.
  • Scaling Law Robustness: Surprisingly, while weight structure changes the absolute error, it does not change the scaling exponents. If the error drops as $p^{-\alpha}$, the value of $\alpha$ is determined by the data's structure, not the weights' structure.
  • Phase Diagram Consistency: The qualitative "phases" of learning (overparameterized vs. bottlenecked) remain the same regardless of weight structure. This is visualized in the phase diagrams below.
Figure 1: Phase diagram of generalization in deep linear RFMs. For simplicity, we consider a model with a single hidden layer (L = 1); the picture for deeper models is identical if one considers the narrowest hidden layer [13]. (a). Generalization error ϵ for unstructured data and features from (25) as a function of training data density 1/α0 and hidden layer width α1/α0 in the absence of label noise (η = 0; left) and in the presence of label noise (η = 0.5; right). (b). As in (a), but for power law structured data and weights, with ω0 = ω1 = 1, and ¯ϵ given by (31). See Appendix F for numerical methods.

Key Results

  • Exact Asymptotics: The paper provides a closed-form expression (Proposition 3.2) for the generalization error $\epsilon$ that accounts for the spectral properties of every layer.
  • Numerical Agreement: The theoretical predictions show near-perfect agreement with numerical simulations, even for relatively small system sizes ($n_0 = 1000$).
  • Bayesian vs. Ridgeless: The authors show that for a Bayesian Gibbs estimator (a different way of "training"), weight structure can actually be beneficial if the prior variance is large enough. This highlights that the "harmfulness" of structure depends heavily on the choice of optimization algorithm.
Figure 2: Comparison of theory (solid lines) and numerical experiments (dots). (a-b) show how error changes with data density, while (c) shows that varying the weight power-law exponent $\omega_1$ shifts the error but preserves the overall shape of the learning curve.

Limitations and Future Work

  • Linearity: The most significant limitation is the focus on linear activations. While this allows for exact solutions, real networks are non-linear. The authors suggest that "Gaussian Equivalence Theorems" might allow these results to extend to non-linear cases, but this remains to be proven for structured weights.
  • Layer Independence: The model assumes weights in different layers are independent. In fully trained networks, weights across layers become highly coupled through the backpropagation process.
  • Single Teacher: The analysis assumes a single teacher vector. Extending this to "multi-index" targets (where the task depends on multiple directions in the data) would be a natural next step.

Summary updated

BibTeX
@inproceedings{zavatoneveth2023learning,
  author = {Jacob A. Zavatone-Veth and Cengiz Pehlevan},
  title = {{Learning curves for deep structured Gaussian feature models}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=6bd2o6pasJ},
}
Figure