Spaces:
Sleeping
Sleeping
jaifar530
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -274,9 +274,18 @@ if press_me_button:
|
|
274 |
file_prefix = 'not_trancated_full_paragraph.xlsx'
|
275 |
|
276 |
# Load the models and vectorizer
|
277 |
-
ridge_model = pickle.load(f"{file_prefix}_ridge_model.pkl")
|
278 |
-
extra_trees_model = pickle.load(f"{file_prefix}_extra_trees_model.pkl")
|
279 |
-
vectorizer = pickle.load(f"{file_prefix}_vectorizer.pkl")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
280 |
# Transform the input
|
281 |
user_input_transformed = vectorizer.transform(new_text)
|
282 |
|
|
|
274 |
file_prefix = 'not_trancated_full_paragraph.xlsx'
|
275 |
|
276 |
# Load the models and vectorizer
|
277 |
+
# ridge_model = pickle.load(f"{file_prefix}_ridge_model.pkl")
|
278 |
+
# extra_trees_model = pickle.load(f"{file_prefix}_extra_trees_model.pkl")
|
279 |
+
# vectorizer = pickle.load(f"{file_prefix}_vectorizer.pkl")
|
280 |
+
with open(f"{file_prefix}_ridge_model.pkl", 'rb') as file:
|
281 |
+
ridge_model = pickle.load(file)
|
282 |
+
|
283 |
+
with open(f"{file_prefix}_extra_trees_model.pkl", 'rb') as file:
|
284 |
+
extra_trees_model = pickle.load(file)
|
285 |
+
|
286 |
+
with open(f"{file_prefix}_vectorizer.pkl", 'rb') as file:
|
287 |
+
vectorizer = pickle.load(file)
|
288 |
+
|
289 |
# Transform the input
|
290 |
user_input_transformed = vectorizer.transform(new_text)
|
291 |
|