ankandrew
commited on
Commit
·
4ed6c98
1
Parent(s):
d35308a
Handle correctly multiple images
Browse files
app.py
CHANGED
@@ -48,7 +48,8 @@ def run_inference(model_key, input_type, text, image, video, fps, system_prompt,
|
|
48 |
# Multimodal inference (image or video)
|
49 |
content = []
|
50 |
if input_type == "image" and image:
|
51 |
-
|
|
|
52 |
elif input_type == "video" and video:
|
53 |
# Ensure file URI for local files
|
54 |
video_src = video if str(video).startswith("file://") else f"file://{video}"
|
|
|
48 |
# Multimodal inference (image or video)
|
49 |
content = []
|
50 |
if input_type == "image" and image:
|
51 |
+
for img_path in image:
|
52 |
+
content.append({"type": "image", "image": img_path})
|
53 |
elif input_type == "video" and video:
|
54 |
# Ensure file URI for local files
|
55 |
video_src = video if str(video).startswith("file://") else f"file://{video}"
|