Skip to content
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

Fix label binarize for binary class #5900

Merged
merged 7 commits into from
May 22, 2024

Conversation

jinsolp
Copy link
Contributor

@jinsolp jinsolp commented May 20, 2024

Closes #5740

Fix for cuml's label_binarize to have the same output as scikit-learn's label_binarize for binary classes.

Note: Unlike scikit-learn's scipy.sparse._csr.csr_matrix.getcol(), cuml's cupyx.scipy.sparse.csr_matrix.getcol() does not support -1 indexing.

@jinsolp jinsolp requested a review from a team as a code owner May 20, 2024 23:47
@github-actions github-actions bot added the Cython / Python Cython or Python issue label May 20, 2024
@beckernick
Copy link
Member

Note: Unlike scikit-learn's scipy.sparse._csr.csr_matrix.getcol(), cuml's cupyx.scipy.sparse.csr_matrix.getcol() does not support -1 indexing.

Can you file a feature request for this on CuPy (if there isn't on already)? Feels like this is probably a small tweak to existing slicing logic.

@jinsolp
Copy link
Contributor Author

jinsolp commented May 21, 2024

I don't think they have it already.
I made an issue here.

@dantegd dantegd requested a review from divyegala May 22, 2024 15:39
@divyegala divyegala added bug Something isn't working non-breaking Non-breaking change labels May 22, 2024
@divyegala
Copy link
Member

/merge

@rapids-bot rapids-bot bot merged commit 10ba0a7 into rapidsai:branch-24.06 May 22, 2024
60 of 63 checks passed
@jinsolp jinsolp deleted the fix-label-binarize branch May 23, 2024 16:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Cython / Python Cython or Python issue non-breaking Non-breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] label_binarize is different from sklearn for binary class.
3 participants