Skip to content

Commit 1f040b4

Browse files
committed
FIX revert changes introduced by mistake in previous commit
If the dataset is too small, stratified k-fold CV used internally by some classifiers such as LogisticRegressionCV raises a warning.
1 parent 5f32d8d commit 1f040b4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sklearn/utils/estimator_checks.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -770,8 +770,9 @@ def check_cluster_overwrite_params(name, Clustering):
770770

771771

772772
def check_sparsify_multiclass_classifier(name, Classifier):
773-
X = np.array([[-2, -1], [-1, -1], [-1, -2], [1, 1], [1, 2], [2, 1]])
774-
y = [1, 1, 1, 2, 2, 3]
773+
X = np.array([[-2, -1], [-1, -1], [-1, -2], [1, 1], [1, 2], [2, 1],
774+
[-1, -2], [2, 2], [-2, -2]])
775+
y = [1, 1, 1, 2, 2, 2, 3, 3, 3]
775776
est = Classifier()
776777

777778
est.fit(X, y)

0 commit comments

Comments
 (0)