atlas

Research map / Architectures and efficiency / RNNs and normalization

Weight decay induces low-rank attention layers

NeurIPS 2024 · Architectures and efficiency › RNNs and normalization · approach: Representation geometry and collapse · 2 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Shows theoretically that L2-regularized factorized products (as in attention W_K^T W_Q and P W_V) equal nuclear-norm regularization at local minima and converge to it exponentially fast, and empirically that weight decay induces low-rank attention matrix products in small LMs, ViTs, and pretrained LLaMA 2.

Problem

Weight decay (L2 regularization) is widely used when training transformers, but its effect on the rank of factorized attention parameter products (W_K^T W_Q and P W_V) is poorly understood.

Approach

For any differentiable loss on a factorized product AB^T, local minima of the L2-regularized loss coincide with local minima of the nuclear-norm-regularized loss, and the two objectives become identical exponentially quickly during gradient flow, so weight decay on attention factors implicitly induces low rank even before convergence.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Increase self-attention weight decay from λ=0.0 to λ=0.1125M Transformer · Pile test setperplexity: 11.72$^{\pm0.02}$ -> 11.52$^{\pm0.03}$Helped
Increase self-attention weight decay from λ=0.1 to λ=0.25125M Transformer · Pile test setperplexity: 11.52$^{\pm0.03}$ -> 11.58 $^{\pm0.03}$Hurt
Increase MLP weight decay from λ=0.0 to λ=0.25125M Transformer · Pile test setperplexity: 11.92$^{\pm0.02}$ -> 11.52$^{\pm0.03}$Helped
Increase attention-layer weight decayTransformer attention products W_K^T W_Q and PW_V · Pile language modelingpseudo rankHurt
Tune and decouple attention-layer weight decay from other parameters125M Transformer · Pile language modelingperplexityMixed

Surprising findings

Limitations

Experimental setup

Datasets: The Pile ImageNet associative recall synthetic task

Benchmarks: The Pile test perplexity ImageNet

Metrics: pseudo rank (95% of nuclear norm mass) test perplexity nuclear vs Frobenius norm gap accuracy

Baselines: L2-regularized factorized matrices nuclear norm regularization

Builds on: AdamW decoupled weight decay GPT-3 training recipe Vision Transformer training protocol

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy