pytorch/test/quantization
Xia, Weiwen 3b0cd9b542 [Quant][PT2E] add a lowering pass for x86 backend (#149708)
**Summary**
This PR adds a lowering pass for x86 backend
- Patterns of `dequantize -> conv/linear (-> quantize)` are fused to corresponding quantized onednn ops.
- Weights are prepacked ahead of time.
- Post ops of conv/linear are fused if supported.
- The pass returns a `GraphModule` with the modifications mentioned above.

**Test plan**
```
pytest test/quantization/pt2e/test_x86inductor_quantizer.py -k test_lowering_to_x86
```

Pull Request resolved: https://github.com/pytorch/pytorch/pull/149708
Approved by: https://github.com/jerryzh168, https://github.com/leslie-fang-intel
2025-04-01 17:32:41 +00:00
..
ao_migration PEP585 update - test (#145176) 2025-01-22 04:48:28 +00:00
bc PEP585 update - test (#145176) 2025-01-22 04:48:28 +00:00
core add torch.float4_e2m1fn_x2 to PyTorch (#148791) 2025-03-27 17:32:20 +00:00
eager PEP585 update - test (#145176) 2025-01-22 04:48:28 +00:00
fx Add test coverage (#149182) 2025-03-14 09:38:29 +00:00
jit PEP585 update - test (#145176) 2025-01-22 04:48:28 +00:00
pt2e [Quant][PT2E] add a lowering pass for x86 backend (#149708) 2025-04-01 17:32:41 +00:00
serialized
__init__.py