Skip to main content

Module split

Module split 

Source
Expand description

Typed-array variant of split_with_sizes for clean destructuring. Typed-array variants of [Tensor::split_with_sizes].

Functions§

split_into
Like [Tensor::split_with_sizes] but returns a fixed-size array, enabling let [a, b, c, ...] = split_into::<…, N>(t, [size_a, size_b, size_c, ...], dim); destructuring at the call site instead of a fragile parts.next().unwrap() chain.