flâneur

Quantization

huggingface.co · 2,230 words · saved by 1 readers

We’re on a journey to advance and democratize artificial intelligence through open source and open science.

Quantization is a technique to reduce the computational and memory costs of running inference by representing the weights and activations with low-precision data types like 8-bit integer (int8) instead of the usual 32-bit floating point (float32). Reducing the number of bits means the resulting model requires less memory storage, consumes less energy (in theory), and operations like matrix multiplication can be performed much faster with integer arithmetic. It also allows to run models on embedded devices, which sometimes only support integer data types. Theory The basic idea behind…

related reading