[misc] fix lora regex (#6944)

* fix lora regex

* fix

Former-commit-id: 1d0ecbaee1b72f1e03154ddd4fcc8b7876e01f89
This commit is contained in:
hoshi-hiyouga
2025-02-14 21:38:43 +08:00
committed by GitHub
parent ed25e051a9
commit a893505924
5 changed files with 32 additions and 31 deletions

View File

@@ -1147,7 +1147,7 @@ class Qwen2vlPlugin(BasePlugin):
mm_inputs = self._get_mm_inputs(images, videos, audios, processor)
fps_per_video = mm_inputs.pop("fps_per_video", [])
image_processor: "BaseImageProcessor" = getattr(processor, "image_processor")
if "second_per_grid_ts" in getattr(image_processor, "model_input_names", []) and fps_per_video:
if "second_per_grid_ts" in processor.model_input_names and fps_per_video:
mm_inputs["second_per_grid_ts"] = [image_processor.temporal_patch_size / fps for fps in fps_per_video]
return mm_inputs