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
But that said, this is an usual conversion as the resulting memory layout is relatively inefficient compared to store the two-dimensional array in a single allocation. Maybe you could expand a little on why you need Vec<Vec<_>> and we can find a way to reduce the number of separate allocations?
Activity
adamreichold commentedon Apr 12, 2022
I think the easiest way to achieve this is to use
ndarray'srowsorColumnsiterators and collect those, e.g.But that said, this is an usual conversion as the resulting memory layout is relatively inefficient compared to store the two-dimensional array in a single allocation. Maybe you could expand a little on why you need
Vec<Vec<_>>and we can find a way to reduce the number of separate allocations?