Integer Quantization for Deep Learning Inference: Principles and Empirical Evaluation

Hao Wu, Patrick Judd, Xiaojie Zhang, Mikhail Isaev, Paulius Micikevicius
4/20/2020
540 citations
cs.LGstat.ML
quantization-pruning

Official code: huggingface/transformers (169,409 stars, Python, Apache-2.0, PyTorch, last commit 2026-04-30).

Abstract

Quantization techniques can reduce the size of Deep Neural Networks and improve inference latency and throughput by taking advantage of high throughput integer instructions. In this paper we review the mathematical aspects of quantization parameters and evaluate their choices on a wide range of neural network models for different application domains, including vision, speech, and language.

Show full abstract

We focus on quantization techniques that are amenable to acceleration by processors with high-throughput integer math pipelines. We also present a workflow for 8-bit quantization that is able to maintain accuracy within 1% of the floating-point baseline on all networks studied, including models that are more difficult to quantize, such as MobileNets and BERT-large.

View on arXivView PDF

Code Implementations(1)

PyTorchApache-2.0

🤗 Transformers: the model-definition framework for state-of-the-art machine learning models in text, vision, audio, and multimodal models, for both inference and training.

169,40935,271Python, DockerfileOct 29, 20187 months agoApache-2.0
audiodeep-learningdeepseekgemmaglm+14 more

Similar Papers

Cite this paper

@article{wu2020integer,
  title  = {Integer Quantization for Deep Learning Inference: Principles and Empirical Evaluation},
  author = {Hao Wu and Patrick Judd and Xiaojie Zhang and Mikhail Isaev and Paulius Micikevicius},
  year   = {2020},
  eprint = {2004.09602},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2004.09602}
}

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

Discussion