From 11df0141c1ef4470f5a015f0a618bc5510eaf30d Mon Sep 17 00:00:00 2001 From: Gertjan van den Burg Date: Tue, 15 Jan 2019 13:19:37 +0000 Subject: Future proof the cv argument Sklearn will change the default from 3-fold to 5-fold, so we're making that explicit now --- gensvm/gridsearch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gensvm') diff --git a/gensvm/gridsearch.py b/gensvm/gridsearch.py index dc835f9..bf4b9ce 100644 --- a/gensvm/gridsearch.py +++ b/gensvm/gridsearch.py @@ -296,7 +296,7 @@ class GenSVMGridSearchCV(BaseEstimator, MetaEstimatorMixin): Determines the cross-validation splitting strategy. Possible inputs for cv are: - - None, to use the default 3-fold cross validation, + - None, to use the default 5-fold cross validation, - integer, to specify the number of folds in a `(Stratified)KFold`, - An object to be used as a cross-validation generator. - An iterable yielding train, test splits. @@ -490,7 +490,7 @@ class GenSVMGridSearchCV(BaseEstimator, MetaEstimatorMixin): _validate_param_grid(self.param_grid) self.scoring = scoring - self.cv = cv + self.cv = 5 if cv is None else cv self.refit = refit self.verbose = verbose self.return_train_score = return_train_score -- cgit v1.2.3