ZeroCommand commited on
Commit
8d74e2f
·
1 Parent(s): 0aeb7ce

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -27,7 +27,7 @@ def inference(img, lang):
27
  im = PIL.Image.open(img.name)
28
  draw_boxes(im, bounds)
29
  im.save('result.jpg')
30
- # print(pd.DataFrame(bounds).iloc[: , 1:])
31
  return ['result.jpg', pd.DataFrame(bounds).iloc[: , 1:].to_string(header=False, index=False)]
32
 
33
 
@@ -43,7 +43,7 @@ choices = [
43
  gr.Interface(
44
  inference,
45
  [gr.inputs.Image(type='file', label='Input'),gr.inputs.CheckboxGroup(choices, type="value", default=['en'], label='language')],
46
- [gr.outputs.Image(type='file', label='Output'), gr.outputs.Textbox(type='text')],
47
  title=title,
48
  description=description,
49
  article=article,
 
27
  im = PIL.Image.open(img.name)
28
  draw_boxes(im, bounds)
29
  im.save('result.jpg')
30
+ print(pd.DataFrame(bounds).iloc[: , 1:].to_string)
31
  return ['result.jpg', pd.DataFrame(bounds).iloc[: , 1:].to_string(header=False, index=False)]
32
 
33
 
 
43
  gr.Interface(
44
  inference,
45
  [gr.inputs.Image(type='file', label='Input'),gr.inputs.CheckboxGroup(choices, type="value", default=['en'], label='language')],
46
+ [gr.outputs.Image(type='file', label='Output'), gr.outputs.Textbox(type='str')],
47
  title=title,
48
  description=description,
49
  article=article,