pub struct Tensor {
pub buf: Buffer,
pub shape: Vec<usize>,
}Expand description
An f32 tensor living in GPU memory. Ops chain Tensor→Tensor with no host readback until to_vec,
so a whole model runs on-device — this is the L2/L3 substrate (the graph executor works on these).
Fields§
§buf: Buffer§shape: Vec<usize>Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Tensor
impl !UnwindSafe for Tensor
impl Freeze for Tensor
impl Send for Tensor
impl Sync for Tensor
impl Unpin for Tensor
impl UnsafeUnpin for Tensor
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