Fix make sure enabling array_api_dispatch=True does not break any estimator on NumPy inputs#32846
Conversation
…entation in the memoryviewslices unwrap helper
|
Only just getting to this. I asked @lesteve about the release schedule and he'd like to get 1.8.0 done more or less "now". I think it would be nice to have this PR in, but it will take more than five minutes to review. For me it is ok to send 1.8.0 off without this merged. I can understand that at some point you need to decide "the 1.8 boat has left, you are too late". Even though it makes me sad to ship it with a bug that we know about. Maybe having a small bug is ok (there are probably more that we haven't yet found) - we will find out if someone tried array API support because they'll report an issue ;) |
OmarManzoor
left a comment
There was a problem hiding this comment.
Thank you for the PR @ogrisel
|
@betatim I think the release-critical bugfixes have already all been merged. This one can indeed wait and this is why I did not milestone it. We can take our time to review carefully, no hurry. |
|
@ogrisel There is a CI failure which seems unrelated to this PR but still seems like something erroneous |
OmarManzoor
left a comment
There was a problem hiding this comment.
LGTM. Thank you @ogrisel
Indeed, there is a missing rng seed. Let me open a dedicated PR. |
…rs-on-numpy-inputs
lucyleeow
left a comment
There was a problem hiding this comment.
LGTM, thanks for the other fixes here. Nits only
sklearn/utils/estimator_checks.py
Outdated
| When expect_only_array_outputs is False, the check accepts non-array | ||
| outputs from estimator methods (e.g., sparse data structures). This is |
There was a problem hiding this comment.
Could you expand on this? I was confused just reading this, but https://github.com/scikit-learn/scikit-learn/pull/32846/changes#r2602981393 cleared it up for me.
There was a problem hiding this comment.
I pushed 969f06a as an attempt to clarify this.
There was a problem hiding this comment.
Thanks! Feel free to merge when you're ready!
Co-authored-by: Lucy Liu <jliu176@gmail.com> Co-authored-by: Loïc Estève <loic.esteve@ymail.com>
Co-authored-by: Lucy Liu <jliu176@gmail.com>
…rs-on-numpy-inputs
|
@ogrisel Should we merge this? |
betatim
left a comment
There was a problem hiding this comment.
One tweak to a comment, for me it made it easier to understand. Otherwise LGTM, let's merge
Co-authored-by: Tim Head <betatim@gmail.com>
…rs-on-numpy-inputs
This is a follow-up to #32840. This should detect most possible silent breaking in future refactoring of helper functions that are used by both in array API supporting and not supporting code in scikit-learn.
AI usage disclosure
I used AI assistance for: