From ca2841a2e4d3d095a4615e2f926d09c567c6ada9 Mon Sep 17 00:00:00 2001 From: Dominik Strzako Date: Sun, 23 May 2021 22:07:14 +0200 Subject: [PATCH] ??? --- Zadanie_09_MLflow_Predict.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Zadanie_09_MLflow_Predict.py b/Zadanie_09_MLflow_Predict.py index 6268c39..8c44897 100644 --- a/Zadanie_09_MLflow_Predict.py +++ b/Zadanie_09_MLflow_Predict.py @@ -1,7 +1,9 @@ import mlflow -import pandas as pd +import sys +import json model = mlflow.keras.load_model("movies_on_streaming_platforms_model") -data = pd.read_json('movies_on_streaming_platforms_model/input_example.json', orient='index') +with open('movies_on_streaming_platforms_model/input_example.json') as json_file: + data = json.load(json_file) print(data) print(model.predict(data)) \ No newline at end of file