Closed ebsrn closed 2 years ago
Thank you.
Hi again, I'm trying to do the inference with quantized weights. For this, I deleted the following line. Is this a correct approach? When I do this, I see that the output of the layer before the classification layer consists entirely of nan values.
@ebsrn Hi,
quant
and dequant
are the standard and necessary steps in quantization and you can't remove any of them.
These steps are introduced in the above-mentioned documents, and Figure 6 of this paper. I hope you could read these articles carefully, in order to enhance the understanding of quantization.
Hi, thank you for sharing the coding.
Could you please explain why you dequantize the values after quantization?
https://github.com/linyang-zhh/FQ-ViT/blob/16122ee7ea33e80aed3edd29cfebb3ab2ce2cb69/models/ptq/quantizer/base.py#L46