Skip to content

Commit 2ae2994

Browse files
authored
[xpu][test] Skip WIP cases in test/quantization/test_qat.py for intel XPU (#3444)
* skip test WIP on xpu * skip test WIP on xpu * skip test WIP on xpu * skip test WIP on xpu
1 parent f99105a commit 2ae2994

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

test/quantization/test_qat.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@
9696
get_groupwise_affine_qparams,
9797
groupwise_affine_quantize_tensor,
9898
)
99+
from torchao.testing.utils import skip_if_xpu
99100
from torchao.utils import (
100101
_is_fbgemm_gpu_genai_available,
101102
get_current_accelerator_device,
@@ -695,10 +696,7 @@ def test_qat_4w_quantizer_gradients(self):
695696
self._test_qat_quantized_gradients(quantizer)
696697

697698
@unittest.skipIf(_DEVICE is None, "skipping when GPU is not available")
698-
@unittest.skipIf(
699-
_DEVICE is torch.device("xpu"),
700-
"skipped due to https://github.com/intel/torch-xpu-ops/issues/1770",
701-
)
699+
@skip_if_xpu("skipped due to https://github.com/intel/torch-xpu-ops/issues/1770")
702700
def test_qat_4w_quantizer(self):
703701
from torchao.quantization.GPTQ import Int4WeightOnlyQuantizer
704702
from torchao.quantization.qat import Int4WeightOnlyQATQuantizer
@@ -2015,6 +2013,7 @@ def test_quantize_api_int8_intx(self, weight_dtype, weight_granularity, dtype):
20152013
)
20162014

20172015
@unittest.skipIf(_DEVICE is None, "skipping when GPU is not available")
2016+
@skip_if_xpu("XPU enablement in progress")
20182017
@parametrize(
20192018
"weight_dtype, granularity, dtype, module_type",
20202019
[

0 commit comments

Comments
 (0)