Abstract
Layer-wise post-training quantization (PTQ) has become the standard for compressing Large Language Models (LLMs) due to its computational efficiency and lack of retraining requirements. However, as quantization moves into the extreme low-bit regime (2-bit and 3-bit), these methods often suffer from a catastrophic "snowball effect" where errors accumulate across layers. This paper introduces Quantization Error Propagation (QEP), a lightweight framework designed to explicitly compensate for accumulated errors from preceding layers. By shifting the optimization objective from local layer approximation to global output alignment, QEP enables stable 2-bit quantization across popular model families like Llama and Mistral with minimal computational overhead.
1. Introduction
To deploy Large Language Models (LLMs) on edge devices with limited memory, quantization is essential. Layer-wise Post-Training Quantization (PTQ) methods, such as GPTQ and AWQ, are widely adopted because they can compress models in hours rather than days. These methods typically optimize each layer independently, attempting to minimize the difference between the output of a quantized layer and its original counterpart, assuming the input to that layer is perfect.
In practice, this assumption is flawed. In a deep neural network, the input to Layer $L$ is the output of Layer $L-1$, which—if quantized—already contains errors. This paper identifies a fundamental bottleneck in current PTQ: the "snowball effect." Small quantization errors in early layers propagate and grow exponentially as they pass through the network, leading to a total collapse in model performance when pushing below 4 bits. QEP addresses this by reformulating the quantization objective to account for these upstream corruptions.
2. Methodology
2.1 Problem Reformulation
Standard PTQ methods minimize the local reconstruction error of a single layer. QEP shifts this goal to minimize the discrepancy between the original model's output and the quantized model's output at each step. The framework explicitly incorporates an accumulated error term, $\delta_l$, representing the difference between the clean input and the corrupted input received from all preceding layers.
2.2 Weight Correction and Propagation Strength
The authors derive a closed-form solution to adjust the weights of the current layer to counteract the errors coming from upstream. This results in a "correction term" added to the pre-trained weights. To ensure the model does not overfit to the small calibration datasets typically used in PTQ, the framework introduces a tunable propagation strength parameter, $\alpha_l$.
- When $\alpha=0$, the system reverts to standard PTQ.
- When $\alpha=1$, the system provides full error correction.
Empirical testing across various architectures suggests that a default value of $\alpha=0.5$ provides a robust balance between error correction and generalization.
2.3 Orthogonality and Efficiency
QEP is designed as a "plug-and-play" module. It does not replace existing techniques like GPTQ, AWQ, or QuIP; rather, it enhances them. By integrating QEP into the optimization loop of these methods, researchers can significantly improve their performance without changing their core logic. Furthermore, the correction step is computationally efficient; for a Llama-2 70B model, the QEP correction process is significantly faster than the base quantization process itself.
3. Experimental Setup
The researchers evaluated QEP across several dimensions:
- Models: Llama-2, Llama-3, and Mistral-7B.
- Calibration Data: The C4 dataset was used for GPTQ and QuIP integrations, while the Pile was used for AWQ evaluations to calculate Hessian matrices.
- Evaluation Metrics: Language modeling performance was measured via perplexity on WikiText-2, Penn Treebank (PTB), and C4. Reasoning and common-sense capabilities were tested using zero-shot benchmarks including ARC-Easy, PIQA, and StoryCloze.
4. Key Results and Insights
4.1 The 2-Bit Breakthrough
The most significant impact of QEP is observed in extreme low-bit regimes where standard PTQ typically fails. For example, standard 2-bit quantization of Llama-2-7B often results in an "exploding" perplexity (e.g., jumping to 17,783). When enhanced with QEP, the QuIP method achieves a perplexity of 11.97, making 2-bit quantization practically viable for the first time.
4.2 Correction vs. Approximation
The study demonstrates that the "optimal" quantized weights are not necessarily those that most closely approximate the original weights. Instead, the optimal weights are those that have been specifically modified to compensate for the "mistakes" made by earlier layers. This conceptual shift allows QEP to maintain model coherence even as depth increases.
4.3 State-of-the-Art Performance
QEP-enhanced QuIP currently holds state-of-the-art results for layer-wise PTQ. Notably, it outperforms some "block-wise" methods that are significantly more computationally expensive, proving that smart error propagation is more effective than brute-force local optimization.
5. Conclusion and Future Work
Quantization Error Propagation (QEP) provides a simple yet powerful solution to the error accumulation problem in LLM compression. By acknowledging and compensating for the "snowball effect," QEP pushes the boundaries of what is possible with post-training quantization.
Future research directions include the development of automated heuristics for learning the optimal propagation strength $\alpha_l$ per layer, rather than relying on a global constant. Additionally, the authors intend to explore the interaction between QEP and 1-bit quantization formats to see if the framework can sustain model logic at the absolute limit of compression.
Summary updated