iq_gemm#

Packed GGML projections with bounded tile storage in both autograd directions.

Functions

iq_linear

Apply a native GGML matrix without expanding weights or saving a full dW.

iq_linear(inputs, packed, steps, format_name, weight_shape, bias=None)#

Apply a native GGML matrix without expanding weights or saving a full dW.

steps are differentiable FP32 native fields in row-major block/group order, shaped (prod(weight_shape) // block_size, block_size // int8_group_size). Packed codes remain immutable. Forward and input VJP decode weights again for each 32-token row tile; larger token counts increase decode work.