-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
[MRG] Sample weights for ElasticNetCV #16449
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
Conversation
Co-Authored-By: Alexandre Gramfort <alexandre.gramfort@m4x.org>
Co-Authored-By: Alexandre Gramfort <alexandre.gramfort@m4x.org>
@agramfort How would you like to calculate the cross-validated mean square error? Weighted by Furthermore, just as info, the current approach to rescale X by sqrt(sw) might use more memory copies as the unweighted version. |
The diff on Github doesn't seem to take into account the merge #15436 PR, maybe merging master would help?
I couldn't find the corresponding issue, maybe it could be worth opening one. There was #15651 but it's a different topic. In the short term, I think we want to be consistent with
_fit_and_score function, sample_weight is not used for scoring there. We could discuss what is the right thing to do (or whether there should be an option to allow taking into account sample weight for scoring) in a separate issue.
|
@jjerphan If you feel comfortable, I'd appreciate your review approval very much:smirk: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @lorentzenchr,
Here are a few lasts suggestions before approval. 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @lorentzenchr!
Decision in yesterday's dev meeting (2021-05-25): Remove |
To have it easily referenced, here is the code that is needed for
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
besides LGTM
thx a lot @lorentzenchr for taking the time to dive deep into this
@rth Do you want to merge? @agramfort and @jjerphan have already approved. This PR only adds |
@lorentzenchr you need to rebase this one |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot! LGTM. Please merge main in to resolve conflicts.
@rth Main merged and all CI green. |
Co-authored-by: Alexandre Gramfort <alexandre.gramfort@m4x.org> Co-authored-by: Christian Lorentzen <lorentzen.ch@googlemail.com> Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Reference Issues/PRs
Partially solves #3702: Adds sample_weight to
ElasticNetCV
andLassoCV
, but only for dense feature array X.It is a follow up of PR #15436.
Any other comments?
DO NOT MERGE BEFORE #15436 as it is based on that branch.