Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -40,14 +40,8 @@ def get_nutrition_info(food_name):
|
|
| 40 |
response = data["branded"][0]["photo"]["thumb"]
|
| 41 |
|
| 42 |
# Open the image using PIL
|
| 43 |
-
|
| 44 |
-
return
|
| 45 |
-
"food_name": data["branded"][0]["food_name"],
|
| 46 |
-
"calories": data["branded"][0]["nf_calories"],
|
| 47 |
-
"serving_size": data["branded"][0]["serving_qty"],
|
| 48 |
-
"serving_unit": data["branded"][0]["serving_unit"],
|
| 49 |
-
#"images": data["branded"][0]["photo"]
|
| 50 |
-
},response
|
| 51 |
|
| 52 |
def volume_estimations(ali):
|
| 53 |
return None
|
|
|
|
| 40 |
response = data["branded"][0]["photo"]["thumb"]
|
| 41 |
|
| 42 |
# Open the image using PIL
|
| 43 |
+
output = json.dumps(response, indent=2, sort_keys=True)
|
| 44 |
+
return output,response
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
|
| 46 |
def volume_estimations(ali):
|
| 47 |
return None
|