text_plain_output_2.png text_plain_output_1.png
from catboost import CatBoostClassifier, Pool

from sklearn.ensemble import RandomForestClassifier, GradientBoostingClassifier

from sklearn.linear_model import LogisticRegression

from sklearn.neighbors import KNeighborsClassifier

from sklearn.svm import SVC

from sklearn.tree import DecisionTreeClassifier

from xgboost import XGBClassifier

lr = LogisticRegression(C=1, solver='newton-cg', random_state=42)
rf = RandomForestClassifier(n_estimators=50, max_depth=10, random_state=42)
gb = GradientBoostingClassifier(n_estimators=10, learning_rate=0.005, random_state=42)
svm = SVC(C=100, kernel='rbf', random_state=42)
knn = KNeighborsClassifier(weights='uniform', n_neighbors=5, metric='manhattan')
xgb = XGBClassifier(n_estimators=250, max_depth=10, learning_rate=0.0001, random_state=42)
cat = CatBoostClassifier(iterations=50, max_depth=10, learning_rate=0.005, loss_function='MultiClass', eval_metric='MultiClass', random_state=42)
dt = DecisionTreeClassifier(max_features='sqrt', max_depth=5, criterion='gini', ccp_alpha=0.001, random_state=42)

lr.fit(X_train_ex, y_train_ex)
rf.fit(X_train_ex, y_train_ex)
gb.fit(X_train_ex, y_train_ex)
svm.fit(X_train_ex, y_train_ex)
knn.fit(X_train_ex, y_train_ex)
xgb.fit(X_train_ex, y_train_ex)
cat.fit(X_train_ex, y_train_ex)
dt.fit(X_train_ex, y_train_ex)