You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
any() and all() should support axis and keep_dims #1555
To match numpy, xt::any() and xt::all() should have an axis argument allowing for multiple axes (it should probably be called axes). Maybe it can be implemented with the reduction framework that already exists?
The only trouble is making sure you can early exit with things like xt::any(). If you see any true values along the way, exit immediately for performance.
Activity
wolfv commentedon Jun 5, 2019
we should move any and all to the reducer framework.
DavisVaughan commentedon Jun 5, 2019
i agree!
wolfv commentedon Jun 5, 2019
It's actually a "simple" fix - just need to pass a correct reducing lambda or struct to the make reducer macro.
btw. where was your issue with the
cum*functions? I was looking for that :)wolfv commentedon Jun 5, 2019
ah yeah, except for the fast exit ...
DavisVaughan commentedon Jun 5, 2019
i believe its this one
#1334
linked them all from
DavisVaughan/rray1#30
Ivorforce commentedon Sep 19, 2024
I was able to get axis support for any / all pretty easily using the reduction macros:
To make use of the optimized implementation with no axes provided, I currently use:
It would be nice if the implementations were unified so this workaround can be dropped.