pub struct QuantizedFp8 {
pub qvalues: Vec<u8>,
pub scales: Vec<f32>,
pub groups: Vec<u32>,
pub variant: Fp8Variant,
}Expand description
An f32 tensor quantized to f8 bytes, one f32 scale per group (the tensor is scaled by
1 / scale before conversion, matching the affine schemes’ convention of storing a
multiplicative dequantization scale).
Fields§
§qvalues: Vec<u8>One f8-encoded byte per input element, same order as the input.
scales: Vec<f32>One scale per group.
groups: Vec<u32>qvalues[i]’s group is groups[i].
variant: Fp8VariantWhich variant qvalues was encoded with.
Trait Implementations§
Source§impl Clone for QuantizedFp8
impl Clone for QuantizedFp8
Source§fn clone(&self) -> QuantizedFp8
fn clone(&self) -> QuantizedFp8
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 moreAuto Trait Implementations§
impl Freeze for QuantizedFp8
impl RefUnwindSafe for QuantizedFp8
impl Send for QuantizedFp8
impl Sync for QuantizedFp8
impl Unpin for QuantizedFp8
impl UnsafeUnpin for QuantizedFp8
impl UnwindSafe for QuantizedFp8
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