Guillermo Uribe Vicencio commited on
Commit
bc2c79f
·
1 Parent(s): e03c8f1
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -180,7 +180,7 @@ def process_rgb(input, mask, indexes):
180
 
181
  return rgb
182
 
183
- def inference_on_file(target_image, model, custom_test_pipeline, map_resume):
184
 
185
  target_image = target_image.name
186
  time_taken=-1
@@ -248,10 +248,11 @@ model = init_segmentor(config, ckpt, device='cpu')
248
  custom_test_pipeline=process_test_pipeline(model.cfg.data.test.pipeline, None)
249
 
250
 
251
- func = partial(inference_on_file, model=model, custom_test_pipeline=custom_test_pipeline, map_resume=map_resume)
252
 
 
 
 
253
 
254
- bar_data=map_resume
255
  with gr.Blocks() as demo:
256
  with gr.Row():
257
  gr.Markdown(value='# Eclipse2')
 
180
 
181
  return rgb
182
 
183
+ def inference_on_file(target_image, model, custom_test_pipeline, bar_data):
184
 
185
  target_image = target_image.name
186
  time_taken=-1
 
248
  custom_test_pipeline=process_test_pipeline(model.cfg.data.test.pipeline, None)
249
 
250
 
 
251
 
252
+ func = partial(inference_on_file, model=model, custom_test_pipeline=custom_test_pipeline, bar_data=bar_data)
253
+
254
+ bar_data = pd.DataFrame(map_resume)
255
 
 
256
  with gr.Blocks() as demo:
257
  with gr.Row():
258
  gr.Markdown(value='# Eclipse2')