[Misc] Don't allow language-model-only used with encoder CG together (#53127)

Signed-off-by: Isotr0py <Isotr0py@outlook.com>
This commit is contained in:
Isotr0py
2026-08-20 17:26:47 +00:00
committed by GitHub
parent ae25628995
commit 00f7f25828
+13
View File
@@ -1147,6 +1147,19 @@ class VllmConfig:
"connectors (PD disaggregation, KV cache offload)."
)
if (
self.model_config is not None
and self.model_config.multimodal_config is not None
and self.model_config.multimodal_config.language_model_only
and self.compilation_config.cudagraph_mm_encoder
):
raise ValueError(
"--language-model-only is incompatible with "
"cudagraph_mm_encoder=True, since it disables all multimodal "
"inputs and the multimodal encoder is never run. Please "
"disable one of them."
)
self._verify_sampling_replay_config()
self._verify_trace_replay_config()