Spaces:
Runtime error
Runtime error
Commit
·
f920484
1
Parent(s):
0e40d1e
Implementing Animal Classifier
Browse files
app.py
CHANGED
|
@@ -27,8 +27,8 @@ def classify_image(img):
|
|
| 27 |
return dict(zip(categories, map(float, probs)))
|
| 28 |
|
| 29 |
# cell
|
| 30 |
-
image = gr.components.Image(
|
| 31 |
-
label = gr.components.Label()
|
| 32 |
examples = ['5a094c5a36.jpg', '6c28066ea3.jpg', '6dd3ba7825.jpg', '6f634d9a5f.jpg',
|
| 33 |
'7b04dad848.jpg', '7b9f3d9464.jpg', '7c43d5ca9e.jpg', '7cc3758d67.jpg',
|
| 34 |
'7f995e322c.jpg', '8aefee4c2c.jpg', '0041c9ff2c.jpg']
|
|
|
|
| 27 |
return dict(zip(categories, map(float, probs)))
|
| 28 |
|
| 29 |
# cell
|
| 30 |
+
image = gr.components.Image()
|
| 31 |
+
label = gr.components.Label(num_top_classes=3)
|
| 32 |
examples = ['5a094c5a36.jpg', '6c28066ea3.jpg', '6dd3ba7825.jpg', '6f634d9a5f.jpg',
|
| 33 |
'7b04dad848.jpg', '7b9f3d9464.jpg', '7c43d5ca9e.jpg', '7cc3758d67.jpg',
|
| 34 |
'7f995e322c.jpg', '8aefee4c2c.jpg', '0041c9ff2c.jpg']
|