Per-channel quantization
Per-channel quantization assigns separate quantization parameters, such as scales, to individual channels along a tensor axis.
Quantization and Fast Inference
Per-channel quantization assigns separate quantization parameters to each tensor channel.
- How it is used
- Uses per-channel quantization to limit cross-channel outlier penalties in weight compression and quantization-aware training.
- How deep it goes
- Derives symmetric scales and broadcasting, implements fake quantization, and measures reconstruction, gradient masking, metadata, and training effects.
- Examples
- Compares ResNet-18 convolution weights and INT4 gradient survival, and measures scale overhead for transformer projections.
- What you can do after
- Build a symmetric per-channel quantizer and fake quantizer, and evaluate their error and deployment tradeoffs.
Read how Quantization and Fast Inference explains per-channel quantization →
CUDA for LLMs
Channel-wise quantization uses separate quantization parameters for individual channels or output features.
- How it is used
- Adapts quantization scales to output features or attention heads with different magnitudes.
- How deep it goes
- Walks through channel indexing, INT8 quantization and dequantization kernels, and calibration-based scale selection.
- Examples
- Uses a 4,096-feature weight matrix, transformer attention heads, and a group-of-128 feed-forward comparison.
- What you can do after
- Builds from scratch CUDA quantization and dequantization kernels that load a scale for each channel.
What to know first
- activationAn activation is a numerical value or tensor produced by a neural-network unit, layer, or operation during a forward computation.
- accuracyAccuracy is the degree to which a result agrees with a specified truth, reference, or criterion, commonly measured as the proportion of evaluated predictions that are correct.
- channel dimensionA channel dimension is a dimension of image or tensor data whose positions distinguish separate color components or feature maps.
- float16float16 is a 16-bit floating-point format, commonly IEEE 754 binary16, with less precision and range than 32-bit floating-point formats.
Related concepts
- quantizationkind of · Model quantization represents model parameters or computations with reduced-precision numerical values, often to lower storage or computational requirements.
- quantization erroraddresses · Quantization error is the discrepancy between a value and its approximation when it is represented using a limited or discrete set of values.
- AWQused by · AWQ is a post-training weight-quantization method that uses activation statistics to identify and protect salient weights, reducing model-size and precision while limiting quality loss.
- keyuses · A key is an identifier or value used to locate or access an associated entry or property in a mapping or object.
- per-tensor quantizationcontrasts with · Per-tensor quantization applies a shared set of quantization parameters, such as scale and zero point, to all values in a tensor.
- post-training quantizationused by · Post-training quantization converts a trained model’s parameters or computations to lower-precision representations without further model training.
Questions about per-channel quantization
What is per-channel quantization?
Per-channel quantization assigns separate quantization parameters, such as scales, to individual channels along a tensor axis.
Which Manning books explain per-channel quantization?
Quantization and Fast Inference and CUDA for LLMs.
What should I know before learning per-channel quantization?
Manning books that teach per-channel quantization usually introduce activation, accuracy, channel dimension and float16 first.
What is the difference between per-channel quantization and per-tensor quantization?
Per-channel quantization assigns separate quantization parameters, such as scales, to individual channels along a tensor axis. Per-tensor quantization applies a shared set of quantization parameters, such as scale and zero point, to all values in a tensor.
What is per-channel quantization a kind of?
Per-channel quantization is a kind of quantization. Model quantization represents model parameters or computations with reduced-precision numerical values, often to lower storage or computational requirements.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

