@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 6d0b827cbd
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 14, 05:30 UTC

[V0 Deprecation] Remove V0-only methods in multi-modal registry (#25362)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>

Cyrus Leung committed Sep 22, 2025 at 13:58 UTC 6d0b827cbd0510173f6a9e77549d917828e80c76
2 files changed +1 -32
tests/models/multimodal/generation/test_qwen2_vl.py
-1
@@ -209,7 +209,6 @@ def batch_make_video_embeddings(
209 return visual(pixel_values_on_device,
210 grid_thw=video_grid_thw_on_device).cpu()
211
212 - # V1 Test: this calls a V0 internal.
212 video_embeds = torch.concat(llm.apply_model(get_image_embeds))
213
214 # split into original batches
vllm/multimodal/registry.py
+1 -31
@@ -12,8 +12,7 @@ from vllm.transformers_utils.tokenizer import (AnyTokenizer,
12 cached_tokenizer_from_config)
13 from vllm.utils import ClassRegistry
14
15 -from .cache import (BaseMultiModalProcessorCache,
16 - processor_only_cache_from_config)
15 +from .cache import BaseMultiModalProcessorCache
16 from .processing import BaseMultiModalProcessor, BaseProcessingInfo
17 from .profiling import (BaseDummyInputsBuilder, DummyDecoderData,
18 DummyEncoderData, MultiModalProfiler)
@@ -176,35 +175,6 @@ class MultiModalRegistry:
175 if mm_limits[key] > 0
176 }
177
179 - # TODO: Remove once V0 is gone
180 - def get_max_tokens_by_modality(
181 - self,
182 - model_config: "ModelConfig",
183 - ) -> Mapping[str, int]:
184 - """
185 - Get the maximum number of tokens from each modality
186 - for profiling the memory usage of a model.
187 - """
188 - cache = processor_only_cache_from_config(model_config, self)
189 - mm_limits = self.get_mm_limits_per_prompt(model_config, cache=cache)
190 - max_tokens_per_item = self.get_max_tokens_per_item_by_modality(
191 - model_config,
192 - cache=cache,
193 - )
194 -
195 - return {
196 - key: mm_limits[key] * max_tokens_per_mm_item
197 - for key, max_tokens_per_mm_item in max_tokens_per_item.items()
198 - }
199 -
200 - # TODO: Remove once V0 is gone
201 - def get_max_multimodal_tokens(self, model_config: "ModelConfig") -> int:
202 - """
203 - Get the maximum number of multi-modal tokens
204 - for profiling the memory usage of a model.
205 - """
206 - return sum(self.get_max_tokens_by_modality(model_config).values())
207 -
178 def get_mm_limits_per_prompt(
179 self,
180 model_config: "ModelConfig",