Source code for evalml.preprocessing.data_splitters.sk_splitters
"""SKLearn data splitter wrapper classes."""fromsklearn.model_selectionimportKFold,StratifiedKFold
[docs]classKFold(KFold):"""Wrapper class for sklearn's KFold splitter."""@propertydefis_cv(self):"""Returns whether or not the data splitter is a cross-validation data splitter. Returns: bool: If the splitter is a cross-validation data splitter """returnTrue
[docs]classStratifiedKFold(StratifiedKFold):"""Wrapper class for sklearn's Stratified KFold splitter."""@propertydefis_cv(self):"""Returns whether or not the data splitter is a cross-validation data splitter. Returns: bool: If the splitter is a cross-validation data splitter """returnTrue