diff --git a/hunga_bunga/classification.py b/hunga_bunga/classification.py index 7871f36..5fd3603 100644 --- a/hunga_bunga/classification.py +++ b/hunga_bunga/classification.py @@ -24,9 +24,10 @@ from sklearn.base import ClassifierMixin from sklearn.base import RegressorMixin from sklearn.base import is_classifier +from sklearn.ensemble import GradientBoostingClassifier -from core import * -from params import * +from hunga_bunga.core import * +from hunga_bunga.params import * linear_models_n_params = [ @@ -157,7 +158,11 @@ (ExtraTreesClassifier, {'n_estimators': n_estimators, 'max_features': max_features, 'max_depth': max_depth, 'min_samples_split': min_samples_split, 'min_samples_leaf': min_samples_leaf, 'min_impurity_split': min_impurity_split, 'warm_start': warm_start, - 'criterion': ['gini', 'entropy']}) + 'criterion': ['gini', 'entropy']}), + + (GradientBoostingClassifier, + {'n_estimators': n_estimators, 'max_features': max_features, 'max_depth': max_depth, 'min_samples_split': min_samples_split, + 'min_samples_leaf': min_samples_leaf, 'min_impurity_split': min_impurity_split, 'warm_start': warm_start}) ] tree_models_n_params_small = [ @@ -171,6 +176,10 @@ }), (ExtraTreesClassifier, + {'n_estimators_small': n_estimators_small, 'max_features_small': max_features_small, 'max_depth_small': max_depth_small, + 'min_samples_split': min_samples_split, 'min_samples_leaf': min_samples_leaf}), + + (GradientBoostingClassifier, {'n_estimators_small': n_estimators_small, 'max_features_small': max_features_small, 'max_depth_small': max_depth_small, 'min_samples_split': min_samples_split, 'min_samples_leaf': min_samples_leaf}) ] diff --git a/hunga_bunga/regression.py b/hunga_bunga/regression.py index 0a9967a..af73510 100644 --- a/hunga_bunga/regression.py +++ b/hunga_bunga/regression.py @@ -19,10 +19,10 @@ from sklearn.gaussian_process.kernels import RBF, ConstantKernel, DotProduct, WhiteKernel from sklearn.ensemble import AdaBoostRegressor, ExtraTreesRegressor, RandomForestRegressor from sklearn.linear_model import LinearRegression, Ridge, Lasso, ElasticNet, Lars, LassoLars, OrthogonalMatchingPursuit, BayesianRidge, ARDRegression, SGDRegressor, PassiveAggressiveRegressor, RANSACRegressor, HuberRegressor +from sklearn.ensemble import GradientBoostingRegressor - -from core import * -from params import * +from hunga_bunga.core import * +from hunga_bunga.params import * linear_models_n_params = [ @@ -271,6 +271,10 @@ {'n_estimators': n_estimators, 'max_features': max_features, 'max_depth': max_depth, 'min_samples_split': min_samples_split, 'min_samples_leaf': min_samples_leaf, 'min_impurity_split': min_impurity_split, 'warm_start': warm_start, 'criterion': ['mse', 'mae']}), + + (GradientBoostingRegressor, + {'n_estimators': n_estimators, 'max_features': max_features, 'max_depth': max_depth, 'min_samples_split': min_samples_split, + 'min_samples_leaf': min_samples_leaf, 'min_impurity_split': min_impurity_split, 'warm_start': warm_start}), ] @@ -282,7 +286,11 @@ (ExtraTreesRegressor, {'n_estimators': n_estimators_small, 'max_features': max_features_small, 'max_depth': max_depth_small, 'min_samples_split': min_samples_split, 'min_samples_leaf': min_samples_leaf, - 'criterion': ['mse', 'mae']}) + 'criterion': ['mse', 'mae']}), + + (GradientBoostingRegressor, + {'n_estimators': n_estimators_small, 'max_features': max_features_small, 'max_depth': max_depth_small, 'min_samples_split': min_samples_split, + 'min_samples_leaf': min_samples_leaf}) ]