MimicNorm: Weight Mean and Last BN Layer Mimic the Dynamic of Batch Normalization

Wen Fei, Wenrui Dai, Chenglin Li, Junni Zou, Hongkai Xiong · OpenReview

Abstract

Substantial experiments have validated the success of Batch Normalization (BN) Layer in benefiting convergence and generalization. However, BN requires extra memory and float-point calculation. Moreover, BN would be inaccurate on micro-batch, as it depends on batch statistics. In this paper, we address these problems by simplifying BN regularization while keeping two fundamental impacts of BN layers, i.e., data decorrelation and adaptive learning rate. We propose a novel normalization method, named MimicNorm, to improve the convergence and efficiency in network training. MimicNorm consists of only two light operations, including modified weight mean operations (subtract mean values from weight parameter tensor) and one BN layer before loss function (last BN layer). We leverage the neural tangent kernel (NTK) theory to prove that our weight mean operation whitens activations and transits network into the chaotic regime like BN layer, and consequently, leads to an enhanced convergence. The last BN layer provides autotuned learning rates and also improves accuracy. Experimental results show that MimicNorm achieves similar accuracy for various network structures, including ResNets and lightweight networks like ShuffleNet, with a reduction of about 20% memory consumption.

Introduction

Batch Normalization (BN) is often considered the "secret sauce" of deep learning, enabling the training of very deep architectures. However, it comes with a significant memory cost—storing mean and variance statistics for every layer—and its performance degrades on small "micro-batches" where statistics become noisy. MimicNorm seeks to provide the benefits of BN—specifically data decorrelation and adaptive learning rate tuning—without the heavy memory overhead and batch-size dependency.

Methods: The MimicNorm Architecture

MimicNorm replaces memory-heavy intermediate BN layers with two primary components:

  1. Weight Mean (WM) Operation: Instead of normalizing activations (which requires tracking batch statistics), MimicNorm subtracts the mean from the weight parameters themselves along the output channel dimension. This is a static operation on parameters that does not require the massive buffers used by standard BN.
  2. The Last BN Layer: The architecture retains exactly one BN layer, placed right before the loss function. This final layer is crucial for "auto-tuning" the learning rate, preventing output variance from exploding and allowing for larger learning rates.
Comparison of standard BatchNorm and the proposed MimicNorm architecture, highlighting the shift to Weight Mean and a final BN layer.

For residual networks, the authors also introduce a learnable scalar multiplier at the end of each skip-connection branch to manage variance accumulation as depth increases.

Key Insights and Theoretical Foundation

The effectiveness of MimicNorm is grounded in Neural Tangent Kernel (NTK) theory. In standard ReLU networks without normalization, activations become highly correlated as they go deeper (the "ordered" phase), leading to poor training. The weight-mean operation ensures the network stays in the "chaotic" phase, where inputs remain decorrelated and whitened.

Activation distributions for 50-layer networks using BN versus Weight Mean (WM), demonstrating that WM effectively mimics BN's whitening effect.

As shown in the figure above, the weight-mean operation successfully mimics the activation distribution of standard BN, ensuring that the network remains well-conditioned for training without requiring intermediate normalization layers.

Experimental Results

The researchers validated MimicNorm on standard benchmarks including CIFAR-100 and ImageNet:

  • Comparable Accuracy: On ImageNet with ResNet50, MimicNorm reached 76.84% accuracy, slightly outperforming standard BN (76.48%). On CIFAR-100 with ResNet18, it achieved 74.96% vs. BN's 74.72%.
  • Memory Efficiency: MimicNorm consistently reduced memory consumption by approximately 20%. For ResNet50 on CIFAR-100, memory usage dropped from 8533MB to 7533MB.
  • Lightweight Performance: On ShuffleNetV2, a network designed for mobile devices, MimicNorm maintained accuracy while reducing memory usage by nearly 800MB.

Conclusion

MimicNorm offers a compelling alternative for researchers and engineers who require the stability of Batch Normalization without the associated memory tax. By disentangling the roles of decorrelation and rate-tuning, it achieves state-of-the-art performance while significantly improving hardware efficiency.

Summary updated

Abstract

Substantial experiments have validated the success of Batch Normalization (BN) Layer in benefiting convergence and generalization. However, BN requires extra memory and float-point calculation. Moreover, BN would be inaccurate on micro-batch, as it depends on batch statistics. In this paper, we address these problems by simplifying BN regularization while keeping two fundamental impacts of BN layers, i.e., data decorrelation and adaptive learning rate. We propose a novel normalization method, named MimicNorm, to improve the convergence and efficiency in network training. MimicNorm consists of only two light operations, including modified weight mean operations (subtract mean values from weight parameter tensor) and one BN layer before loss function (last BN layer). We leverage the neural tangent kernel (NTK) theory to prove that our weight mean operation whitens activations and transits network into the chaotic regime like BN layer, and consequently, leads to an enhanced convergence. The last BN layer provides autotuned learning rates and also improves accuracy. Experimental results show that MimicNorm achieves similar accuracy for various network structures, including ResNets and lightweight networks like ShuffleNet, with a reduction of about 20% memory consumption. The code is publicly available at https://github.com/Kid-key/MimicNorm.
BibTeX
@misc{fei2020mimicnorm,
  author = {Wen Fei and Wenrui Dai and Chenglin Li and Junni Zou and Hongkai Xiong},
  title = {{MimicNorm: Weight Mean and Last BN Layer Mimic the Dynamic of Batch Normalization}},
  year = {2020},
  eprint = {2010.09278},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2010.09278},
}
Figure