Skip to main content

quantize_rows

Function quantize_rows 

Source
pub fn quantize_rows(
    rows: &ArrayView2<'_, f32>,
) -> Result<QuantizedMatrix, EmbeddingError>
Expand description

Quantize each row of rows to int8 with a per-row symmetric scale.

ยงErrors

Returns EmbeddingError::EmptyInput when rows is empty.