pub enum Fp8Format {
E4m3,
E5m2,
}Expand description
The two IEEE-style 8-bit float encodings used for low-precision inference.
Variants§
E4m3
E4M3 (HF8): 1 sign, 4 exponent, 3 mantissa bits.
E5m2
E5M2 (BF8): 1 sign, 5 exponent, 2 mantissa bits.
Implementations§
Source§impl Fp8Format
impl Fp8Format
Sourcepub fn exponent_bits(self) -> u32
pub fn exponent_bits(self) -> u32
Number of exponent bits.
Sourcepub fn mantissa_bits(self) -> u32
pub fn mantissa_bits(self) -> u32
Number of mantissa bits.
Sourcepub fn intel_name(self) -> &'static str
pub fn intel_name(self) -> &'static str
The Intel naming used in oneAPI docs.
Trait Implementations§
impl Copy for Fp8Format
impl Eq for Fp8Format
impl StructuralPartialEq for Fp8Format
Auto Trait Implementations§
impl Freeze for Fp8Format
impl RefUnwindSafe for Fp8Format
impl Send for Fp8Format
impl Sync for Fp8Format
impl Unpin for Fp8Format
impl UnsafeUnpin for Fp8Format
impl UnwindSafe for Fp8Format
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