[Feature Request] XLA (and NumPy) compatible sorting for NaNs #2664
polvalente
started this conversation in
Ideas
Replies: 1 comment 2 replies
-
Well aside whether or not we can provide that option.. it looks like the NaN breaks the sort which is perhaps unexpected. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm starting this as a discussion because I'm not sure if this has been considered and there wasn't an issue template for feature requests.
In short, NaNs in numpy will be sorted to the end while MLX seems to not care about them. I can see the reasoning behind this, but it would be nice if we could have an option to control this.
I believe this would affect max, min, argmax, argmin, argsort and sort. Not sure if there are any other similar functions.
Beta Was this translation helpful? Give feedback.
All reactions