When I usually need to do something like that, I just construct a tuple of
slice() objects. No need to use swapaxes(). Or am I missing something?
On Sat, Feb 1, 2025 at 10:24 AM Michael Mullen
wrote:
> Hello,
>
> I am writing a class handling NumPy arrays, and basing it off some
> computations I
Hello,
I am writing a class handling NumPy arrays, and basing it off some
computations I have done in C++ using the Eigen library. For tensors whose
length are only known at runtime, the Eigen chip method is useful for
slicing a tensor along a specific axis while keeping all other axes the
same. I