pub enum PackedDType {
Int4,
Int8,
Fp8E4M3,
Fp8E5M2,
}Expand description
Packed scalar encoding used by a low-precision TOSA acceptance case.
Variants§
Int4
Signed two’s-complement values packed low nibble first.
Int8
Signed two’s-complement bytes.
Fp8E4M3
TOSA FP8 E4M3 bytes.
Fp8E5M2
TOSA FP8 E5M2 bytes.
Implementations§
Source§impl PackedDType
impl PackedDType
Sourcepub const fn storage_bytes(self, elements: usize) -> Option<usize>
pub const fn storage_bytes(self, elements: usize) -> Option<usize>
Number of bytes needed for elements densely packed values.
Trait Implementations§
Source§impl Clone for PackedDType
impl Clone for PackedDType
Source§fn clone(&self) -> PackedDType
fn clone(&self) -> PackedDType
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for PackedDType
Source§impl Debug for PackedDType
impl Debug for PackedDType
impl Eq for PackedDType
Source§impl PartialEq for PackedDType
impl PartialEq for PackedDType
Source§fn eq(&self, other: &PackedDType) -> bool
fn eq(&self, other: &PackedDType) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PackedDType
Auto Trait Implementations§
impl Freeze for PackedDType
impl RefUnwindSafe for PackedDType
impl Send for PackedDType
impl Sync for PackedDType
impl Unpin for PackedDType
impl UnsafeUnpin for PackedDType
impl UnwindSafe for PackedDType
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