pub fn validate_weight_buffer(
weight_name: &str,
ggml_type: u32,
actual_bytes: usize,
rows: usize,
cols: usize,
) -> Result<(), WeightBufferError>Expand description
Validate a weight buffer against a known GGML type ID.
This is the primary entry point for realizar and aprender to validate quantized weight buffers before passing them to trueno kernels.
§Arguments
weight_name- Human-readable name (for error messages)ggml_type- GGML quantization type IDactual_bytes- Actual buffer size in bytesrows- Number of rows (out_dim for GEMV)cols- Number of columns (in_dim for GEMV)
§Errors
Returns WeightBufferError if:
- The GGML type ID is unknown
- The buffer size doesn’t match expected dimensions