What LLMs train with and what it costs
LLMs usually train with 16-bit floating point parameters (a.k.a FP16/BF16). [1]
Thus, storing the value of a single weight or activation value requires 2 bytes of memory. [2]
Why floating point costs more
In addition, floating point arithmetic is more complex and slower than integer arithmetic and requires additional computing power. [3]
What quantization does
Quantization is a model compression technique that aims to solve both problems by reducing the range of unique values that model parameters can take. [4]
In a nutshell, quantization rescales model parameters to smaller value ranges. [5]
Sources
- The Hugging Face source says: LLMs usually train with 16-bit floating point parameters (a.k.a FP16/BF16). Smaller is better: Q8-Chat, an efficient generative AI experience on Xeon
- The Hugging Face source says: Thus, storing the value of a single weight or activation value requires 2 bytes of memory. Smaller is better: Q8-Chat, an efficient generative AI experience on Xeon
- The Hugging Face source says: In addition, floating point arithmetic is more complex and slower than integer arithmetic and requires additional computing power. Smaller is better: Q8-Chat, an efficient generative AI experience on Xeon
- The Hugging Face source says: Quantization is a model compression technique that aims to solve both problems by reducing the range of unique values that model parameters can take. Smaller is better: Q8-Chat, an efficient generative AI experience on Xeon
- The Hugging Face source says: In a nutshell, quantization rescales model parameters to smaller value ranges. Smaller is better: Q8-Chat, an efficient generative AI experience on Xeon