Quantization Error: Linear Amplification by Activation Peaks
Quantization error in LLMs is directly proportional to the magnitude of input activations; larger activation values linearly magnify errors introduced during quantization, leading to greater distortion in the layer's output.
The top 3
- Top 3 Techniques to Counter Activation Peak Errors: Clipping activations (e.g., PACT) to limit extreme values, dynamic quantization for on-the-fly range adaptation, and selectively exempting "quantization-free" modules are key strategies to reduce error amplification from activation spikes.
- GLU Variants: LLM's Biggest Activation Spike Culprit: Gated Linear Unit (GLU) variants, prevalent in the feed-forward networks (FFN) of modern LLMs like LLaMA, are identified as primary generators of "activation spikes"—excessively large values causing severe local quantization errors, particularly in early and late layers.
- ReLU vs. GeLU vs. SiLU: Which Amplifies Quantization Error Most?: While ReLU can produce sharp peaks, GeLU and SiLU, prevalent in modern LLMs, are often associated with more pronounced and widespread activation outliers, leading to greater quantization error amplification due to their non-linear, often unbounded, output distributions.
Sources
Open the full topic