Spaces:
Running
Running
add examples
Browse files- app.py +1 -1
- examples/image_1.png +0 -0
- examples/image_2.png +0 -0
- examples/image_3.png +0 -0
app.py
CHANGED
@@ -31,7 +31,7 @@ def predict(image):
|
|
31 |
predicted_class_idx = logits.argmax(-1).item()
|
32 |
return(model.config.id2label[predicted_class_idx])
|
33 |
|
34 |
-
demo = gr.Interface(fn=predict, inputs="image", outputs="text", title=title,
|
35 |
description=description,).launch()
|
36 |
|
37 |
# demo.launch(debug=True)
|
|
|
31 |
predicted_class_idx = logits.argmax(-1).item()
|
32 |
return(model.config.id2label[predicted_class_idx])
|
33 |
|
34 |
+
demo = gr.Interface(fn=predict, inputs="image", outputs="text", title=title, examples=["examples/image_1.png", "examples/image_2.png", "examples/image_3.png"],
|
35 |
description=description,).launch()
|
36 |
|
37 |
# demo.launch(debug=True)
|
examples/image_1.png
ADDED
examples/image_2.png
ADDED
examples/image_3.png
ADDED