Commit
·
511693e
1
Parent(s):
6028db4
Update main.py
Browse files
main.py
CHANGED
@@ -22,14 +22,14 @@ class InputFeatures(BaseModel):
|
|
22 |
# bd2: float
|
23 |
# age: int
|
24 |
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
|
34 |
# Load the pickled XGBoost model
|
35 |
model_input = joblib.load("model_1.joblib")
|
@@ -39,9 +39,9 @@ model_input = joblib.load("model_1.joblib")
|
|
39 |
async def predict(input:model_input):
|
40 |
#Numeric Features
|
41 |
|
42 |
-
num_features = [['
|
43 |
-
'
|
44 |
-
'
|
45 |
|
46 |
XGB= Pipeline([
|
47 |
("col_trans", full_pipeline),
|
|
|
22 |
# bd2: float
|
23 |
# age: int
|
24 |
|
25 |
+
Plasma_glucose: float
|
26 |
+
Blood_Work_Result_1:float
|
27 |
+
Blood_Pressure :float
|
28 |
+
Blood_Work_Result_2:float
|
29 |
+
Blood_Work_Result_3:float
|
30 |
+
Body_mass_index :float
|
31 |
+
Blood_Work_Result_4:float
|
32 |
+
patients_age :int
|
33 |
|
34 |
# Load the pickled XGBoost model
|
35 |
model_input = joblib.load("model_1.joblib")
|
|
|
39 |
async def predict(input:model_input):
|
40 |
#Numeric Features
|
41 |
|
42 |
+
num_features = [['Plasma_glucose','Blood_Work_Result_1','Blood_Pressure',
|
43 |
+
'Blood_Work_Result_2',' Blood_Work_Result_3', 'Body_mass_index',
|
44 |
+
'Blood_Work_Result_4', 'Age']]
|
45 |
|
46 |
XGB= Pipeline([
|
47 |
("col_trans", full_pipeline),
|