Update app.py
Browse files
app.py
CHANGED
|
@@ -48,11 +48,9 @@ def predict_price(year, month, markets, food):
|
|
| 48 |
|
| 49 |
prediction = model.predict(input_data)
|
| 50 |
|
| 51 |
-
food_url = "https://raw.githubusercontent.com/TimiUU/wine/main/" +
|
| 52 |
img = Image.open(requests.get(food_url, stream=True).raw)
|
| 53 |
|
| 54 |
-
# 返回文本和图像对象
|
| 55 |
-
#return f"Prediction: {prediction[0]}", img
|
| 56 |
|
| 57 |
return prediction, img
|
| 58 |
|
|
|
|
| 48 |
|
| 49 |
prediction = model.predict(input_data)
|
| 50 |
|
| 51 |
+
food_url = "https://raw.githubusercontent.com/TimiUU/wine/main/" + food + ".png"
|
| 52 |
img = Image.open(requests.get(food_url, stream=True).raw)
|
| 53 |
|
|
|
|
|
|
|
| 54 |
|
| 55 |
return prediction, img
|
| 56 |
|