@@ -1033,7 +1033,7 @@ def cross_val_predict(estimator, X, y=None, cv=None, n_jobs=1,
1033
1033
"""
1034
1034
X , y = indexable (X , y )
1035
1035
1036
- cv = _check_cv (cv , X , y , classifier = is_classifier (estimator ))
1036
+ cv = check_cv (cv , X , y , classifier = is_classifier (estimator ))
1037
1037
# We clone the estimator to make sure that all the folds are
1038
1038
# independent, and that it is pickle-able.
1039
1039
parallel = Parallel (n_jobs = n_jobs , verbose = verbose ,
@@ -1191,7 +1191,7 @@ def cross_val_score(estimator, X, y=None, scoring=None, cv=None, n_jobs=1,
1191
1191
"""
1192
1192
X , y = indexable (X , y )
1193
1193
1194
- cv = _check_cv (cv , X , y , classifier = is_classifier (estimator ))
1194
+ cv = check_cv (cv , X , y , classifier = is_classifier (estimator ))
1195
1195
scorer = check_scoring (estimator , scoring = scoring )
1196
1196
# We clone the estimator to make sure that all the folds are
1197
1197
# independent, and that it is pickle-able.
@@ -1428,11 +1428,6 @@ def check_cv(cv, X=None, y=None, classifier=False):
1428
1428
The return value is guaranteed to be a cv generator instance, whatever
1429
1429
the input type.
1430
1430
"""
1431
- return _check_cv (cv , X = X , y = y , classifier = classifier )
1432
-
1433
-
1434
- def _check_cv (cv , X = None , y = None , classifier = False ):
1435
- # This exists for internal use while indices is being deprecated.
1436
1431
is_sparse = sp .issparse (X )
1437
1432
if cv is None :
1438
1433
cv = 3
@@ -1523,7 +1518,7 @@ def permutation_test_score(estimator, X, y, cv=None,
1523
1518
1524
1519
"""
1525
1520
X , y = indexable (X , y )
1526
- cv = _check_cv (cv , X , y , classifier = is_classifier (estimator ))
1521
+ cv = check_cv (cv , X , y , classifier = is_classifier (estimator ))
1527
1522
scorer = check_scoring (estimator , scoring = scoring )
1528
1523
random_state = check_random_state (random_state )
1529
1524
0 commit comments