@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / fde60ee775
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, 23:45 UTC

[Model] Fix a check for None but the return value was empty list in Gemma3 MM vision_embeddings (#21479)

Signed-off-by: Hongmin Fan <fanhongmin@google.com>

hfan committed Jul 25, 2025 at 01:46 UTC fde60ee775de6406477d467ab5782f6a70141734
1 file changed +1 -1
vllm/model_executor/models/gemma3_mm.py
+1 -1
@@ -627,7 +627,7 @@ class Gemma3ForConditionalGeneration(nn.Module, SupportsMultiModal, SupportsPP,
627
628 inputs_embeds = self.get_input_embeddings(input_ids,
629 vision_embeddings)
630 - if vision_embeddings is not None:
630 + if (vision_embeddings is not None) and len(vision_embeddings) != 0:
631 kwargs = self.prepare_attn_masks(
632 input_ids,
633 positions,