Mixed Precision DNNs: All you need is a good parametrization

Stefan Uhlich, Lukas Mauch, Fabien Cardinaux, Kazuki Yoshiyama, Javier Alonso Garcia +3 more
5/27/2019
cs.LGcs.CVstat.ML

Official code: sony/ai-research-code (357 stars, Apache-2.0, last commit 2023-09-12).

Abstract

Efficient deep neural network (DNN) inference on mobile or embedded devices typically involves quantization of the network parameters and activations. In particular, mixed precision networks achieve better performance than networks with homogeneous bitwidth for the same size constraint. Since choosing the optimal bitwidths is not straight forward, training methods, which can learn them, are desirable. Differentiable quantization with straight-through gradients allows to learn the quantizer's parameters using gradient methods. We show that a suited parametrization of the quantizer is the key to achieve a stable training and a good final performance. Specifically, we propose to parametrize the quantizer with the step size and dynamic range. The bitwidth can then be inferred from them. Other parametrizations, which explicitly use the bitwidth, consistently perform worse. We confirm our findings with experiments on CIFAR-10 and ImageNet and we obtain mixed precision DNNs with learned quantization parameters, achieving state-of-the-art performance.

View on arXivView PDF

Code Implementations(1)

Apache-2.0
35772HTML, ShellApr 14, 20203 years agoApache-2.0

Cite this paper

@article{uhlich2019mixed,
  title  = {Mixed Precision DNNs: All you need is a good parametrization},
  author = {Stefan Uhlich and Lukas Mauch and Fabien Cardinaux and Kazuki Yoshiyama and Javier Alonso Garcia and Stephen Tiedemann and Thomas Kemp and Akira Nakamura},
  year   = {2019},
  eprint = {1905.11452},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/1905.11452}
}

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/1905.11452.svg)](https://codeofpaper.com/paper/1905.11452)

Discussion