jeraldhan92 commited on
Commit
d47e854
·
1 Parent(s): a210aea

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -8
app.py CHANGED
@@ -13,11 +13,10 @@ def predict(img):
13
  pred,pred_idx,probs = learn.predict(img)
14
  return {labels[i]: float(probs[i]) for i in range(len(labels))}
15
 
16
- title = "Pet Breed Classifier"
17
- description = "A pet breed classifier trained on the Oxford Pets dataset with fastai. Created as a demo for Gradio and HuggingFace Spaces."
18
- article="<p style='text-align: center'><a href='https://tmabraham.github.io/blog/gradio_hf_spaces_tutorial' target='_blank'>Blog post</a></p>"
19
- examples = ['siamese.jpg']
20
- interpretation='default'
21
- enable_queue=True
22
-
23
- gr.Interface(fn=predict, inputs=gr.Image(height = 512, width = 512), outputs=gr.Label(num_top_classes=3)).launch(share=True)
 
13
  pred,pred_idx,probs = learn.predict(img)
14
  return {labels[i]: float(probs[i]) for i in range(len(labels))}
15
 
16
+ gr.Interface(fn=predict, inputs=gr.Image(height = 512, width = 512), outputs=gr.Label(num_top_classes=3),
17
+ title = "Pet Breed Classifier",
18
+ description = "A pet breed classifier trained on the Oxford Pets dataset with fastai. Created as a demo for Gradio and HuggingFace Spaces.",
19
+ article="<p style='text-align: center'><a href='https://tmabraham.github.io/blog/gradio_hf_spaces_tutorial' target='_blank'>Blog post</a></p>",
20
+ examples = ['siamese.jpg'],
21
+ queue=True
22
+ ).launch(share=True)