sitammeur commited on
Commit
6d2edfa
1 Parent(s): 1a859c1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -5
app.py CHANGED
@@ -1,6 +1,5 @@
1
  # Importing the requirements
2
  # import warnings
3
-
4
  # warnings.filterwarnings("ignore")
5
 
6
  import gradio as gr
@@ -9,10 +8,10 @@ from src.model import describe_video
9
 
10
  # Video and text inputs for the interface
11
  video = gr.Video(label="Video")
12
- query = gr.Textbox(label="Query", placeholder="Type your query here")
13
 
14
  # Output for the interface
15
- response = gr.Textbox(label="Response", show_label=True, show_copy_button=True)
16
 
17
  # Examples for the interface
18
  examples = [
@@ -29,8 +28,8 @@ examples = [
29
 
30
  # Title, description, and article for the interface
31
  title = "Video Understanding & Question Answering"
32
- description = "This Gradio demo uses the MiniCPM-V-2_6 model for video understanding tasks. Upload a video and type a question to get a detailed description or specific information from the video."
33
- article = "<p style='text-align: center'><a href='https://arxiv.org/abs/2407.03320' target='_blank'>InternLM-XComposer-2.5: A Versatile Large Vision Language Model Supporting Long-Contextual Input and Output</a> | <a href='https://huggingface.co/internlm/internlm-xcomposer2d5-7b' target='_blank'>Model Page</a></p>"
34
 
35
 
36
  # Launch the interface
 
1
  # Importing the requirements
2
  # import warnings
 
3
  # warnings.filterwarnings("ignore")
4
 
5
  import gradio as gr
 
8
 
9
  # Video and text inputs for the interface
10
  video = gr.Video(label="Video")
11
+ query = gr.Textbox(label="Question", placeholder="Enter your question here")
12
 
13
  # Output for the interface
14
+ response = gr.Textbox(label="Predicted answer", show_label=True, show_copy_button=True)
15
 
16
  # Examples for the interface
17
  examples = [
 
28
 
29
  # Title, description, and article for the interface
30
  title = "Video Understanding & Question Answering"
31
+ description = "This Gradio demo uses the MiniCPM-V-2_6 model for video understanding tasks. To use it, simply upload your video and type a question and click 'submit', or click one of the examples to load them. Read more at the links below."
32
+ article = "<p style='text-align: center'><a href='https://github.com/OpenBMB/MiniCPM-V' target='_blank'>Model GitHub Repo</a> | <a href='https://huggingface.co/openbmb/MiniCPM-V-2_6' target='_blank'>Model Page</a></p>"
33
 
34
 
35
  # Launch the interface