GradInit is a method that multiplies each block of randomly initialized weights (layer weights, biases, normalization-layer scales, and so on) by a single scale factor, and learns those factors briefly to set the scale of the initial values. The factors are chosen so that "the loss after a single update step with the optimizer used for training is as small as possible". It was proposed in 2021 by Chen Zhu et al. (NeurIPS 2021, "GradInit: Learning to Initialize Neural Networks for Stable and Efficient Training").
Earlier initializations derived a formula for each network architecture. Xavier initialization and He initialization assume plain feed-forward networks without normalization layers or residual connections, Fixup assumes residual networks, and T-Fixup assumes the Transformer. Re-deriving a formula every time a new architecture is tried is laborious, and once the formula's assumptions no longer hold, training becomes unstable. For example, the original Transformer (Post-LN) does not converge with ordinary initialization without learning rate warmup.
Instead of deriving formulas, GradInit finds the scale factors numerically using training data and the actual optimizer, so it works with any architecture. The paper showed the following.
- VGG and ResNet, both with and without batch normalization, trained faster and to higher accuracy than with He initialization.
- A 1,202-layer ResNet was trained and beat the accuracy of a 110-layer ResNet.
- The original Post-LN Transformer, unmodified, was trained without learning rate warmup using both Adam and SGD.
In every experiment it took less than 1% of the total training time. The left side of the figure at the top shows where in the network the factors are applied, and the right side shows one iteration of learning the factors.

![The GradInit procedure. On the left, a network from a minibatch to the loss, where each weight block W_i (convolution, BN scale, fully connected, etc.) is multiplied by a learned factor α_i. On the right, one iteration of learning α: at the bottom, the gradient g on minibatch S is measured and compared with the bound γ; at the top, if ‖g‖ > γ then ‖g‖ is reduced, and if ‖g‖ ≤ γ the loss on another minibatch S̃ is measured with the weights after one step and reduced. The bottom box describes A[g], how S̃ is built, and how the procedure ends](/note/images/articles/weight-initialization/gradinit.en.png)