Looking through the ndarray API, as far as I can tell, only 1-dimensional arrays support .collect() directly, hower, the creation of a 2-dimensional array (Array2) from a Vec<[T; N]> is super cheap, as far as I can tell, and works without any copying or moving of the data, i.e. the allocation of the Vecis just used as-is. So you can just do .collect::<Vec<_>>().into(); and annotate the Array2 type, and everything should work nicely and efficiently.