arXiv ScienceSearch

arXiv · 2403.02579

Geometric Dynamics of Signal Propagation Predict Trainability of Transformers

Abstract

We investigate forward signal propagation and gradient back propagation in deep, randomly initialized transformers, yielding simple necessary and sufficient conditions on initialization hyperparameters that ensure trainability of deep transformers. Our approach treats the evolution of the representations of $n$ tokens as they propagate through the transformer layers in terms of a discrete time dynamical system of $n$ interacting particles. We derive simple update equations for the evolving geometry of this particle system, starting from a permutation symmetric simplex. Our update equations show that without MLP layers, this system will collapse to a line, consistent with prior work on rank collapse in transformers. However, unlike prior work, our evolution equations can quantitatively track particle geometry in the additional presence of nonlinear MLP layers, and it reveals an order-chaos phase transition as a function of initialization hyperparameters, like the strength of attentional and MLP residual connections and weight variances. In the ordered phase the particles are attractive and collapse to a line, while in the chaotic phase the particles are repulsive and converge to a regular $n$-simplex. We analytically derive two Lyapunov exponents: an angle exponent that governs departures from the edge of chaos in this particle system, and a gradient exponent that governs the rate of exponential growth or decay of backpropagated gradients. We show through experiments that, remarkably, the final test loss at the end of training is well predicted just by these two exponents at the beginning of training, and that the simultaneous vanishing of these two exponents yields a simple necessary and sufficient condition to achieve minimal test loss.

Explore related subjects

Keep this discovery

BibTeXRIS

Aditya Cowsik, Tamra Nebabu, Xiao-Liang Qi, Surya Ganguli. 2024-03-05. Geometric Dynamics of Signal Propagation Predict Trainability of Transformers. https://arxiv.org/abs/2403.02579

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

Irrationality Measure Controls Long-Wavelength Charge Fluctuations in Quasiperiodic Systems

Quasiperiodic order is characterized by irrational frequencies whose rational approximability known as irrationality measure defines distinct arithmetic classes. We establish that this arithmetic classification has direct physical consequences for long-wavelength charge fluctuations. In translation-covariant quasiperiodic systems, the infrared scaling of charge fluctuation is governed by the interplay between the irrationality exponent of irrational frequency and the large-harmonic decay of the hull charge profile: the latter determines the available charge weight, while the former controls how efficiently that weight is transferred to the infrared. Consequently, all algebraic irrational frequencies share the same arithmetic scaling, whereas exceptionally well-approximable transcendental frequencies can exhibit strongly enhanced infrared fluctuation scaling. We further prove that occupied states separated from the Fermi level by a gap stable throughout the hull contribute only an analytic infrared background, leaving the nontrivial scaling to near-Fermi states. Our results extend to general translation-covariant multi-frequency quasiperiodic systems.

cond-mat.dis-nn

Curvature-Induced Geometric Universality in Non-Hermitian Anderson Transitions

In Euclidean space, universality classes of Anderson transitions are primarily determined by symmetry and spatial dimensionality. Here, we present evidence for a geometry-controlled universality class of non-Hermitian Anderson transitions on hyperbolic-like lattices. In this setting, critical behavior is influenced by the large-scale hyperbolic geometry, characterized by negative curvature, exponential volume growth, and a non-Euclidean notion of spatial scaling. Finite-size scaling of participation ratios across several distinct \( \{p,q\} \) tilings reveals one-parameter scaling collapses with a common critical exponent \( \nu\simeq1 \) within numerical accuracy. A complementary phenomenological coarse-grained Landau-Ginzburg analysis shows how exponential correlation-volume growth suppresses critical fluctuations, offering a rationale for the observed mean-field-like scaling. Our results suggest that spatial curvature can act as an additional organizing principle for Anderson-transition universality beyond the conventional dimensionality- and symmetry-based classification.

cond-mat.dis-nn

Finite-rank multiplicative perturbations of rotationally invariant non-Hermitian random matrices

We study finite-rank multiplicative deformations of rotationally invariant non-Hermitian random matrices. More precisely, we consider models of the form $\mathbf{A}(\mathbf{I}+\mathbf{T})$, where $\mathbf{A}$ is a large rotationally invariant non-Hermitian random matrix, $\mathbf{T}$ is a finite-rank normal perturbation, and $\mathbf{I}$ denotes the identity matrix. We characterize the emergence of outlier eigenvalues, their fluctuations, and the associated eigenvector overlaps. Our results provide a multiplicative non-Hermitian counterpart to the classical Baik--Ben Arous--P\'ech\'e framework.

cond-mat.dis-nn