(self, quantization_config)
| 43 | class FP_Quantize(Quantizer): |
| 44 | |
| 45 | def __init__(self, quantization_config) -> None: |
| 46 | global fp_quant_module |
| 47 | super().__init__(group_size=quantization_config.group_size) |
| 48 | if fp_quant_module is None: |
| 49 | fp_quant_module = FPQuantizerBuilder().load() |
| 50 | self.cuda_impl = getattr(fp_quant_module, "CUDA_IMPL", True) |
| 51 | self.q_config = quantization_config |
| 52 | |
| 53 | self.orig_dtype = None |
| 54 | self.num_groups = None |
| 55 | self.input_q = None |
| 56 | self.scale = None |
| 57 | |
| 58 | def _validate_shape(self, input): |
| 59 | if self.group_size <= 0: |
nothing calls this directly
no test coverage detected