Hugo Lindgren commited on
Commit
a8fd4ee
·
1 Parent(s): 4d227a9
Files changed (2) hide show
  1. app.py +2 -2
  2. tmp.py +0 -0
app.py CHANGED
@@ -7,13 +7,13 @@ import pandas as pd
7
  import datetime
8
  import os
9
 
10
- year = datetime.date.today().year
11
 
12
  project = hopsworks.login()
13
  fs = project.get_feature_store()
14
  mr = project.get_model_registry()
15
  model_url = f"valuation_model_v{year-1}_{year}"
16
- model = mr.get_model(model_url, version=1)
17
  model_dir = model.download()
18
  model = joblib.load(f"{model_dir}/valuation_model.pkl")
19
  scaler = joblib.load(f"{model_dir}/scaler.pkl")
 
7
  import datetime
8
  import os
9
 
10
+ year = datetime.date.today().year - 1
11
 
12
  project = hopsworks.login()
13
  fs = project.get_feature_store()
14
  mr = project.get_model_registry()
15
  model_url = f"valuation_model_v{year-1}_{year}"
16
+ model = mr.get_model(model_url)
17
  model_dir = model.download()
18
  model = joblib.load(f"{model_dir}/valuation_model.pkl")
19
  scaler = joblib.load(f"{model_dir}/scaler.pkl")
tmp.py ADDED
File without changes