Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2d8842e

Browse filesBrowse files
committed
COSMIT make BaseKFold private with underscore
1 parent 0db0d05 commit 2d8842e
Copy full SHA for 2d8842e

File tree

1 file changed

+4
-4
lines changed
Filter options

1 file changed

+4
-4
lines changed

‎sklearn/cross_validation.py

Copy file name to clipboardExpand all lines: sklearn/cross_validation.py
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -223,12 +223,12 @@ def __len__(self):
223223
/ factorial(self.p))
224224

225225

226-
class BaseKFold(with_metaclass(ABCMeta, _PartitionIterator)):
226+
class _BaseKFold(with_metaclass(ABCMeta, _PartitionIterator)):
227227
"""Base class to validate KFold approaches"""
228228

229229
@abstractmethod
230230
def __init__(self, n, n_folds, indices, k=None):
231-
super(BaseKFold, self).__init__(n, indices)
231+
super(_BaseKFold, self).__init__(n, indices)
232232
if k is not None: # pragma: no cover
233233
warnings.warn("The parameter k was renamed to n_folds and will be"
234234
" removed in 0.15.", DeprecationWarning)
@@ -246,7 +246,7 @@ def __init__(self, n, n_folds, indices, k=None):
246246
% (self.n_folds, self.n))
247247

248248

249-
class KFold(BaseKFold):
249+
class KFold(_BaseKFold):
250250
"""K-Folds cross validation iterator.
251251
252252
Provides train/test indices to split data in train test sets. Split
@@ -334,7 +334,7 @@ def __len__(self):
334334
return self.n_folds
335335

336336

337-
class StratifiedKFold(BaseKFold):
337+
class StratifiedKFold(_BaseKFold):
338338
"""Stratified K-Folds cross validation iterator
339339
340340
Provides train/test indices to split data in train test sets.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.