pub struct HostTensor<'a> {
pub dtype: DType,
pub shape: &'a [usize],
pub bytes: &'a [u8],
}Expand description
A weight as it sits in the checkpoint, before a backend converts it.
Fields§
§dtype: DTypeElement type.
shape: &'a [usize]Shape.
bytes: &'a [u8]Little endian, row major.
Trait Implementations§
Source§impl<'a> Clone for HostTensor<'a>
impl<'a> Clone for HostTensor<'a>
impl<'a> Copy for HostTensor<'a>
Auto Trait Implementations§
impl<'a> Freeze for HostTensor<'a>
impl<'a> RefUnwindSafe for HostTensor<'a>
impl<'a> Send for HostTensor<'a>
impl<'a> Sync for HostTensor<'a>
impl<'a> Unpin for HostTensor<'a>
impl<'a> UnsafeUnpin for HostTensor<'a>
impl<'a> UnwindSafe for HostTensor<'a>
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