chitang1 commited on
Commit
94e2dc3
·
verified ·
1 Parent(s): 0542dd2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -16,9 +16,9 @@ LABELS = LEARN.dls.vocab
16
 
17
  def gradio_predict(img):
18
  img = img.resize((512, 512))
19
- img = PILImage.create(img)
20
  _pred, _pred_idx, probs = LEARN.predict(img)
21
- labels_probs = dict(zip(categories, map(float,probs)))
22
  return labels_probs
23
 
24
  # with open('gradio_article.md') as f:
 
16
 
17
  def gradio_predict(img):
18
  img = img.resize((512, 512))
19
+ # img = PILImage.create(img)
20
  _pred, _pred_idx, probs = LEARN.predict(img)
21
+ labels_probs = dict(zip(LABELS, map(float,probs)))
22
  return labels_probs
23
 
24
  # with open('gradio_article.md') as f: