Spaces:
Runtime error
Runtime error
app version 0.0.3
Browse files
app.py
CHANGED
@@ -66,6 +66,7 @@ def predict(age, female, race, elective, aweekend, zipinc_qrtl, hosp_region, hos
|
|
66 |
.apply(lambda x: x.astype('category'))
|
67 |
|
68 |
# converting ordinal column to ordinal
|
|
|
69 |
df.zipinc_qrtl = df.zipinc_qrtl.astype(ordinal_cat)
|
70 |
|
71 |
# reading the model from GitHub
|
|
|
66 |
.apply(lambda x: x.astype('category'))
|
67 |
|
68 |
# converting ordinal column to ordinal
|
69 |
+
ordinal_cat = CategoricalDtype(categories = ['FirstQ', 'SecondQ', 'ThirdQ', 'FourthQ'], ordered = True)
|
70 |
df.zipinc_qrtl = df.zipinc_qrtl.astype(ordinal_cat)
|
71 |
|
72 |
# reading the model from GitHub
|