pub struct TensorBuffer {
pub handle: Handle,
pub shape: Shape,
pub strides: Strides,
pub dtype: DType,
}Expand description
An owned device buffer binding and its logical tensor layout.
Fields§
§handle: HandleRetains the allocation for the duration of native execution.
shape: ShapeLogical dimensions.
strides: StridesElement strides, including non-contiguous layouts.
dtype: DTypeStored element type; native implementations must validate it.
Trait Implementations§
Source§impl Clone for TensorBuffer
impl Clone for TensorBuffer
Auto Trait Implementations§
impl !RefUnwindSafe for TensorBuffer
impl !UnwindSafe for TensorBuffer
impl Freeze for TensorBuffer
impl Send for TensorBuffer
impl Sync for TensorBuffer
impl Unpin for TensorBuffer
impl UnsafeUnpin for TensorBuffer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more