|
27 | 27 | from sklearn.feature_selection import VarianceThreshold |
28 | 28 | from sklearn.linear_model import LogisticRegression, SGDClassifier, \ |
29 | 29 | LinearRegression |
| 30 | +from sklearn.neural_network import MLPClassifier |
30 | 31 | from sklearn.ensemble import RandomForestClassifier, BaggingClassifier |
31 | 32 | from sklearn.svm import SVC, LinearSVC |
32 | 33 | from sklearn.model_selection import RandomizedSearchCV, GridSearchCV, \ |
@@ -614,13 +615,13 @@ def test__get_seeded_model_raises(self): |
614 | 615 | self.assertRaises(ValueError, _get_seeded_model, model=clf, seed=42) |
615 | 616 |
|
616 | 617 | def test__extract_arfftrace(self): |
617 | | - param_grid = {"max_depth": [3, None], |
618 | | - "max_features": [1, 2, 3, 4], |
619 | | - "bootstrap": [True, False], |
620 | | - "criterion": ["gini", "entropy"]} |
| 618 | + param_grid = {"hidden_layer_sizes": [(5, 5), (10, 10), (20, 20)], |
| 619 | + "activation" : ['identity', 'logistic', 'tanh', 'relu'], |
| 620 | + "learning_rate_init": [0.1, 0.01, 0.001, 0.0001], |
| 621 | + "max_iter": [10, 20, 40, 80]} |
621 | 622 | num_iters = 10 |
622 | 623 | task = openml.tasks.get_task(20) |
623 | | - clf = RandomizedSearchCV(RandomForestClassifier(), param_grid, num_iters) |
| 624 | + clf = RandomizedSearchCV(MLPClassifier(), param_grid, num_iters) |
624 | 625 | # just run the task |
625 | 626 | train, _ = task.get_train_test_split_indices(0, 0) |
626 | 627 | X, y = task.get_X_and_y() |
|
0 commit comments