jrahn commited on
Commit
594fd54
·
1 Parent(s): 6a8f5d8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -6,6 +6,7 @@ import os
6
  TOKEN = os.environ["token"]
7
  REPO_ID = "42digital/deepfashion_classification_vit-large-patch14-clip-336"
8
  FILENAME = "model.pkl"
 
9
 
10
  learner = load_learner(
11
  hf_hub_download(repo_id=REPO_ID, filename=FILENAME, token=TOKEN)
@@ -19,5 +20,5 @@ def predict(img):
19
 
20
  gr.Interface(fn=predict,
21
  inputs=gr.Image(type="numpy"),
22
- outputs=gr.Label(num_top_classes=4),
23
- examples=[]).launch()
 
6
  TOKEN = os.environ["token"]
7
  REPO_ID = "42digital/deepfashion_classification_vit-large-patch14-clip-336"
8
  FILENAME = "model.pkl"
9
+ EXAMPLES = ["dress.jpg", "hoodie.jpg", "joggers.jpg", "jumpsuit.jpg", "shorts.jpg", "tee.jpg"]
10
 
11
  learner = load_learner(
12
  hf_hub_download(repo_id=REPO_ID, filename=FILENAME, token=TOKEN)
 
20
 
21
  gr.Interface(fn=predict,
22
  inputs=gr.Image(type="numpy"),
23
+ outputs=gr.Label(num_top_classes=5),
24
+ examples=EXAMPLES).launch()