pytorch/test/quantization
andrewor14 b6e85eb8d5 [quant][pt2] Support quantized conv bias in QAT fusion (#112528)
Summary: Previously QAT fusion assumes bias is not quantized.
This works for the existing XNNPACKQuantizer, but not for custom
quantizers that wish to quantize the bias. This commit supports
this by adding the necessary patterns. This requires refactoring
the code, however, since it previously assumed that there will
only be one pair of q-dq (from conv weight) in the matched
pattern, and this is no longer true.

Test Plan:
python test/test_quantization.py TestQuantizePT2EQAT.test_qat_conv_bn_bias_derived_qspec

Reviewers: jerryzh168, kimishpatel

Subscribers: jerryzh168, kimishpatel, supriyar

Differential Revision: [D50856377](https://our.internmc.facebook.com/intern/diff/D50856377)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/112528
Approved by: https://github.com/jerryzh168
2023-11-06 17:58:57 +00:00
..
ao_migration ao migration: remove package test as this behavior is tested by other things (#94422) 2023-02-13 16:33:40 +00:00
bc [BE] Enable ruff's UP rules and autoformat test/ (#105434) 2023-07-19 20:36:06 +00:00
core [Quant] [PT2] Enable Decomposed quant per tensor/channel to accept bfloat16 input (#112225) 2023-11-03 23:47:43 +00:00
eager [pytorch][ao] Add torch.matmul in FloatFunctional/QFunctional (#106831) 2023-08-10 22:43:36 +00:00
fx Back out "Enable pickling model prepared with QAT qconfig" (#110392) 2023-10-05 14:41:00 +00:00
jit Revert "Remove deprecated fbgemm operators (#104535)" 2023-10-25 16:34:16 +00:00
pt2e [quant][pt2] Support quantized conv bias in QAT fusion (#112528) 2023-11-06 17:58:57 +00:00
serialized [ao] fix incorrect integer cast on histogram observer bounds (#90355) 2022-12-12 20:30:44 +00:00
__init__.py