Closed browshanravan closed 4 years ago
I see the problem - the get_params() does not include sub-parameters as the scikit-API requires. I will probably be abe to fix this on Wednesday.
With 0.7.6, you should be able to call grid.best_estimator_.get_params()
and get the requested keys. Note that the field selected_model
is always empty on the grid object itself, as the model is a parameter of the estimator.
On the other hand, the parameters of the other available models should now also be set on grid.get_params()
.
Thank you for improving my project :-)
Apologies for the extensive correction, but my question is asked better as follows.
I need to access the
best_estimator_
attribute parameters. The code for this isprint(grid.get_params().keys())
. So if you use this code in this example code, the output is as follows.As you can see, the parameters for the bestestimator (lets say the best estimator/selected estimator is ExtraTreesClassifier ) such as
n_estimators
is not accessible. The output forprint(grid.get_params().keys())
should have produced something likeestimator__clf__selected_model__ExtraTreesClassifier__n_estimators
. I need these parameters for feeding intovalidation_curve()