-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revisit CrossValidateReporter.__init__
parameters
#953
Comments
In line with a comment on the original PR: #871 (comment) |
I'm happy to copy-paste |
It does go against the drop-in replacement indeed. However, it would be more user-friendly to go by this suggestion. I've been convinced that everything that we would remove in this proposed solution is edge-case, or shouldn't be used. Therefore, let's go :)! |
@augustebaum i don't understand why you said that changing the argument list is against the "drop-in replacement". For instance:
|
other similar request: #1000. Therefore increasing prio to P1. |
@glemaitre can we take the opportunity of including this issue in the upcoming |
Yes. I think that it will be part of the revamp. |
Right now,
CrossValidateReporter.__init__
is taking*args
and**kwargs
as parameters.It is pretty hard for user to infer what are the parameters in such case. We should avoid to have these generic signature.
Since we are wrapping the
sklearn.model_selection.cross_validate
, we can make an editorial choice of the parameters that we want to expose.Currently, the signature is
For instance, there is no need to request the user any of the
return_*
values since we are going to persist them to make any computation.We would almost request to not accept
groups
orfit_params
since it would lead to bugs and we should encourage the usage of the metadata routing in this case.I would also not expose the
verbose
option because we should come with a nicer way to observe the progress of the computation. This is related with #949.We should probably also simplify and not expose
pre-dispatch
orerror_score
, the first one being a low level component while the second one should be highlighted from the report that we provide.Therefore, I would think that
estimator
,X
,y
,scoring
,cv
,params
, andn_jobs
are the sufficient parameters for this class. We should therefore explicitly document these parameters without redirecting to the scikit-learn documentation (when developing in and editor/notebook, I don't really want to be redirected on an external webpage).The text was updated successfully, but these errors were encountered: