Taking ϵ→0, how do you prove that batch normalisation makes a layer’s output invariant to positive scalar rescaling of its weights, BN⁡(cWx)=BN⁡(Wx) for any c>0, and what does this imply for the weight gradient ∇cWL and the effective learning rate during SGD?

Deep learning, Normalisation
Level L4 Advanced. Length Long. Nature Mat Mathematical.

What's being asked

Whether you can prove BN’s scale invariance and deduce both the 1/c gradient scaling and the growth of weight norms during training.

Key idea

Scaling pre-activations z=Wx by c>0 multiplies both the batch mean μB and standard deviation σB by c, so z^ and BN⁡(cWx) are unchanged. Because L(cW)=L(W) for all c>0, differentiating with respect to W gives ∇cWL=1c∇WL, and differentiating with respect to c at c=1 shows ⟨∇WL,W⟩=0 (where ⟨A,B⟩=tr⁡(A⊤B) is the Frobenius inner product).

Steps

  1. Forward invariance: let zi=Wxi and zi′=cWxi=czi for c>0. Then μB(z′)=c μB(z) and σB(z′)=1m∑i(czi−cμB)2=c σB(z) (taking ϵ→0 and c>0). Hence zi′−μB(z′)σB(z′)=zi−μB(z)σB(z), so BN⁡(cWx)=BN⁡(Wx).
  2. Gradient scaling: write f(W)=L(BN⁡(WX)) so f(cW)=f(W) for every W. Taking ∇W of both sides via the chain rule gives c (∇f)(cW)=(∇f)(W), i.e. ∇cWL=1c∇WL.
  3. Orthogonality to W: differentiate f(cW)=f(W) with respect to c at c=1: ddcf(cW)∣c=1=⟨∇WL,W⟩=0.
  4. Consequence for SGD without weight decay: an update Wt+1=Wt−η∇WL satisfies ∥Wt+1∥F2=∥Wt∥F2+η2∥∇WL∥F2>∥Wt∥F2 (Pythagoras, since ∇WL⊥Wt and ∥⋅∥F is the Frobenius norm). Because cW−η∇cWL=c(W−ηc2∇WL), growing ∥Wt∥F by c shrinks the effective learning rate by 1/c2—which is why weight decay helps keep ∥W∥F bounded.

Common mistakes

How long your answer should be

About one page; 5–7 minutes.

Last checked on 4 December 2026.

Read this

Previous in Deep learning: For a quadratic loss J(w)=12(w−w∗)⊤H(w−w∗) with symmetric positive definite Hessian H (whose largest eigenvalue is λmax⁡(H)), started at w0=0 with gradient descent step size 0<η<1/λmax⁡(H), how do you show that stopping after t iterations acts approximately like L2 regularisation with penalty λ≈1ηt?
Next in Deep learning: Why do modern deep networks such as Transformers and large-batch CNNs typically start training with a learning-rate warm-up instead of immediately using the peak learning rate?