Spaces:
Sleeping
Sleeping
Ilija Eftimov
commited on
Commit
·
022ae0c
1
Parent(s):
c7fc8ea
Fix return type
Browse files
app.py
CHANGED
|
@@ -6,7 +6,6 @@ learn = load_learner("model.pkl")
|
|
| 6 |
labels = learn.dls.vocab
|
| 7 |
def classify_image(img):
|
| 8 |
pred, idx, probs = learn.predict(img)
|
| 9 |
-
return pred
|
| 10 |
return {labels[i]: float(probs[i]) for i in range(len(labels))}
|
| 11 |
|
| 12 |
image = gr.inputs.Image(shape=(192,192))
|
|
|
|
| 6 |
labels = learn.dls.vocab
|
| 7 |
def classify_image(img):
|
| 8 |
pred, idx, probs = learn.predict(img)
|
|
|
|
| 9 |
return {labels[i]: float(probs[i]) for i in range(len(labels))}
|
| 10 |
|
| 11 |
image = gr.inputs.Image(shape=(192,192))
|