Why Low-Bit Quantization Is Hard

Three first-principle problems: quantization creates rounding/clipping error, scale controls the error tradeoff, and nearest rounding can be locally correct but globally bad for LLM layers.

Quant:
q = clamp(round(x / s), qmin, qmax)
DeQuant:
xdq = q × s
Error:
e = xdq − x
1

Rounding error and clipping error

INT4 only has a small set of grid points. Values inside the range are rounded; values outside the range are clipped.

Rounding: value is inside range

s = 0.1, INT4 range = [-0.7, 0.7]
-0.7
-0.3
0
0.3
0.7
x = 0.26
xdq = 0.30
x / s0.26 / 0.1 = 2.6
round2.6 → 3
dequant3 × 0.1 = 0.3

Clipping: value is outside range

s = 0.1, representable max = 7s = 0.7
-0.7
0
0.7
x = 1.20
clipped to 0.70
x / s1.2 / 0.1 = 12
clamp12 → 7
dequant7 × 0.1 = 0.7
Original FP value
Dequantized value
Out-of-range value
2

Scale selection is a tradeoff

The scale chooses both the grid spacing and the representable range. Large scale protects outliers; small scale preserves normal values.

Large scale: protect outlier

s = 2.0 / 7 ≈ 0.286
-2.0
0
2.0
EffectResult
Outlier 2.0Preserved
Small values 0.05, 0.08, 0.10Collapse to 0
Dominant errorRounding error for normal values

Small scale: preserve normal values

s = 0.03, representable max = 0.21
-0.21
0
0.21
EffectResult
Small values 0.05, 0.08, 0.10Preserved well
Outlier 2.0Clipped to 0.21
Dominant errorClipping error for outliers
First-principle view: scale is the knob that trades precision against range. In INT4, you only have 16 buckets, so you cannot represent tiny normal values and large outliers perfectly at the same time.
3

Rounding is not always harmless

Nearest rounding minimizes scalar error, but LLM layers care about output error after GEMM: Y = XW.

Nearest rounding: locally correct

x = [1, 1], w = [0.49, 0.49], s = 1.0
X
[1, 1]
Wfp
[0.49, 0.49]
Y = XW
0.98
Target
0.98
X
[1, 1]
Wq
[0, 0]
Yq
0
Error
0.98

Each 0.49 is closer to 0 than 1, so nearest rounding chooses [0, 0]. But the layer output becomes very wrong.

Non-nearest rounding: globally better

One value is rounded “wrong” locally
X
[1, 1]
Wq
[1, 0]
Yq
1
Error
0.02
Scalar view
0.49 → 1
locally worse
Layer view
globally better

The model does not optimize each weight alone. It cares about whether XW is preserved after quantization.

Key idea: nearest rounding minimizes |w − wq|, but quantization-aware algorithms care more about ||XW − XWq||. That is why methods like GPTQ, AWQ, and AutoRound optimize rounding, clipping, or scaling using calibration data.