Expand description
2026-09-25: FP8-to-BF16 dequantization, dtype-dispatching dense loads, and the compressed-tensors NVFP4 loader.
Owner: model-layers (weight loading). Invariants: none beyond the types.
Functions§
- dense_
auto - 2026-09-25: Load
nameas a BF16DenseWeight, converting by dtype: - dequant_
fp8_ blockscaled_ to_ bf16 - 2026-09-25: Dequantize a block-scaled FP8 E4M3 weight
{prefix}.weight[N, K]into a new BF16 device buffer:bf16[i,j] = fp8[i,j] * scale[i/block_n, j/block_k], with the block sizes inferred from the scale’s shape. - quantized_
v2 - 2026-09-25: Build a
QuantizedWeightfrom compressed-tensors NVFP4 keys:weight_packed,weight_scale,weight_global_scaleand an optionalinput_global_scale. compressed-tensors stores the global scale as the reciprocal ofweight_scale_2, soweight_scale_2 = 1 / weight_global_scale.