-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
ENH Add Array API compatibility for additive_chi2_kernel
#29144
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
ENH Add Array API compatibility for additive_chi2_kernel
#29144
Conversation
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. Could you please just update the _array_api.rst
documentation file to reference this function?
And there are a bunch of conflicts to resolve when merging |
Also please check that the CUDA tests pass with https://gist.github.com/EdAbati/ff3bdc06bafeb92452b3740686cc8d7c. |
CUDA tests passed |
Ping @betatim @OmarManzoor. |
I resolved the merge conflict and started the CUDA CI https://github.com/scikit-learn/scikit-learn/actions/runs/9501959732 edit: CI failed because I made a mistake when resolving the conflict. |
Towards #26024
Reference Issues/PRs
What does this implement/fix? Explain your changes.
Any other comments?
Due to
_chi2_kernel_fast
written in cython it can't be used with array-api containers. So I implemented all calculations using array broadcasting. It is not faster than cython function, so I use_chi2_kernel_fast
whenadditive_chi2_kernel
gets a numpy array.