[ROCm][CI] Skip Quark mxfp4 tests unless Quark version is compatible with Torch version (#46431)
Signed-off-by: Micah Williamson <micah.williamson@amd.com>
This commit is contained in:
@@ -13,9 +13,15 @@ from vllm._aiter_ops import is_aiter_found
|
||||
from vllm.platforms import current_platform
|
||||
from vllm.utils.flashinfer import has_flashinfer
|
||||
|
||||
QUARK_MXFP4_AVAILABLE = find_spec("quark") is not None and version.parse(
|
||||
importlib.metadata.version("amd-quark")
|
||||
) >= version.parse("0.8.99")
|
||||
# MXFP4 via quark requires amd-quark >= 0.12 on torch >= 2.11.
|
||||
# Earlier torch releases work with older quark versions. See
|
||||
# https://github.com/amd/Quark/issues/34
|
||||
# TODO: Remove once amd-quark>=0.12.0
|
||||
QUARK_MXFP4_TORCH_COMPATIBLE = find_spec("quark") is not None and (
|
||||
version.parse(importlib.metadata.version("amd-quark")) >= version.parse("0.12.0")
|
||||
if version.parse(torch.__version__.split("+")[0]) >= version.parse("2.11")
|
||||
else True
|
||||
)
|
||||
|
||||
TRTLLM_GEN_MXFP4_AVAILABLE = (
|
||||
current_platform.is_cuda() and current_platform.is_device_capability_family(100)
|
||||
@@ -87,7 +93,10 @@ def enable_pickle(monkeypatch):
|
||||
ModelCase("fxmarty/Llama-3.1-70B-Instruct-2-layers-mxfp6", tp=4),
|
||||
],
|
||||
)
|
||||
@pytest.mark.skipif(not QUARK_MXFP4_AVAILABLE, reason="amd-quark>=0.9 is not available")
|
||||
@pytest.mark.skipif(
|
||||
not QUARK_MXFP4_TORCH_COMPATIBLE,
|
||||
reason="MXFP4 via quark requires amd-quark >= 0.12 on torch >= 2.11.",
|
||||
)
|
||||
def test_mxfp4_loading_and_execution_moe(vllm_runner, model_case: ModelCase):
|
||||
if torch.accelerator.device_count() < model_case.tp:
|
||||
pytest.skip(
|
||||
|
||||
Reference in New Issue
Block a user