Skip to main content

from_slice_cpu

Function from_slice_cpu 

Source
pub fn from_slice_cpu<T: Pod + WithDType>(data: &[T]) -> Storage
Expand description

Build a CPU Storage from a typed slice, copying the bytes. The result has the dtype matching T and is 64-byte aligned.