pub fn quantize<M>(
module: M,
group_size: impl Into<Option<i32>>,
bits: impl Into<Option<i32>>,
) -> Result<M::Quantized, M::QuantizationError>where
M: Quantizable,
Expand description
Quantize a module.
ยงParams
module
: The module to quantize.group_size
: The group size to use for the quantized weight. Default toQuantizable::DEFAULT_GROUP_SIZE
bits
: The bit width to use for the quantized weight. Default toQuantizable::DEFAULT_BITS