Neural Spectrum Alignment

Dmitry Kopitkov, Vadim Indelman

TL;DR

Contrary to common theoretical assumptions that the Neural Tangent Kernel (NTK) remains static during training, this paper empirically demonstrates that the kernel evolves to align its top eigenfunctions with the target function. This "Neural Spectrum Alignment" acts as a form of learned memory, explaining why deep networks converge faster and generalize better than their shallow counterparts.

What Problem Does This Paper Address?

In the quest to understand why deep learning works, researchers often lean on the Neural Tangent Kernel (NTK) framework. Theoretical breakthroughs (like the "lazy training" regime) suggest that in the limit of infinite width, this kernel is time-invariant—meaning the way a network computes gradients doesn't change as it learns.

However, practitioners know that real-world networks are not "lazy." The authors tackle the gap between this static theory and practical reality. They investigate how the kernel’s spectrum (its eigenvalues and eigenvectors) actually behaves during gradient descent. If the kernel isn't constant, how does it change, and does that change help or hinder learning?

Methods

The authors conduct an extensive empirical study using fully-connected (FC) neural networks. Their primary tool is the Gramian matrix ($G_t$), which represents the empirical NTK at training points.

Key methodological steps include:

  • Spectral Analysis: Computing the eigenvalues and eigenvectors of the Gramian throughout the optimization process.
  • Alignment Metrics: Measuring the "relative energy" of the target labels within the subspace spanned by the top $k$ eigenvectors.
  • Visualization: Projecting eigenvectors back into the input space to visualize them as basis functions (e.g., seeing how they represent parts of an image).
  • LR Decay Analysis: Observing how the kernel reacts to the common practice of dropping the learning rate during training.

Datasets

The study utilizes several benchmarks to ensure the phenomena are universal:

  • 2D Regression: A "Mona Lisa" image reconstruction task, used for intuitive visualization of eigenfunctions.
  • Image Classification: Standard real-world datasets including MNIST and CIFAR100.
  • Synthetic Data: Points sampled uniformly on a 2D plane for controlled experiments.

Key Insights and Ideas

  • The Kernel as Task-Specific Memory: The most significant finding is that the kernel's top eigenvectors align themselves with the target function almost immediately. The kernel effectively "learns" which directions in function space are important for the specific task at hand.
  • Eigenvectors as Basis Functions: The network's output is almost entirely spanned by a small number of top eigenvectors. As shown in the Mona Lisa experiments, these eigenvectors look like low-frequency versions of the target image, acting as the fundamental building blocks the network uses to construct its final prediction.
  • The Learning Rate "Compensation" Effect: The authors discovered a fascinating trend: when the learning rate ($\delta$) is decayed, the kernel's eigenvalues ($\lambda$) experience a sudden boost. The product of the eigenvalue and the learning rate remains roughly constant, suggesting a self-regulating mechanism that maintains a steady "speed" of movement in parameter space.
  • Depth vs. Width: While increasing width is the focus of much NTK theory, this paper shows that depth is what truly drives alignment. Deeper networks show much stronger alignment with the target function than shallow, wide networks with the same number of parameters.
Figure 1: (a) Mona Lisa target function for a regression task. (b) NN fθ(X) at convergence. (c) 104 sampled training points. (d) Accuracy of first order dynamics in Eq. (3). Depicted is

Key Results

  • High Alignment: In the Mona Lisa task, just the top 20 eigenvectors of the Gramian contain 90% of the target function's energy for nearly the entire training duration.
  • First-Order Accuracy: The authors show that first-order Taylor approximations (using the dynamic NTK) explain roughly 90% of the actual change in the neural network's output (see Figure 1d).
  • Convergence Speed: Because learning is naturally faster along the directions of top eigenvectors, the alignment of these eigenvectors with the target function directly accelerates global convergence.
  • Stability of the Top Spectrum: While the "bottom" (small eigenvalue) eigenvectors are noisy and unstable, the top spectrum is remarkably preserved and consistent throughout the optimization process (see Figure 7d).
Figure 5: Visualizing the top eigenvectors at the end of training. Note how they resemble components of the target image.

Limitations and Future Work

The authors acknowledge that their work is primarily empirical. While they provide a clear "what" and "how," the mathematical "why"—a formal theory explaining the mechanism behind this alignment—remains an open challenge.

Additionally, the study focuses on fully-connected networks and specific optimizers (GD, SGD, Adam). While they mention results are consistent across these, further study into more complex architectures like Transformers or CNNs with specialized layers (like Batch Norm) would be necessary to claim total universality. Finally, the behavior of the "bottom" spectrum is attributed partly to numerical precision limits (float32), leaving room for deeper investigation into the role of noise in the kernel's tail.

Summary updated

BibTeX
@inproceedings{kopitkov2020neural,
  author = {Dmitry Kopitkov and Vadim Indelman},
  title = {{Neural Spectrum Alignment}},
  booktitle = {ICANN},
  year = {2020},
  doi = {10.1007/978-3-030-61616-8\_14},
}
Figure