要約
大規模言語モデル(LLM)は近年、様々なタスクにおいて目覚ましい成功を収めている。しかし、LLMを効率的に処理することは、特に小バッチの推論環境(モバイルデバイスなど)において、大きなメモリボトルネックのために課題となっている。重みのみの量子化は有望なアプローチであるが、4ビット以下の量子化は、大きな活性化外れ値のために依然として課題である。この望ましくない外れ値の影響を軽減するために、我々はまず、従来の出力チャンネル毎(per-OC)ではなく、各入力チャンネル(IC)内に量子化グループを作成する、シンプルで効果的な方法であるIC毎量子化を提案する。我々の方法は、活性化外れ値が重み行列の入力次元に影響を与えるという観察から動機づけられており、同様にIC方向に重みをグループ化することで、グループ内の外れ値を分離することができる。また、活性化の外れ値が量子化の難易度を決めるわけではなく、固有の重み感度も存在することがわかった。外れ値に優しい新しいスキームとしてIC毎の量子化を用い、様々な重み感度パターンに適応できる汎用的な量子化フレームワークであるAdaptive Dimensions (AdaDim)を提案する。我々は、Round-To-NearestやGPTQなどの先行手法を補強することで、AdaDimの有効性を実証し、様々な言語モデリングベンチマークにおいて、ベースLLM(MMLUで最大+4.7%)と命令チューニングLLM(HumanEvalで最大+10%)の両方で有意な改善を示した。コードはhttps://github.com/johnheo/adadim-llm。
要約(オリジナル)
Large Language Models (LLMs) have recently demonstrated remarkable success across various tasks. However, efficiently serving LLMs has been a challenge due to the large memory bottleneck, specifically in small batch inference settings (e.g. mobile devices). Weight-only quantization can be a promising approach, but sub-4 bit quantization remains a challenge due to large-magnitude activation outliers. To mitigate the undesirable outlier effect, we first propose per-IC quantization, a simple yet effective method that creates quantization groups within each input channel (IC) rather than the conventional per-output-channel (per-OC). Our method is motivated by the observation that activation outliers affect the input dimension of the weight matrix, so similarly grouping the weights in the IC direction can isolate outliers within a group. We also find that activation outliers do not dictate quantization difficulty, and inherent weight sensitivities also exist. With per-IC quantization as a new outlier-friendly scheme, we propose Adaptive Dimensions (AdaDim), a versatile quantization framework that can adapt to various weight sensitivity patterns. We demonstrate the effectiveness of AdaDim by augmenting prior methods such as Round-To-Nearest and GPTQ, showing significant improvements across various language modeling benchmarks for both base (up to +4.7% on MMLU) and instruction-tuned (up to +10% on HumanEval) LLMs. Code is available at https://github.com/johnheo/adadim-llm
arxiv情報
著者 | Jung Hwan Heo,Jeonghoon Kim,Beomseok Kwon,Byeongwook Kim,Se Jung Kwon,Dongsoo Lee |
発行日 | 2025-03-03 06:37:01+00:00 |
arxivサイト | arxiv_id(pdf) |