File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
vllm/model_executor/models Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -375,7 +375,7 @@ def input_mapper_for_minicpmv(ctx: InputContext, data: object):
375375 raise RuntimeError ("No HuggingFace processor is available "
376376 "to process the image object" )
377377
378- if not isinstance (data , list ) or len ( data ) <= 0 :
378+ if not isinstance (data , list ):
379379 raise ValueError ("Invalid image input (%s)" , data )
380380
381381 try :
@@ -386,7 +386,7 @@ def input_mapper_for_minicpmv(ctx: InputContext, data: object):
386386 logger .error ("Failed to process image (%s)" , data )
387387 raise
388388
389- if "image_bounds" in data [0 ]:
389+ if len ( data ) > 0 and "image_bounds" in data [0 ]:
390390 batch_data ["image_bounds" ] = data [0 ]["image_bounds" ]
391391
392392 return MultiModalInputs (batch_data )
You can’t perform that action at this time.
0 commit comments