Cherry on Top: Parameter Heterogeneity and Quantization in Large Language Models

This paper reveals the phenomenon of parameter heterogeneity in large language models (LLMs). We find that a small subset of "cherry" parameters exhibit a disproportionately large influence on model performance, while the vast majority of parameters have minimal impact. This heterogeneity is found to be prevalent across different model families, scales, and types. Motivated by this observation, we propose CherryQ, a novel quantization method that unifies the optimization of mixed-precision parameters. CherryQ identifies and preserves the critical cherry parameters in high precision while aggressively quantizing the remaining parameters to low precision. Extensive experiments demonstrate the effectiveness of CherryQ. CherryQ outperforms existing quantization approaches in terms of perplexity and downstream task performance. Notably, our 3-bit quantized Vicuna-1.5 exhibits competitive performance compared to their 16-bit counterparts.

Paper

References (30)

Scroll for more · 18 remaining

Similar papers

Peer review

Reviewer P3Ag5/10 · confidence 4/52024-07-08

Summary

The paper introduces a quantization technique for LLMs, inspired by an empirical study on parameter importance. The authors identify a small subset of parameters, termed "Cherry parameters," which exhibit significantly higher importance than others. They propose an optimization strategy: retaining full precision for Cherry parameters and their gradients, while quantizing the normal parameters. A straight-through estimator is used to handle the gradients of these quantized parameters during optimization.

Strengths

1. The paper begins with a weight importance analysis, providing an insightful empirical study as a foundation. 2. The proposed method is straightforward to implement.

Weaknesses

Weaknesses: 1. Section 3: The method depends on back-propagation, which could lead to computational and memory overhead challenges in resource-limited scenarios, such as quantizing an extremely large model with only 4 GPUs. However, this issue is acknowledged in Section 8. 2. Section 4: The Fisher information matrix is recalculated at each step. Given that parameters are updated frequently, this could cause the parameter importance to fluctuate significantly, potentially leading to a chain error. This is because gradients influence cherry parameter identification, which in turn affects gradient calculations. The paper does not address how to manage this cyclic error effectively. 3. Section 5: The model for assessing weight importance is based on Optimal Brain Damage and only considers the impact of individual weights when perturbed or quantized. It overlooks the synergistic effects between weights, where quantizing two normal parameters together could have a more significant impact than quantizing one cherry parameter. 4. Section 5: There seems to be a discrepancy in how weight importance is presented: Figure 2 is per weight matrix, whereas Figure 1 is per weight scalar. In the experiments, parameter impact scores are averaged along rows, and cherry parameter identification is performed along columns based on these averages, leading to confusion. If cherry parameter identification is indeed column-based, some cherry parameters may be overshadowed by dominant normal parameters in the same column, leading to potential misidentification. 5. Section 6.2: The improvement in perplexity over OmniQuant is marginal, as shown in Tables 1 and 2. Furthermore, it is weird that OmniQuant is omitted in the QA evaluations in Tables 3 and 4. I would be inclined to improve the rating if these points are properly addressed.

Questions

Please see Weaknesses.

Rating

5

Confidence

4

Soundness

2

Presentation

3

Contribution

3

Limitations

Please see Weaknesses.

Reviewer YuKp7/10 · confidence 4/52024-07-12

Summary

This paper presents a new post-training quantization strategy called "CherryQ" that identifies "cherries" --- meaning parameters that disproportionately impact the model's loss --- stores those in fp16, and quantizes the rest of the model parameters using a standard symmetric min-max quantization (with groups). It shows that this approach yields better perplexity and downstream performance numbers than existing quantization methods, on several models (Llama-3 7b/13, Vicuna 1.5 7b/13b), several tasks (c4/wiki perplexity, Hellaswag, Winogrande, ARC, TruthfulQA, GSM8K, MMLU, chat win-rate), and at several compression rates (2 bits, 3 bits, 4 bits). Some more details: - To identify cherries, the paper proposes using E[g_i^2] as a measure of the impact of parameter w_i on the loss, where g_i is the gradient of the loss function with respect to that parameter. This is motivated by: (1) approximating the loss around each parameter w_i using a second order Taylor expansion, assuming E[g_i] = 0 (because model has converged), and assuming the second-order derivative of L w.r.t. w_i is equal to E[g_i^2] (based on results about Fisher information matrix equaling the Hessian from [16]). - The paper shows that selecting cherries in this way (using the above approximation of the impact of each parameter on the loss) is better than using alternative metrics based on model weights or activations. - Once cherries are identified, the non-cherries are quantized, and then the model is fine-tuned by training the cherries in a regular manner (non-quantized gradients and updates), while training the (quantized) non-cherries using the straight-through estimator.

Strengths

- The paper demonstrates that some parameters have *much* larger impact on loss than others (at least according to their way of approximating impact), a surprising result, that nicely motivates using mixed precision quantization. - The proposed method perform well across numerous models, tasks, and compression rates relative to baselines. - The proposed method is pretty simple and straightforward.

Weaknesses

- It would have been useful to **directly** confirm that the proposed way of approximating impact on loss is actually a good approximation of the impact of a parameter on the loss. This was only done in indirect ways (e.g., by showing that quantizing these parameters leads to better performance than quantizing using other metrics). It should be relatively straightforward to do this by selecting a random set of model parameters (both cherries and non-cherries), perturbing them slightly (one-by-one), and passing data through the perturbed and unperturbed model and measuring the loss difference. One could then show a scatter plot (and measure spearman rank correlation) to visualize how well the approximated impact on loss (E[g_i^2]) aligns with the actual impact on loss. - QuIP (https://arxiv.org/abs/2307.13304) and QuIP# (https://arxiv.org/abs/2402.04396) are not compared to, and more recent state-of-the-art models are not benchmarked (e.g., Llama3). - No inference speed results are shared. It would be great to see if this method can directly lead to faster inference, especially during decoding (which is memory-bound).

Questions

- See weaknesses. Are there any obstacles to running the experiment to validate the use of E[g_i^2] as the metric for measuring impact on loss? - How "data-dependent" are the cherries? Can this be measured? - How does CherryQ compare with QuIP/QuIP# on Llama-3?

Rating

7

Confidence

4

Soundness

3

Presentation

4

Contribution

3

Limitations

Limitations are discussed, though could be addressed better with some experiments (see questions above).

Reviewer P3Ag2024-08-08

.

W1: addressed. W2: Okay. W3: I am not fully convinced. $|H_{ii}| \gg |H_{ij}|$ does not necessarily indicates that the synergy between neurons is much less significant than individual parameter's effect. the $H_{ij}$ are average acrossed pairs of parameters. It is to note that sometimes parameters coalate in larger groups. But I think this problem might be analyzed in a seperate work. Finally, I hope the reviewers cand discuss this point in the limitations. W4: Okay. I carefully read line 158-159 and also said that the importance are averaged across rows. I was asking because Figure 2 was confusing after I read line 158-159. It is better that the authors add some additional explanations in the caption of Figure 2. W5: Okay, athough the average QA performance gain in the above table is only 1.13%. I increase my ratings now. I hope the authors can incorporate my suggestions in their revision. Cheers.

Authorsrebuttal2024-08-13

Thank you for acknowledging our responses and for raising your ratings. We appreciate your valuable feedback and will incorporate your suggestions into the revised version.

Authorsrebuttal2024-08-14

We conducted a cross-dataset analysis to evaluate the consistency of cherry parameters across different datasets. Specifically, we compared cherry parameters identified from C4 and WikiText datasets. We performed 9 independent sampling trials, each using 128 samples from both datasets. Our analysis revealed an **average overlap rate of 68%** between the cherry parameters identified from C4 and WikiText. This overlap, while lower than the 84% observed within the same dataset, still represents a substantial consistency across datasets. The difference can be attributed to dataset-specific characteristics influencing parameter importance. This suggests a strong core consistency in cherry parameters. There are also potentials for dataset-specific optimizations in future research.

Program Chairsdecision2024-09-25

Decision

Accept (poster)

© 2026 NYSGPT2525 LLC