Stuti commited on
Commit
2221dcc
1 Parent(s): a905593

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -105,15 +105,15 @@ with demo:
105
  img_output_from_upload= gr.Image(shape=(650,650))
106
 
107
  with gr.Row():
108
- example_images = gr.Dataset(components=[img_input],
109
- samples=[[path.as_posix()]
110
- for path in sorted(pathlib.Path('images').rglob('*.jpeg'))])
111
 
112
  img_but = gr.Button('Detect')
113
 
114
 
115
- img_but.click(detect_objects,inputs=[options,img_input,slider_input],outputs=img_output_from_upload,queue=True, examples=examples)
116
- example_images.click(fn=set_example_image,inputs=[example_images],outputs=[img_input], examples=examples)
117
 
118
 
119
  #gr.Markdown("![visitor badge](https://visitor-badge.glitch.me/badge?page_id=nickmuchi-object-detection-with-detr-and-yolos)")
 
105
  img_output_from_upload= gr.Image(shape=(650,650))
106
 
107
  with gr.Row():
108
+ example_images = examples #gr.Dataset(components=[img_input],
109
+ #samples=[[path.as_posix()]
110
+ #for path in sorted(pathlib.Path('images').rglob('*.jpeg'))])
111
 
112
  img_but = gr.Button('Detect')
113
 
114
 
115
+ img_but.click(detect_objects,inputs=[options,img_input,slider_input],outputs=img_output_from_upload,queue=True)
116
+ example_images.click(fn=set_example_image,inputs=example_images,outputs=[img_input])
117
 
118
 
119
  #gr.Markdown("![visitor badge](https://visitor-badge.glitch.me/badge?page_id=nickmuchi-object-detection-with-detr-and-yolos)")