PresplitFilesCV#

class PresplitFilesCV(cv=None)[source]#

Cross-validation iterator over split predefined in files.

This class is useful in orchestration where the train and test set is provided in separate files.

Methods

get_n_splits()

Return the number of splits.

split(data[, y, groups])

Split the data according to the train/test index.

split(data, y=None, groups=None)[source]#

Split the data according to the train/test index.

Parameters:
datapandas.DataFrame
Yields:
trainndarray

Train indices

testndarray

Test indices

get_n_splits()[source]#

Return the number of splits.

Returns:
n_splitsint