Miroslav Purkrabek commited on
Commit
6359049
·
1 Parent(s): 46671d4

edit texts and layout

Browse files
app.py CHANGED
@@ -186,46 +186,46 @@ def process_image_with_BMP(
186
 
187
 
188
  with gr.Blocks() as app:
189
- gr.Markdown("# Small Object Detection with SAHI + YOLOv11")
190
  gr.Markdown(
191
- "SAHI + YOLOv11 demo for small object detection. "
192
- "Upload your own image or click an example image to use."
 
 
 
193
  )
194
 
195
  with gr.Row():
196
  with gr.Column():
197
  original_image_input = gr.Image(type="numpy", label="Original Image")
198
- # bbox_thr_slider = gr.Slider(
199
- # minimum=0.0,
200
- # maximum=1.0,
201
- # step=0.01,
202
- # value=0.5,
203
- # label="BBox Confidence Threshold",
204
- # )
205
- # bbox_nms_slider = gr.Slider(
206
- # minimum=0.0,
207
- # maximum=1.0,
208
- # step=0.01,
209
- # value=0.5,
210
- # label="BBox NMS Threshold",
211
- # )
212
- # kpt_conf_slider = gr.Slider(
213
- # minimum=0.0,
214
- # maximum=1.0,
215
- # step=0.01,
216
- # value=0.5,
217
- # label="Keypoint Confidence Threshold",
218
- # )
219
  submit_button = gr.Button("Run Inference")
220
 
221
  with gr.Column():
222
- output_standard = gr.Image(type="numpy", label="RTMDet-L bboxes + masks")
223
 
224
  with gr.Column():
225
- output_sahi_sliced = gr.Image(type="numpy", label="BMP 2x masks + poses")
226
 
227
 
228
  gr.Examples(
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
229
  examples=[
230
  ["examples/prochazka_MMA.jpg"],
231
  ["examples/riner_judo.jpg"],
@@ -233,9 +233,9 @@ with gr.Blocks() as app:
233
  ["examples/tackle1.jpg"],
234
  ["examples/tackle2.jpg"],
235
  ["examples/tackle5.jpg"],
 
236
  ["examples/santa_o_crop.jpg"],
237
  ["examples/floorball_SKV_2.jpg"],
238
- ["examples/floorball_SKV_3.jpg"],
239
  ],
240
  inputs=[
241
  original_image_input,
@@ -244,6 +244,10 @@ with gr.Blocks() as app:
244
  fn=process_image_with_BMP,
245
  cache_examples=True,
246
  )
 
 
 
 
247
 
248
  submit_button.click(
249
  fn=process_image_with_BMP,
 
186
 
187
 
188
  with gr.Blocks() as app:
189
+ gr.Markdown("# BBoxMaskPose Image Demo")
190
  gr.Markdown(
191
+ "Official demo for paper **Detection, Pose Estimation and Segmentation for Multiple Bodies: Closing the Virtuous Circle.** (ICCV 2025)"
192
+ )
193
+ gr.Markdown(
194
+ "For details, see the [project website](https://mirapurkrabek.github.io/BBox-Mask-Pose/) or [arXiv paper](https://arxiv.org/abs/2412.01562)."
195
+ "The demo showcases the capabilities of the BBoxMaskPose framework. If you want to play around with parameters, use the [GitHub demo](https://github.com/MiraPurkrabek/BBoxMaskPose)."
196
  )
197
 
198
  with gr.Row():
199
  with gr.Column():
200
  original_image_input = gr.Image(type="numpy", label="Original Image")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
201
  submit_button = gr.Button("Run Inference")
202
 
203
  with gr.Column():
204
+ output_standard = gr.Image(type="numpy", label="RTMDet-L + MaskPose-B")
205
 
206
  with gr.Column():
207
+ output_sahi_sliced = gr.Image(type="numpy", label="BBoxMaskPose")
208
 
209
 
210
  gr.Examples(
211
+ label="OCHuman examples",
212
+ examples=[
213
+ ["examples/004806.jpg"],
214
+ ["examples/004684.jpg"],
215
+ ["examples/004849.jpg"],
216
+ ["examples/004981.jpg"],
217
+ ["examples/005002.jpg"],
218
+ ["examples/005056.jpg"],
219
+ ],
220
+ inputs=[
221
+ original_image_input,
222
+ ],
223
+ outputs=[output_standard, output_sahi_sliced],
224
+ fn=process_image_with_BMP,
225
+ cache_examples=True,
226
+ )
227
+ gr.Examples(
228
+ label="In-the-wild examples",
229
  examples=[
230
  ["examples/prochazka_MMA.jpg"],
231
  ["examples/riner_judo.jpg"],
 
233
  ["examples/tackle1.jpg"],
234
  ["examples/tackle2.jpg"],
235
  ["examples/tackle5.jpg"],
236
+ ["examples/floorball_SKV_3.jpg"],
237
  ["examples/santa_o_crop.jpg"],
238
  ["examples/floorball_SKV_2.jpg"],
 
239
  ],
240
  inputs=[
241
  original_image_input,
 
244
  fn=process_image_with_BMP,
245
  cache_examples=True,
246
  )
247
+ gr.Markdown(
248
+ "Please note that due to HuggingFace restrictions, the demo runs much slower than the original implementation."
249
+ "For faster inference, use the [GitHub demo](https://github.com/MiraPurkrabek/BBoxMaskPose)."
250
+ )
251
 
252
  submit_button.click(
253
  fn=process_image_with_BMP,
examples/004684.jpg ADDED

Git LFS Details

  • SHA256: 642508dd177a6198746c21927c2e78d6f27db734722afb0c7d193c66de242fc8
  • Pointer size: 131 Bytes
  • Size of remote file: 158 kB
examples/004806.jpg ADDED

Git LFS Details

  • SHA256: 0ea2b4b492c3ecd2186fc978edfd72a4d81537b932fcf8cfd2513cb0932e7e2a
  • Pointer size: 131 Bytes
  • Size of remote file: 177 kB
examples/004849.jpg ADDED

Git LFS Details

  • SHA256: 6483673e0002f1dced7d47311064fd8e32659db41c86073583ff98017cf3387f
  • Pointer size: 131 Bytes
  • Size of remote file: 127 kB
examples/004981.jpg ADDED

Git LFS Details

  • SHA256: 06789bdeff12c80f50fab2e4e818a082f4a7cb7307e0c781875b5cafce04872e
  • Pointer size: 131 Bytes
  • Size of remote file: 216 kB
examples/005002.jpg ADDED

Git LFS Details

  • SHA256: 9b525f89c35c879a17f4c5b45f7b175f0e4fdc3270ac5a65d35e9e273a0654fe
  • Pointer size: 131 Bytes
  • Size of remote file: 144 kB
examples/005056.jpg ADDED

Git LFS Details

  • SHA256: f28895d6bf1a2e3fe9b86b7b042383736f9b68acefe58fb95746c700ba503f8a
  • Pointer size: 131 Bytes
  • Size of remote file: 155 kB