Spaces:
Sleeping
Sleeping
Upload app.py with huggingface_hub
Browse files
app.py
CHANGED
|
@@ -145,6 +145,8 @@ def create_interface():
|
|
| 145 |
|
| 146 |
**Supported Food Types:** Apple Pie, Caesar Salad, Chocolate Cake, Cup Cakes, Donuts,
|
| 147 |
Hamburger, Ice Cream, Pancakes, Pizza, Waffles
|
|
|
|
|
|
|
| 148 |
""")
|
| 149 |
|
| 150 |
with gr.Row():
|
|
@@ -243,9 +245,9 @@ class HealthResponse(BaseModel):
|
|
| 243 |
model_info: Optional[dict] = None
|
| 244 |
|
| 245 |
# FastAPI routes
|
| 246 |
-
@app.get("/")
|
| 247 |
-
async def
|
| 248 |
-
"""
|
| 249 |
return {
|
| 250 |
"message": "Food Recognition API",
|
| 251 |
"version": "1.0.0",
|
|
|
|
| 145 |
|
| 146 |
**Supported Food Types:** Apple Pie, Caesar Salad, Chocolate Cake, Cup Cakes, Donuts,
|
| 147 |
Hamburger, Ice Cream, Pancakes, Pizza, Waffles
|
| 148 |
+
|
| 149 |
+
**How to use:** Simply drag and drop an image or click to upload, then click "Predict Food"!
|
| 150 |
""")
|
| 151 |
|
| 152 |
with gr.Row():
|
|
|
|
| 245 |
model_info: Optional[dict] = None
|
| 246 |
|
| 247 |
# FastAPI routes
|
| 248 |
+
@app.get("/api")
|
| 249 |
+
async def api_info():
|
| 250 |
+
"""API information endpoint"""
|
| 251 |
return {
|
| 252 |
"message": "Food Recognition API",
|
| 253 |
"version": "1.0.0",
|