Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -31,9 +31,9 @@ async def predict(model: UploadFile = File(...), data: str = None):
|
|
31 |
print(data)
|
32 |
# Process the data
|
33 |
predictions = model.predict(ds_normalized.reshape(1, 12, 1)).tolist()
|
34 |
-
predictions_rescaled = scaler.inverse_transform(predictions).flatten()
|
35 |
|
36 |
-
return {"predictions":
|
37 |
|
38 |
except Exception as e:
|
39 |
print(traceback.format_exc())
|
|
|
31 |
print(data)
|
32 |
# Process the data
|
33 |
predictions = model.predict(ds_normalized.reshape(1, 12, 1)).tolist()
|
34 |
+
predictions_rescaled = scaler.inverse_transform(predictions).flatten().tolist()
|
35 |
|
36 |
+
return {"predictions": predictions_rescaled}
|
37 |
|
38 |
except Exception as e:
|
39 |
print(traceback.format_exc())
|