Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -11,6 +11,8 @@ from sklearn.ensemble import GradientBoostingClassifier
|
|
11 |
from sklearn.linear_model import LogisticRegression
|
12 |
from sklearn.metrics import accuracy_score, precision_score, recall_score, f1_score, roc_auc_score, roc_curve
|
13 |
import shap
|
|
|
|
|
14 |
|
15 |
def load_data():
|
16 |
data = pd.read_csv('exported_named_train_good.csv')
|
@@ -26,7 +28,9 @@ def train_models(X_train, y_train, X_test, y_test):
|
|
26 |
"Logistic Regression": LogisticRegression(random_state=42),
|
27 |
"Decision Tree": DecisionTreeClassifier(random_state=42),
|
28 |
"Random Forest": RandomForestClassifier(random_state=42),
|
29 |
-
"Gradient Boost": GradientBoostingClassifier(random_state=42)
|
|
|
|
|
30 |
}
|
31 |
|
32 |
results = {}
|
|
|
11 |
from sklearn.linear_model import LogisticRegression
|
12 |
from sklearn.metrics import accuracy_score, precision_score, recall_score, f1_score, roc_auc_score, roc_curve
|
13 |
import shap
|
14 |
+
from xgboost import XGBClassifier
|
15 |
+
from lightgbm import LGBMClassifier
|
16 |
|
17 |
def load_data():
|
18 |
data = pd.read_csv('exported_named_train_good.csv')
|
|
|
28 |
"Logistic Regression": LogisticRegression(random_state=42),
|
29 |
"Decision Tree": DecisionTreeClassifier(random_state=42),
|
30 |
"Random Forest": RandomForestClassifier(random_state=42),
|
31 |
+
"Gradient Boost": GradientBoostingClassifier(random_state=42),
|
32 |
+
"Extreme Gradient Boosting": XGBClassifier(random_state=42),
|
33 |
+
"Light Gradient Boosting": LGBMClassifier(random_state=42)
|
34 |
}
|
35 |
|
36 |
results = {}
|