[Bugfix] Count unsplit Idefics3 image patches (#48760)

Signed-off-by: nightcityblade <nightcityblade@gmail.com>
Co-authored-by: nightcityblade <nightcityblade@gmail.com>
Co-authored-by: Cyrus Leung <tlleungac@connect.ust.hk>
This commit is contained in:
nightcityblade
2026-09-24 11:36:26 -07:00
committed by GitHub
co-authored by nightcityblade Cyrus Leung
parent 8b84e15066
commit 5b3f280a6d
2 changed files with 10 additions and 1 deletions
+1 -1
View File
@@ -137,7 +137,7 @@ class Idefics3ProcessingInfo(BaseProcessingInfo):
mm_kwargs=mm_kwargs,
)
return num_patches
return max(num_patches, 1)
def _get_image_token(self, processor: Idefics3Processor) -> tuple[str, str, str]:
image_token = processor.image_token