MCPcopy Create free account
hub / github.com/IST-DASLab/MoE-Quant / find_quantization_meta

Function find_quantization_meta

src/quant_utils.py:75–101  ·  view source on GitHub ↗

Find quantization metadata over dim=-1 x: (..., C), weight bit_width: int symmetric: bool, whether to set qzero to the middle dtype: torch.dtype, target scale dtype, fp16 or bf16

(
    x: torch.Tensor,
    bit_width: int,
    symmetric: bool = False,
    dtype: torch.dtype = None,
)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

get_quantization_gridFunction · 0.85

Calls 1

round_fpFunction · 0.85

Tested by

no test coverage detected