FP8 Quantization: The Power of the Exponent
Andrey Kuzmin, Mart van Baalen, Yuwei Ren, Markus Nagel, Jorn Peters, Tijmen Blankevoort
Abstract
When quantizing neural networks for efficient inference, low-bit integers are the go-to format for efficiency. However, low-bit floating point numbers have an extra degree of freedom, assigning some bits to work on an exponential scale instead. This paper in-depth investigates this benefit of the floating point format for neural network inference. We detail the choices that can be made for the FP8 format, including the important choice of the number of bits for the mantissa and exponent, and show analytically in which settings these choices give better performance. Then we show how these findings translate to real networks, provide an efficient implementation for FP8 simulation, and a new algorithm that enables the learning of both the scale parameters and the number of exponent bits in the FP8 format. Our chief conclusion is that when doing post-training quantization for a wide range of networks, the FP8 format is better than INT8 in terms of accuracy, and the choice of the number of exponent bits is driven by the severity of outliers in the network. We also conduct experiments with quantization-aware training where the difference in formats disappears as the network is trained to reduce the effect of outliers.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
23 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Intriguing Properties of Quantization at Scale cites Up or Down? Adaptive Rounding for Post-Training Quantization
- Outlier Suppression+: Accurate quantization of large language models by equivalent and effective shifting and scaling cites Learned Step Size quantization
- Outlier Suppression+: Accurate quantization of large language models by equivalent and effective shifting and scaling cites HAWQ: Hessian AWare Quantization of Neural Networks With Mixed-Precision
- Outlier Suppression+: Accurate quantization of large language models by equivalent and effective shifting and scaling cites Up or Down? Adaptive Rounding for Post-Training Quantization
- Learning from Students: Applying t-Distributions to Explore Accurate and Efficient Formats for LLMs cites Pruning vs Quantization: Which is Better?
- Pruning vs Quantization: Which is Better? cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
- Pruning vs Quantization: Which is Better? cites Learned Step Size quantization
- Pruning vs Quantization: Which is Better? cites HAWQ: Hessian AWare Quantization of Neural Networks With Mixed-Precision
- Pruning vs Quantization: Which is Better? cites Up or Down? Adaptive Rounding for Post-Training Quantization
- Up or Down? Adaptive Rounding for Post-Training Quantization cites Learned Step Size quantization
- Up or Down? Adaptive Rounding for Post-Training Quantization cites HAWQ: Hessian AWare Quantization of Neural Networks With Mixed-Precision
- Ladder: Enabling Efficient Low-Precision Deep Learning Computing through Hardware-aware Tensor Transformation cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
Cited by top-tier papers23
- Pruning vs Quantization: Which is Better?Andrey Kuzmin, Markus Nagel, Mart van Baalen, Arash Behboodi et al.NeurIPS 2023 · 152 citations
- Intriguing Properties of Quantization at ScaleArash Ahmadian, Saurabh Dash, Hongyu Chen, Bharat Venkitesh et al.NeurIPS 2023 · 56 citations
- Ladder: Enabling Efficient Low-Precision Deep Learning Computing through Hardware-aware Tensor TransformationLei Wang, Lingxiao Ma, Shijie Cao, Quanlu Zhang et al.OSDI 2024 · 56 citations
- Outlier Suppression+: Accurate quantization of large language models by equivalent and effective shifting and scalingXiuying Wei, Yunchen Zhang, Yuhang Li, Xiangguo Zhang et al.EMNLP 2023 · 40 citations
- Learning from Students: Applying t-Distributions to Explore Accurate and Efficient Formats for LLMsJordan Dotzel, Yuzong Chen, Bahaa Kotb, Sushma Prasad et al.ICML 2024 · 20 citations
Builds on10
- An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
- SemanticKITTI: A Dataset for Semantic Scene Understanding of LiDAR SequencesJens Behley, Martin Garbade, Andres Milioto, Jan Quenzel et al.ICCV 2019 · 2,345 citations
- Learned Step Size quantizationSteven K. Esser, Jeffrey L. McKinstry, Deepika Bablani, Rathinakumar Appuswamy et al.ICLR 2020 · 1,037 citations
- Up or Down? Adaptive Rounding for Post-Training QuantizationMarkus Nagel, Rana Ali Amjad, Mart van Baalen, Christos Louizos et al.ICML 2020 · 816 citations
- HAWQ: Hessian AWare Quantization of Neural Networks With Mixed-PrecisionZhen Dong, Zhewei Yao, Amir Gholami, Michael W. Mahoney et al.ICCV 2019 · 645 citations
Related papers
- Shifted and Squeezed 8-bit Floating Point format for Low-Precision Training of Deep Neural NetworksLéopold Cambier, Anahita Bhiwandiwalla, Ting Gong, Oguz H. Elibol et al.ICLR 2020 · 53 citations
- Unit Scaling: Out-of-the-Box Low-Precision TrainingCharlie Blake, Douglas Orr, Carlo LuschiICML 2023 · 15 citations
- MERSIT: A Hardware-Efficient 8-bit Data Format with Enhanced Post-Training Quantization DNN AccuracyNguyen-Dong Ho, Gyujun Jeong, Cheol-Min Kang, Seungkyu Choi et al.DAC 2024 · 3 citations
- µnit Scaling: Simple and Scalable FP8 LLM TrainingSaaketh Narayan, Abhay Gupta, Mansheej Paul, Davis W. BlalockICML 2025
- Scaling Laws for Floating-Point Quantization TrainingXingwu Sun, Shuaipeng Li, Ruobing Xie, Weidong Han et al.ICML 2025
