wondervictor commited on
Commit
a403dcf
·
verified ·
1 Parent(s): 47db2fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -14
app.py CHANGED
@@ -153,11 +153,18 @@ def run_image(runner,
153
  return image
154
 
155
 
 
 
 
156
  def demo(runner, vision_encoder, vision_processor, padding_embed):
157
  with gr.Blocks(title="YOLO-World") as demo:
158
  with gr.Row():
159
- gr.Markdown('<h1><center>YOLO-World: Real-Time Open-Vocabulary '
160
- 'Object Detector</center></h1>')
 
 
 
 
161
  with gr.Row():
162
  image = gr.Image(type='pil', label='input image')
163
  output_image = gr.Image(type='pil', label='output image')
@@ -215,22 +222,10 @@ def demo(runner, vision_encoder, vision_processor, padding_embed):
215
  exp_image_dir + "1.png", exp_prompt_dir + "1.png", "",
216
  "padding", 0.2, 0.1, 100
217
  ],
218
- [
219
- exp_image_dir + "2.png", exp_prompt_dir + "2.png", "",
220
- "padding", 0.0, 0.1, 200
221
- ],
222
  [
223
  exp_image_dir + "3.png", exp_prompt_dir + "3.png", "",
224
  "padding", 0.3, 0.5, 100
225
  ],
226
- [
227
- exp_image_dir + "4.png", exp_prompt_dir + "4.png", "",
228
- "padding", 0.01, 0.1, 200
229
- ],
230
- [
231
- exp_image_dir + "5.png", exp_prompt_dir + "5.png", "",
232
- "none", 0.3, 0.5, 100
233
- ],
234
  ],
235
  inputs=[
236
  image, prompt_image, input_text, add_padding, score_thr,
 
153
  return image
154
 
155
 
156
+
157
+
158
+
159
  def demo(runner, vision_encoder, vision_processor, padding_embed):
160
  with gr.Blocks(title="YOLO-World") as demo:
161
  with gr.Row():
162
+ gr.Markdown('<h1><center>YOLO-World-Image: YOLO-World with Image Prompts</center></h1>')
163
+ gr.Markdown('<center> This demo is actively under construction and the YOLO-World-Image is an initial version!')
164
+ gr.Markdown("""<center>
165
+ [![project page](https://img.shields.io/badge/Project-Page-green)](https://yoloworld.cc)
166
+ [![arxiv paper](https://img.shields.io/badge/arXiv-Paper-red)](https://arxiv.org/abs/2401.17270)
167
+ [![demo](https://img.shields.io/badge/🤗HugginngFace-Spaces-orange)](https://huggingface.co/spaces/stevengrove/YOLO-World)</center>""")
168
  with gr.Row():
169
  image = gr.Image(type='pil', label='input image')
170
  output_image = gr.Image(type='pil', label='output image')
 
222
  exp_image_dir + "1.png", exp_prompt_dir + "1.png", "",
223
  "padding", 0.2, 0.1, 100
224
  ],
 
 
 
 
225
  [
226
  exp_image_dir + "3.png", exp_prompt_dir + "3.png", "",
227
  "padding", 0.3, 0.5, 100
228
  ],
 
 
 
 
 
 
 
 
229
  ],
230
  inputs=[
231
  image, prompt_image, input_text, add_padding, score_thr,