de-Rodrigo commited on
Commit
81d0953
Β·
1 Parent(s): d163769

Visual Gradio Improvements

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -18,7 +18,7 @@ logger = logging.getLogger(__name__)
18
 
19
  # Paths to the static image and GIF
20
  README_IMAGE_PATH = os.path.join("figs", "saliencies-merit-dataset.png")
21
- GIF_PATH = os.path.join("figs", "demo_samples.gif")
22
 
23
  # Global variables for Donut model, processor, and dataset
24
  donut_model = None
@@ -134,12 +134,12 @@ if __name__ == "__main__":
134
  with gr.Blocks() as demo:
135
  gr.Markdown("# Saliency Maps with the MERIT Dataset πŸŽ’πŸ“ƒπŸ†")
136
 
137
- gr.Image(value=README_IMAGE_PATH, label="Example Document")
138
 
139
  with gr.Tab("Introduction"):
140
  gr.Markdown(
141
  """
142
- ## Welcome to Saliency Maps with the [MERIT Dataset](https://huggingface.co/datasets/de-Rodrigo/merit)
143
 
144
  This space demonstrates the capabilities of different Vision Language models
145
  for document understanding tasks.
@@ -151,7 +151,7 @@ if __name__ == "__main__":
151
  """
152
  )
153
 
154
- gr.Image(value=GIF_PATH, label="Document Understanding Process")
155
 
156
  with gr.Tab("Try It Yourself"):
157
  gr.Markdown(
 
18
 
19
  # Paths to the static image and GIF
20
  README_IMAGE_PATH = os.path.join("figs", "saliencies-merit-dataset.png")
21
+ GIF_PATH = os.path.join("figs", "demo-samples.gif")
22
 
23
  # Global variables for Donut model, processor, and dataset
24
  donut_model = None
 
134
  with gr.Blocks() as demo:
135
  gr.Markdown("# Saliency Maps with the MERIT Dataset πŸŽ’πŸ“ƒπŸ†")
136
 
137
+ gr.Image(value=README_IMAGE_PATH, width=400, height=300)
138
 
139
  with gr.Tab("Introduction"):
140
  gr.Markdown(
141
  """
142
+ ## Welcome to Saliency Maps with the [MERIT Dataset](https://huggingface.co/datasets/de-Rodrigo/merit πŸŽ’πŸ“ƒπŸ†)
143
 
144
  This space demonstrates the capabilities of different Vision Language models
145
  for document understanding tasks.
 
151
  """
152
  )
153
 
154
+ gr.Image(value=GIF_PATH, label="Dataset samples you can process")
155
 
156
  with gr.Tab("Try It Yourself"):
157
  gr.Markdown(