Skip to content

Commit 0197a8f

Browse files
authored
Update Lab041.py
1 parent cfa2e35 commit 0197a8f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

flaskr/Lab041/Lab041.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def index():
1919

2020
@bp41.route('/submit', methods=['post'])
2121
def submit():
22-
model = joblib.load('./Lab04.1/model.pkl') #load the model
22+
model = joblib.load('/home/ailabs/Exploiting-AI/flaskr/Lab041/') #load the model
2323
user_input = pd.DataFrame({'City_Code': request.form.get("City_Code"), 'Income': request.form.get("Income"), 'CreditScore': request.form.get("CreditScore")}, index=[0]) # sample input - inputs should be recieved from user input.
2424
probas = model.predict_proba(user_input) #model predictions are made here.
2525

@@ -32,4 +32,5 @@ def submit():
3232
probas = probas[0][1] * 100
3333
probas = f"{'%.2f'%(probas)}%"
3434

35-
return render_template('index41.html', probas=probas)
35+
36+
return render_template('index41.html', probas=probas)

0 commit comments

Comments
 (0)