Glenn, You need to fit the estimator with some data for the cv_results_ attribute to exist. You may refer to https://scikit-learn.org/stable/getting_started.html
Nicolas On Tue, 5 Jan 2021 at 17:25, Glenn Schultz via scikit-learn < scikit-learn@python.org> wrote: > All, > > I have a grid search of gradient boosting classifier. All works well the > best model is extracted and predict works on the model. I would like to > extract the cv_results_ My set-up is pretty standard > > gbclassifier = GridSearchCV(GradientBoostingClassifier(), > parameters, > verbose = 5, > n_jobs = 5, > cv = ShuffleSplit(n_splits = 5, test_size = .2, > random_state = 42), > refit = True, > scoring = “roc_auc”) > > print(gbclassifier.cv_results_) > > returns an attribute error ‘Gradient Boosting Classifier’ has no attribute > cv_results. I am not sure what I am doing wrong I checked the > documentation and followed some SO examples but no progress. I am missing > something any help is appreciated. > > Best, > Glenn > _______________________________________________ > scikit-learn mailing list > scikit-learn@python.org > https://mail.python.org/mailman/listinfo/scikit-learn >
_______________________________________________ scikit-learn mailing list scikit-learn@python.org https://mail.python.org/mailman/listinfo/scikit-learn