From 649b0f763ae4f77f55fa0af99ef9b6843b68b49a Mon Sep 17 00:00:00 2001 From: tzhouam Date: Sat, 3 Oct 2026 22:29:17 +0800 Subject: [PATCH] Fit weekly serving fixtures to assigned GPUs and initialize accuracy groups Signed-off-by: tzhouam --- .../test_invalid_omni_chat.py | 4 +-- tests/e2e/accuracy/sana_video/conftest.py | 26 +++++++++++++++++++ .../sana_video/test_sana_video_golden.py | 1 + .../test_sana_video_pipeline_alignment.py | 1 + .../test_flux_kontext_expansion.py | 3 ++- .../online_serving/test_moss_tts_expansion.py | 9 +++++-- 6 files changed, 39 insertions(+), 5 deletions(-) create mode 100644 tests/e2e/accuracy/sana_video/conftest.py diff --git a/tests/dfx/reliability/invalid_param_test/test_invalid_omni_chat.py b/tests/dfx/reliability/invalid_param_test/test_invalid_omni_chat.py index a6d5fd342..22a7de1df 100644 --- a/tests/dfx/reliability/invalid_param_test/test_invalid_omni_chat.py +++ b/tests/dfx/reliability/invalid_param_test/test_invalid_omni_chat.py @@ -216,7 +216,7 @@ def test_video_chat_stream_invalid_requests( # WS /v1/realtime # ───────────────────────────────────────────────────────────────────────────── -# Resolved in ``test_realtime_invalid_requests`` (skip ``session.created`` handshake). +# Resolved in ``test_realtime_invalid_requests`` after the initial handshake. _REALTIME_WS_MODEL_MISMATCH = object() _REALTIME_WS_INVALID_AUDIO_APPEND = object() @@ -286,7 +286,7 @@ def test_realtime_invalid_requests( "send_frames": send_frames, "timeout": 120, "ws_max_size": None, - "ws_skip_types": ["session.created"], + "ws_skip_types": ["session.created", "conversation.created"], "ws_json_type": "error", "ws_error_code": ws_error_code, "err_message": err_message, diff --git a/tests/e2e/accuracy/sana_video/conftest.py b/tests/e2e/accuracy/sana_video/conftest.py new file mode 100644 index 000000000..427dae468 --- /dev/null +++ b/tests/e2e/accuracy/sana_video/conftest.py @@ -0,0 +1,26 @@ +# SPDX-License-Identifier: Apache-2.0 +# SPDX-FileCopyrightText: Copyright contributors to the vLLM-Omni project + +import pytest + + +@pytest.fixture +def sana_model_parallel(tmp_path): + """Construct native parallel layers with real single-rank GPU groups.""" + from vllm_omni.diffusion.distributed.parallel_state import ( + destroy_distributed_env, + init_distributed_environment, + initialize_model_parallel, + ) + + init_distributed_environment( + world_size=1, + rank=0, + local_rank=0, + distributed_init_method=f"file://{tmp_path / 'sana-distributed'}", + ) + try: + initialize_model_parallel() + yield + finally: + destroy_distributed_env() diff --git a/tests/e2e/accuracy/sana_video/test_sana_video_golden.py b/tests/e2e/accuracy/sana_video/test_sana_video_golden.py index cb6ffe6c9..87c91d093 100644 --- a/tests/e2e/accuracy/sana_video/test_sana_video_golden.py +++ b/tests/e2e/accuracy/sana_video/test_sana_video_golden.py @@ -202,6 +202,7 @@ def test_sana_video_transformer_matches_frozen_golden( variant: str, _hardware, accuracy_artifact_root: Path, + sana_model_parallel, ) -> None: del _hardware from vllm.config import LoadConfig diff --git a/tests/e2e/accuracy/sana_video/test_sana_video_pipeline_alignment.py b/tests/e2e/accuracy/sana_video/test_sana_video_pipeline_alignment.py index aabe166d2..787114529 100644 --- a/tests/e2e/accuracy/sana_video/test_sana_video_pipeline_alignment.py +++ b/tests/e2e/accuracy/sana_video/test_sana_video_pipeline_alignment.py @@ -189,6 +189,7 @@ def _cfg_prediction( def test_sana_video_quick_pipeline_stages_match_diffusers( variant: str, _hardware, + sana_model_parallel, ) -> None: """Compare the first denoising step without replacing native attention. diff --git a/tests/e2e/online_serving/test_flux_kontext_expansion.py b/tests/e2e/online_serving/test_flux_kontext_expansion.py index 79460c631..b7a360a40 100644 --- a/tests/e2e/online_serving/test_flux_kontext_expansion.py +++ b/tests/e2e/online_serving/test_flux_kontext_expansion.py @@ -23,7 +23,8 @@ BASE_FEATURE_MARKS = hardware_marks(res={"cuda": "L4"}) def _get_diffusion_feature_cases(model: str): return [ pytest.param( - OmniServerParams(model=model), + # The unsharded transformer alone exceeds the L4's 22 GiB. + OmniServerParams(model=model, server_args=["--enable-cpu-offload"]), id="base", marks=BASE_FEATURE_MARKS, ), diff --git a/tests/e2e/online_serving/test_moss_tts_expansion.py b/tests/e2e/online_serving/test_moss_tts_expansion.py index bd38a7fc7..9b6bb5566 100644 --- a/tests/e2e/online_serving/test_moss_tts_expansion.py +++ b/tests/e2e/online_serving/test_moss_tts_expansion.py @@ -28,7 +28,7 @@ import pytest from tests.helpers.mark import hardware_test from tests.helpers.runtime import OmniServerParams -from tests.helpers.stage_config import get_deploy_config_path +from tests.helpers.stage_config import get_deploy_config_path, modify_stage_config pytestmark = [ pytest.mark.advanced_model, @@ -84,7 +84,12 @@ tts_server_params = [ pytest.param( OmniServerParams( model=MODEL, - stage_config_path=get_deploy_config_path("moss_tts_realtime.yaml"), + stage_config_path=modify_stage_config( + get_deploy_config_path("moss_tts_realtime.yaml"), + # Leave room on the single L4 for the codec weights, reference + # encoder, and speech-serving activations in addition to KV. + updates={"stages": {0: {"gpu_memory_utilization": 0.45}}}, + ), server_args=["--disable-log-stats"], ), id="moss_tts_realtime",