Understanding the Impact of Post-Training Quantization on Large-scale Language Models

要約

大規模言語モデル (LLM) のサイズは急速に増大しており、パラメーターの数が ChatGPT、Claude、Bard などの多くの商用モデルの成功の重要な要素となっています。
Falcon や Llama2 など、最近リリースされた商業用途向けに一般にアクセス可能なモデルでさえ、数十億のパラメータを備えています。
このパラメータ数の大幅な増加により、展開と運用のコストが非常に高くなります。
大規模ニューラル ネットワーク全般、特に LLM の量子化の分野における目覚ましい進歩により、これらのモデルをコンシューマー グレードの GPU に展開できるようになり、アクセスしやすくなりました。
量子化モデルは通常、量子化されていないベースのモデルと同等のパフォーマンス レベルを示します。
それにもかかわらず、特にデコード段階で、これらの量子化モデルが温度、新しいトークンの最大数、top\_k などのハイパーパラメーターにどのように応答するかについての包括的な理解には、顕著なギャップが存在します。
今回の分析により、nf4 と fp4 は同様に優れた 4 ビット量子化技術であり、推論速度、メモリ消費量、生成されたコンテンツの品質などの類似した属性によって特徴付けられることが明らかになりました。
それにもかかわらず、これらの量子化方法は、より小さなモデルとより大きなモデルの両方において、さまざまな温度設定で異なる動作を示します。
一般に、さまざまなサイズの 4 ビット量子化モデルは、量子化されていないモデルとは異なり、より低い温度設定に対して高い感度を示すことは注目に値します。
さらに、int8 量子化は推論速度が大幅に遅くなりますが、量子化されていない fp16 モデルは、すべてのサイズのモデルにわたって一貫して最速の推論速度をもたらします。

要約(オリジナル)

Large language models (LLMs) are rapidly increasing in size, with the number of parameters becoming a key factor in the success of many commercial models, such as ChatGPT, Claude, and Bard. Even the recently released publicly accessible models for commercial usage, such as Falcon and Llama2, come equipped with billions of parameters. This significant increase in the number of parameters makes deployment and operation very costly. The remarkable progress in the field of quantization for large neural networks in general and LLMs in particular, has made these models more accessible by enabling them to be deployed on consumer-grade GPUs. Quantized models generally demonstrate comparable performance levels to their unquantized base counterparts. Nonetheless, there exists a notable gap in our comprehensive understanding of how these quantized models respond to hyperparameters, such as temperature, max new tokens, and top\_k, particularly during the decoding phase. The present analysis reveals that nf4 and fp4 are equally proficient 4-bit quantization techniques, characterized by similar attributes such as inference speed, memory consumption, and the quality of generated content. Nevertheless, these quantization methods exhibit distinct behaviors at varying temperature settings, both in the context of smaller and larger models. It is noteworthy that, in general, 4-bit quantized models of varying sizes exhibit heightened sensitivity to lower temperature settings, unlike their unquantized counterparts. Additionally, int8 quantization is associated with significantly slower inference speeds, whereas unquantized fp16 models consistently yield the fastest inference speeds across models of all sizes.

arxiv情報

著者 Somnath Roy
発行日 2023-09-11 02:58:32+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.CL パーマリンク