wuhp commited on
Commit
7838f2e
·
verified ·
1 Parent(s): 892ea03

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -3
app.py CHANGED
@@ -141,9 +141,24 @@ with gr.Blocks() as app:
141
  api_input = gr.Textbox(label="Roboflow API Key", type="password")
142
  url_input = gr.Textbox(label="Roboflow Dataset URL (Segmentation)")
143
  run_btn = gr.Button("Convert")
144
- before_gallery = gr.Gallery(label="Before (Segmentation)").style(grid=[5], height="auto")
145
- after_gallery = gr.Gallery(label="After (Bounding Boxes)").style(grid=[5], height="auto")
146
- run_btn.click(convert_seg_to_bbox, inputs=[api_input, url_input], outputs=[before_gallery, after_gallery])
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
147
 
148
  if __name__ == "__main__":
149
  app.launch()
 
141
  api_input = gr.Textbox(label="Roboflow API Key", type="password")
142
  url_input = gr.Textbox(label="Roboflow Dataset URL (Segmentation)")
143
  run_btn = gr.Button("Convert")
144
+
145
+ before_gallery = gr.Gallery(
146
+ label="Before (Segmentation)",
147
+ columns=5,
148
+ height="auto"
149
+ )
150
+
151
+ after_gallery = gr.Gallery(
152
+ label="After (Bounding Boxes)",
153
+ columns=5,
154
+ height="auto"
155
+ )
156
+
157
+ run_btn.click(
158
+ convert_seg_to_bbox,
159
+ inputs=[api_input, url_input],
160
+ outputs=[before_gallery, after_gallery]
161
+ )
162
 
163
  if __name__ == "__main__":
164
  app.launch()