Spaces:
Running
on
Zero
Running
on
Zero
update app
Browse files
app.py
CHANGED
|
@@ -395,13 +395,13 @@ with gr.Blocks(theme=thistle_theme, css=css) as demo:
|
|
| 395 |
image_query = gr.Textbox(label="Query Input", placeholder="Enter your query here...")
|
| 396 |
image_upload = gr.Image(type="pil", label="Image", height=290)
|
| 397 |
image_submit = gr.Button("Submit", variant="primary")
|
| 398 |
-
gr.Examples(examples=image_examples, inputs=[image_query, image_upload]
|
| 399 |
|
| 400 |
with gr.TabItem("Video Inference"):
|
| 401 |
video_query = gr.Textbox(label="Query Input", placeholder="Enter your query here...")
|
| 402 |
video_upload = gr.Video(label="Video", height=290)
|
| 403 |
video_submit = gr.Button("Submit", variant="primary")
|
| 404 |
-
gr.Examples(examples=video_examples, inputs=[video_query, video_upload]
|
| 405 |
|
| 406 |
with gr.TabItem("PDF Inference"):
|
| 407 |
with gr.Row():
|
|
@@ -415,18 +415,18 @@ with gr.Blocks(theme=thistle_theme, css=css) as demo:
|
|
| 415 |
prev_page_btn = gr.Button("◀ Previous")
|
| 416 |
page_info = gr.HTML('<div style="text-align:center;">No file loaded</div>')
|
| 417 |
next_page_btn = gr.Button("Next ▶")
|
| 418 |
-
gr.Examples(examples=pdf_examples, inputs=[pdf_query, pdf_upload]
|
| 419 |
|
| 420 |
with gr.TabItem("Gif Inference"):
|
| 421 |
gif_query = gr.Textbox(label="Query Input", placeholder="e.g., 'What is happening in this gif?'")
|
| 422 |
gif_upload = gr.Image(type="filepath", label="Upload GIF", height=290)
|
| 423 |
gif_submit = gr.Button("Submit", variant="primary")
|
| 424 |
-
gr.Examples(examples=gif_examples, inputs=[gif_query, gif_upload]
|
| 425 |
|
| 426 |
with gr.TabItem("Caption"):
|
| 427 |
caption_image_upload = gr.Image(type="pil", label="Image to Caption", height=290)
|
| 428 |
caption_submit = gr.Button("Generate Caption", variant="primary")
|
| 429 |
-
gr.Examples(examples=caption_examples, inputs=[caption_image_upload]
|
| 430 |
|
| 431 |
with gr.Accordion("Advanced options", open=False):
|
| 432 |
max_new_tokens = gr.Slider(label="Max new tokens", minimum=1, maximum=MAX_MAX_NEW_TOKENS, step=1, value=DEFAULT_MAX_NEW_TOKENS)
|
|
|
|
| 395 |
image_query = gr.Textbox(label="Query Input", placeholder="Enter your query here...")
|
| 396 |
image_upload = gr.Image(type="pil", label="Image", height=290)
|
| 397 |
image_submit = gr.Button("Submit", variant="primary")
|
| 398 |
+
gr.Examples(examples=image_examples, inputs=[image_query, image_upload])
|
| 399 |
|
| 400 |
with gr.TabItem("Video Inference"):
|
| 401 |
video_query = gr.Textbox(label="Query Input", placeholder="Enter your query here...")
|
| 402 |
video_upload = gr.Video(label="Video", height=290)
|
| 403 |
video_submit = gr.Button("Submit", variant="primary")
|
| 404 |
+
gr.Examples(examples=video_examples, inputs=[video_query, video_upload])
|
| 405 |
|
| 406 |
with gr.TabItem("PDF Inference"):
|
| 407 |
with gr.Row():
|
|
|
|
| 415 |
prev_page_btn = gr.Button("◀ Previous")
|
| 416 |
page_info = gr.HTML('<div style="text-align:center;">No file loaded</div>')
|
| 417 |
next_page_btn = gr.Button("Next ▶")
|
| 418 |
+
gr.Examples(examples=pdf_examples, inputs=[pdf_query, pdf_upload])
|
| 419 |
|
| 420 |
with gr.TabItem("Gif Inference"):
|
| 421 |
gif_query = gr.Textbox(label="Query Input", placeholder="e.g., 'What is happening in this gif?'")
|
| 422 |
gif_upload = gr.Image(type="filepath", label="Upload GIF", height=290)
|
| 423 |
gif_submit = gr.Button("Submit", variant="primary")
|
| 424 |
+
gr.Examples(examples=gif_examples, inputs=[gif_query, gif_upload])
|
| 425 |
|
| 426 |
with gr.TabItem("Caption"):
|
| 427 |
caption_image_upload = gr.Image(type="pil", label="Image to Caption", height=290)
|
| 428 |
caption_submit = gr.Button("Generate Caption", variant="primary")
|
| 429 |
+
gr.Examples(examples=caption_examples, inputs=[caption_image_upload])
|
| 430 |
|
| 431 |
with gr.Accordion("Advanced options", open=False):
|
| 432 |
max_new_tokens = gr.Slider(label="Max new tokens", minimum=1, maximum=MAX_MAX_NEW_TOKENS, step=1, value=DEFAULT_MAX_NEW_TOKENS)
|