Spaces:
Sleeping
Sleeping
Commit
·
e030474
1
Parent(s):
4b6c5b9
Update app.py
Browse files
app.py
CHANGED
@@ -55,12 +55,10 @@ def predict(img) -> Tuple[Dict, float]:
|
|
55 |
### 4. Gradio app ###
|
56 |
|
57 |
# Create title, description and article strings
|
58 |
-
title = "
|
59 |
-
description = "An EfficientNetB2 feature extractor computer vision model to classify images of food into
|
60 |
-
|
61 |
-
|
62 |
-
# Create examples list from "examples/" directory
|
63 |
-
example_list = [["examples/" + example] for example in os.listdir("examples")]
|
64 |
|
65 |
# Create Gradio interface
|
66 |
demo = gr.Interface(
|
@@ -70,10 +68,9 @@ demo = gr.Interface(
|
|
70 |
gr.Label(num_top_classes=5, label="Predictions"),
|
71 |
gr.Number(label="Prediction time (s)"),
|
72 |
],
|
73 |
-
examples=
|
74 |
title=title,
|
75 |
description=description,
|
76 |
-
article=article,
|
77 |
)
|
78 |
|
79 |
# Launch the app!
|
|
|
55 |
### 4. Gradio app ###
|
56 |
|
57 |
# Create title, description and article strings
|
58 |
+
title = "Food Classifier"
|
59 |
+
description = "An EfficientNetB2 feature extractor computer vision model to classify images of food into 101 classes
|
60 |
+
|
61 |
+
burger_example_path = "burger.jpg"
|
|
|
|
|
62 |
|
63 |
# Create Gradio interface
|
64 |
demo = gr.Interface(
|
|
|
68 |
gr.Label(num_top_classes=5, label="Predictions"),
|
69 |
gr.Number(label="Prediction time (s)"),
|
70 |
],
|
71 |
+
examples=[[burger_example_path]],
|
72 |
title=title,
|
73 |
description=description,
|
|
|
74 |
)
|
75 |
|
76 |
# Launch the app!
|