Batchless Normalization: How to Normalize Activations Across Instances with Minimal Memory Requirements

Benjamin Berger, Victor Uc Cetina
12/30/2022
cs.LGcs.NE

Official code: ichteltelch/Batchless (2 stars, Python, MIT, last commit 2024-04-21).

Abstract

In training neural networks, batch normalization has many benefits, not all of them entirely understood. But it also has some drawbacks.

Show full abstract

Foremost is arguably memory consumption, as computing the batch statistics requires all instances within the batch to be processed simultaneously, whereas without batch normalization it would be possible to process them one by one while accumulating the weight gradients. Another drawback is that that distribution parameters (mean and standard deviation) are unlike all other model parameters in that they are not trained using gradient descent but require special treatment, complicating implementation. In this paper, I show a simple and straightforward way to address these issues. The idea, in short, is to add terms to the loss that, for each activation, cause the minimization of the negative log likelihood of a Gaussian distribution that is used to normalize the activation. Among other benefits, this will hopefully contribute to the democratization of AI research by means of lowering the hardware requirements for training larger models.

View on arXivView PDF

Code Implementations(1)

MIT

Code for the batchless normalization paper

20PythonMay 12, 20232 years agoMIT

Similar Papers

Cite this paper

@article{berger2022batchless,
  title  = {Batchless Normalization: How to Normalize Activations Across Instances with Minimal Memory Requirements},
  author = {Benjamin Berger and Victor Uc Cetina},
  year   = {2022},
  eprint = {2212.14729},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2212.14729}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2212.14729.svg)](https://codeofpaper.com/paper/2212.14729)

Discussion