Understanding LLM Quantization through Activation-Guided Compensation and Orthogonal Residuals
Organizations: Department of Computer Science, The University of Tokyo
Abstract
Post-training weight-activation quantization reduces the memory and inference costs of large language models, but aggressive W4A4 quantization remains difficult because activation outliers degrade effective quantization resolution. Although weight optimization, channel-wise scaling, and orthogonal rotation mitigate this problem, the error components they address and their relationship remain unclear. Using an exact decomposition of local weight-activation quantization error into an activation-guided weight compensation term and an orthogonal residual, we bound the residual using persistent channel-wise outlier and regular activation quantities. This decomposition clarifies which error components can be addressed by weight compensation and which require transformation design. We then use the residual bounds to derive practical guidelines for applying randomized Hadamard rotation, sign selection, and channel scaling. In particular, the analysis explains how random signs suppress constructive interference among persistent outlier channels, how sampling multiple sign patterns can improve transformation selection, and how second-moment balancing leads to an scaling rule while a further relaxation recovers SmoothQuant-style scaling. We evaluate these guidelines through backpropagation-free configurations across eight Llama and Mistral models, obtaining performance competitive with gradient-trained SpinQuant.
Figures & tables
| Model | FP reference | W4A4 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| W16A16 | QuaRot | SmoothRot | SpinQuant | L2-SmoothRot | ||||||
| PPL | Avg. | PPL | Avg. | PPL | Avg. | PPL | Avg. | PPL | Avg. | |
| Llama-7B | 5.67 | 69.39 | 6.12 | 66.17 | 6.13 | 66.16 | 6.19 | 66.18 | 6.09 | 66.67 |
| Llama-13B | 5.05 | 71.78 | 5.42 | 69.49 | 5.42 | 69.09 | 5.44 | 69.31 | 5.37 | 69.91 |
| Llama2-7B | 5.47 | 69.82 | 5.96 | 66.32 | 5.98 | 66.45 | 6.06 | 65.98 | 5.94 | 66.59 |
| Llama2-13B | 4.86 | 72.57 | 5.24 | 69.87 | 5.26 | 70.15 | 5.26 | 70.23 | 5.23 | 70.50 |
Appendix figures & tables1 asset
Supplementary material from the paper’s appendix.
Appendix
| Model | Bits | Method | PPL | Accuracy (%) | |||||||
| WT2 | C4 | PIQA | ARC-E | ARC-C | HS | WG | LB | Avg. | |||
| Llama-7B | W16A16 | N/A | 5.67 | 8.03 | 79.16 | 72.85 | 44.62 | 76.19 | 70.01 | 73.51 | 69.39 |
| [2pt/1pt] | W4A4 | QuaRot | 6.12 | 8.84 | 77.53 | 68.01 | 41.38 | 72.82 | 66.77 | 70.54 | 66.17 |
| SmoothRot | 6.13 | 8.87 | 77.58 | 67.72 | 40.27 | 72.66 | 67.88 | 70.83 | 66.16 | ||
| SpinQuant | 6.19 | 8.95 | 76.44 | 69.07 | 42.32 | 72.75 | 67.01 | 69.51 | 66.18 | ||
| L2-SmoothRot | 6.09 | 8.76 | 77.15 | 69.65 | 41.30 | 73.01 | 67.64 | 71.28 | 66.67 | ||
Post-Training Quantization
Post-Training Quantization compresses trained neural networks into low-bit weights, activations, or caches to reduce memory use and inference cost.
See all 360 papers