Skip to content
Snippets Groups Projects
Commit 967742a6 authored by Charly Lamothe's avatar Charly Lamothe
Browse files

Finish to fix sklearn dataset fetchers. Keep 20newsgroups_vectorized instead...

Finish to fix sklearn dataset fetchers. Keep 20newsgroups_vectorized instead of non vectorized version that is the preprocessed version of this text dataset. Remove kddcup99 dataset.
parent d70fad15
No related branches found
No related tags found
1 merge request!9Resolve "Experiment pipeline"
......@@ -39,23 +39,20 @@ class DatasetLoader(object):
dataset_loading_func = change_binary_func_load(load_breast_cancer)
task = Task.BINARYCLASSIFICATION
elif name == 'olivetti_faces':
data = fetch_olivetti_faces(random_state=dataset_parameters.random_state, shuffle=True)
task = Task.MULTICLASSIFICATION
X, y = data.data, data.target
elif name == '20newsgroups':
data = fetch_20newsgroups(random_state=dataset_parameters.random_state, shuffle=True)
#X, y =
dataset = fetch_olivetti_faces(random_state=dataset_parameters.random_state, shuffle=True)
task = Task.MULTICLASSIFICATION
X, y = dataset.data, dataset.target
elif name == '20newsgroups_vectorized':
dataset_loading_func = fetch_20newsgroups_vectorized
dataset = fetch_20newsgroups_vectorized()
X, y = dataset.data, dataset.target
task = Task.MULTICLASSIFICATION
elif name == 'lfw_people':
data = fetch_lfw_people()
X, y = data.data, data.target
dataset = fetch_lfw_people()
X, y = dataset.data, dataset.target
task = Task.MULTICLASSIFICATION
elif name == 'lfw_pairs':
data = fetch_lfw_pairs()
X, y = data.data, data.target
dataset = fetch_lfw_pairs()
X, y = dataset.data, dataset.target
task = Task.MULTICLASSIFICATION
elif name == 'covtype':
X, y = fetch_covtype(random_state=dataset_parameters.random_state, shuffle=True, return_X_y=True)
......@@ -63,9 +60,6 @@ class DatasetLoader(object):
elif name == 'rcv1':
X, y = fetch_rcv1(random_state=dataset_parameters.random_state, shuffle=True, return_X_y=True)
task = Task.MULTICLASSIFICATION
elif name == 'kddcup99':
X, y = fetch_kddcup99(random_state=dataset_parameters.random_state, shuffle=True, return_X_y=True)
task = Task.MULTICLASSIFICATION
elif name == 'california_housing':
X, y = fetch_california_housing(return_X_y=True)
task = Task.REGRESSION
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment