powered by
Quantizes a chunk of floating-point data to a lower precision format.
ggml_quantize_chunk(type, src, nrows, n_per_row)
Raw vector containing quantized data
Target GGML type (e.g., GGML_TYPE_Q4_0)
Source numeric vector (F32 data)
Number of rows
Number of elements per row
# \donttest{ # Quantize 256 floats to Q8_0 (block size 32) data <- rnorm(256) quantized <- ggml_quantize_chunk(GGML_TYPE_Q8_0, data, 1, 256) ggml_quantize_free() # Clean up # }
Run the code above in your browser using DataLab