Skip to main content
QUICK REVIEW

[Paper Review] An empirical study of LLaMA3 quantization: from LLMs to MLLMs

Wei Huang, Xingyu Zheng|arXiv (Cornell University)|Apr 22, 2024
Advanced Wireless Communication TechniquesEngineering11 citations
TL;DR

This paper empirically evaluates low-bit quantization on Meta’s LLaMA3 models using post-training quantization (PTQ) and LoRA-finetuning (LoRA-FT), showing non-negligible performance degradation at ultra-low bits, with LLaMA3-70B exhibiting greater robustness than LLaMA3-8B across tested datasets.

ABSTRACT

The LLaMA family, a collection of foundation language models ranging from 7B to 65B parameters, has become one of the most powerful open-source large language models (LLMs) and the popular LLM backbone of multi-modal large language models (MLLMs), widely used in computer vision and natural language understanding tasks. In particular, LLaMA3 models have recently been released and have achieved impressive performance in various domains with super-large scale pre-training on over 15T tokens of data. Given the wide application of low-bit quantization for LLMs in resource-constrained scenarios, we explore LLaMA3's capabilities when quantized to low bit-width. This exploration can potentially provide new insights and challenges for the low-bit quantization of LLaMA3 and other future LLMs, especially in addressing performance degradation issues that suffer in LLM compression. Specifically, we comprehensively evaluate the 10 existing post-training quantization and LoRA fine-tuning (LoRA-FT) methods of LLaMA3 on 1-8 bits and various datasets to reveal the low-bit quantization performance of LLaMA3. To uncover the capabilities of low-bit quantized MLLM, we assessed the performance of the LLaMA3-based LLaVA-Next-8B model under 2-4 ultra-low bits with post-training quantization methods. Our experimental results indicate that LLaMA3 still suffers from non-negligible degradation in linguistic and visual contexts, particularly under ultra-low bit widths. This highlights the significant performance gap at low bit-width that needs to be addressed in future developments. We expect that this empirical study will prove valuable in advancing future models, driving LLMs and MLLMs to achieve higher accuracy at lower bit to enhance practicality. Our project is released on https://github.com/Macaronlin/LLaMA3-Quantization , and quantized models are released at https://huggingface.co/Efficient-ML .

Motivation & Objective

  • Assess how LLaMA3 models (8B and 70B) perform under low-bit quantization.
  • Evaluate a wide range of PTQ methods and LoRA-FT techniques from 1 to 8 bits.
  • Identify the accuracy degradation patterns and robustness differences between model scales.
  • Provide practical insights to guide future LLM quantization research and development.

Proposed method

  • Quantize LLaMA3-8B and LLaMA3-70B using eight PTQ methods and two LoRA-FT methods.
  • Evaluate PTQ quantized models on WikiText2, C4, PTB, and zero-shot tasks PIQA, Winogrande, ARC-e, ARC-c, Hellaswag.
  • Evaluate LoRA-FT quantized LLaMA3-8B on MMLU and confirm zero-shot tasks.
  • Use WikiText2 calibration (128 tokens, 2048 sequence length) for fairness across methods.
  • Apply channel-wise grouping with block size 128 when needed.
  • Compare with baseline FP16/32BIT performance and report perplexity and task accuracies.

Experimental results

Research questions

  • RQ1How does LLaMA3-8B perform under various PTQ and LoRA-FT quantization methods across standard benchmarks?
  • RQ2How does LLaMA3-70B compare in robustness to quantization relative to LLaMA3-8B under the same methods?
  • RQ3Do ultra-low-bit quantizations (1-2 bits) yield acceptable performance, and which methods best preserve accuracy?
  • RQ4Does LoRA-FT quantization provide reliable gains for LLaMA3, or does pretraining scale limit its effectiveness?
  • RQ5What are practical implications for deploying quantized LLaMA3 in resource-constrained environments?

Key findings

  • Quantized LLaMA3-8B and -70B experience non-negligible degradation at ultra-low bit-widths across PTQ methods.
  • Ultra-low-bit (2-bit and below) performance can be significantly worse for 8B than for 70B, with certain ultra-low-bit methods performing poorly.
  • LoRA-FT quantization on LLaMA3-8B does not consistently compensate for quantization errors and can underperform compared to non-LoRA-FT 4-bit baselines.
  • 4-bit LoRA-FT quantized LLaMA3-8B can outperform some 4-bit LLaMA1/2 baselines, suggesting a shift in quantization dynamics with newer models.
  • Certain PTQ methods (e.g., PB-LLM, BiLLM, DB-LLM, QuIP, AWQ, GPTQ) show varying strengths, with ultra-low-bit techniques like BiLLM and PB-LLM pushing 1-2 bit performance but not universally closing the gap to full precision.
  • SmoothQuant helps stabilize activation quantization for some configurations but collapses at very low bit-widths (e.g., 4-bit).

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.