fedihch commited on
Commit
0d5174b
1 Parent(s): be2750d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -26,12 +26,14 @@ def classify(input_img):
26
  id2label = {0: "invoice", 1: "receipt"}
27
  return id2label[predicted_class_idx]
28
 
29
-
 
30
  demo = gr.Interface(
31
  fn=classify,
32
  inputs=gr.Image(shape=(200, 200)),
33
  outputs="text",
34
  allow_flagging="manual",
35
  description="Upload an invoice or receipt image and the model will classify it!",
 
36
  )
37
  demo.launch(share=True)
 
26
  id2label = {0: "invoice", 1: "receipt"}
27
  return id2label[predicted_class_idx]
28
 
29
+ examples =[['https://upserve.com/media/sites/2/Bill-from-Mezcalero-in-Washington-D.C.-photo-by-Alfredo-Solis-1-e1507226752437.jpg',
30
+ 'https://templates.invoicehome.com/invoice-template-us-neat-750px.png']]
31
  demo = gr.Interface(
32
  fn=classify,
33
  inputs=gr.Image(shape=(200, 200)),
34
  outputs="text",
35
  allow_flagging="manual",
36
  description="Upload an invoice or receipt image and the model will classify it!",
37
+ examples=examples
38
  )
39
  demo.launch(share=True)