Spaces:
Sleeping
Sleeping
gradio's input/output changed
Browse files
app.py
CHANGED
|
@@ -11,8 +11,8 @@ def classify_image(img):
|
|
| 11 |
pred,idx,probs = learn.predict(img)
|
| 12 |
return dict(zip(categories, map(float,probs)))
|
| 13 |
|
| 14 |
-
image = gr.
|
| 15 |
-
label = gr.
|
| 16 |
examples = ['dog.jpg', 'cat.jpg', 'dunno.jpg']
|
| 17 |
|
| 18 |
intf=gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=examples)
|
|
|
|
| 11 |
pred,idx,probs = learn.predict(img)
|
| 12 |
return dict(zip(categories, map(float,probs)))
|
| 13 |
|
| 14 |
+
image = gr.components.Image(shape=(192,192))
|
| 15 |
+
label = gr.components.Label()
|
| 16 |
examples = ['dog.jpg', 'cat.jpg', 'dunno.jpg']
|
| 17 |
|
| 18 |
intf=gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=examples)
|