INT8 Quantization › Asymmetric Quantization
Language AI HandbookAll chapters INT8 Quantization › Asymmetric QuantizationOne section · Sections in this chapter4 / 15 ↓
Reading tools Definitions & inline links
Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.
Article links
Make inline references clickable
When tensor values are not centered around zero, symmetric quantization wastes representable range. ReLU activations, for example, are always non-negative. Mapping the range symmetrically would waste half our integers representing negative values that never occur. This inefficiency becomes severe when the actual data distribution is heavily skewed or shifted away from zero. With 256 integers available and only half the range needed, symmetric quantization effectively reduces your precision from 8 bits to 7 bits for these tensors.
Asymmetric quantization solves this by introducing a zero-point offset that shifts the quantization grid to the data's range. Think of it as sliding our 256-slot number line left or right until it lines up with the data distribution, rather than always keeping it centered at zero. The grid spacing remains uniform, but we can position it anywhere. This flexibility comes at a cost: more complex arithmetic during inference, as we now have two parameters (scale and zero-point) to track rather than one.
The asymmetric quantization formulas show how to derive both parameters from the data range:
where:
- : the input floating-point tensor
- : the scale factor, computed from the full data range (minimum to maximum)
- : the number of intervals in an 8-bit range ( intervals for 256 values)
- : the zero-point integer that shifts the grid to align with the data distribution
- : the resulting quantized tensor with values in
The key difference from symmetric quantization lies in how we compute the scale and the introduction of the zero-point. Instead of basing the scale on the maximum absolute value, we use the full range from minimum to maximum. This keeps all 256 integers can potentially be used. The zero-point is an integer that shifts the quantization grid so that the minimum value maps to -128 and the maximum to 127. This shift allows us to "slide" our quantization grid along the number line to wherever the actual data lies.
Dequantization reverses this process by first undoing the zero-point shift and then applying the scale:
where:
- : the reconstructed floating-point values
- : the scale factor
- : the quantized integer values
- : the zero-point offset, which is subtracted before scaling to recover the original range
While asymmetric quantization can stand for arbitrary ranges more efficiently, it complicates the mathematics during inference. Matrix multiplications now involve additional terms from the zero-point offsets. When we expand the matrix multiplication with asymmetric quantization, cross-terms involving the zero-points appear, requiring additional computation and memory access. For weights, which are typically centered around zero due to common initialization and regularization practices, symmetric quantization remains the standard choice. The computational overhead of asymmetric quantization is generally reserved for activations where the efficiency gains from better range utilization outweigh the additional complexity.

