atlas

Research map / Optimization / Implicit bias and generalization

Grokking at the Edge of Numerical Stability

ICLR 2025 · Optimization › Implicit bias and generalization · approach: Stability-based generalization analysis · 1 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.

Argues that grokking without regularization is blocked by floating-point absorption errors in softmax cross-entropy (Softmax Collapse), driven by gradient alignment with a logit-scaling direction (naive loss minimization); proposes StableMax and orthogonal-gradient optimizers that induce grokking without weight decay.

Problem

Grokking (delayed generalization after overfitting) is usually observed only with regularization such as weight decay, and it is unclear why generalization is delayed and why regularization is needed, especially with cross-entropy loss and deeper models.

Approach

Without regularization, training beyond 100% train accuracy drives gradients toward a logit-scaling (naive loss minimization) direction; logits grow until float absorption errors in the softmax sum zero out gradients (Softmax Collapse). Remedies are a numerically stable replacement for softmax (StableMax) and an optimizer (⊥Grad) that projects out the weight-direction component of the gradient.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Replace Softmax CE with StableMax CEResNet18 · CIFAR10accuracy: 87.17% ± 0.2 -> 87.01% ± 0.2No clear effect
Replace Softmax CE with StableMax CEResNet18 · CIFAR100accuracy: 59.98% ± 0.4 -> 60.63% ± 0.4Helped
Replace Softmax CE with StableMax CEResNet18 · ImageNet-1kaccuracy: 69.33% ± 0.04 -> 65.87% ± 0.22Hurt
Replace Softmax CE with StableMax CEGPT2-Small · WikiText-103Top-5 accuracy: 60.48% ± 0.04 -> 51.85% ± 0.47Hurt
Replace SGD with ⊥SGDResNet18 · CIFAR10accuracy: 87.17% ± 0.2 -> 87.22% ± 0.2No clear effect
Replace SGD with ⊥SGDResNet18 · CIFAR100accuracy: 59.98% ± 0.4 -> 62.69% ± 0.1Helped
Replace SGD with ⊥SGDResNet18 · ImageNet-1kaccuracy: 69.33% ± 0.04 -> 68.95% ± 0.03No clear effect
Replace AdamW with ⊥GradGPT2-Small · WikiText-103Top-5 accuracy: 60.48% ± 0.04 -> 59.64% ± 0.04No clear effect
Replace Softmax with StableMax in the attention mechanism (ablation)GPT2-Small · WikiText-103Top-5 accuracy: 60.48% ± 0.04 -> 58.52% ± 0.04Hurt
Use StableMax instead of Softmax CEMLP and transformer grokking tasks without regularization · Modular arithmetic, Sparse Parity, and MNISTtest accuracyHelped
Remove the gradient component parallel to the weights using ⊥GradGrokking models · Modular arithmetictest accuracyHelped
Increase Softmax calculation precision from float32 to float64 (ablation)MLP · Modular arithmetictest accuracyHelped

Surprising findings

Limitations

Experimental setup

Datasets: modular arithmetic mod 113 sparse parity MNIST WikiText-103 CIFAR10 CIFAR100 ImageNet-1k

Benchmarks: modular arithmetic mod 113 sparse parity MNIST CIFAR10 CIFAR100 ImageNet-1k WikiText-103

Metrics: train accuracy test accuracy test loss accuracy (top-5 for WikiText-103) fraction of softmax collapse samples weight norm

Baselines: AdamW with SCE AdamW with weight decay SGD with weight decay float64 softmax label smoothing temperature scaling

Builds on: AdamW SGD Softplus grokking (Power et al.) lazy training

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