pub struct QuantSpec {
pub family: Option<String>,
pub ggml_dtype: Option<String>,
pub granularity: Option<String>,
pub block_shape: Option<Value>,
pub role: Option<String>,
pub scale_operand: Option<String>,
}Expand description
Quant facts (§3.2 fdx.quant:). All tokens are String (disarms Norway;
the typed conversion is a lowering concern).
Fields§
§family: Option<String>FDXQuant.family symbol: none|GGML_BLOCK|MX|AFFINE_INT|AFFINE_FLOAT|AFFINE_BLOCK (FDX §6.2).
ggml_dtype: Option<String>GgmlDType variant NAME when family=GGML_BLOCK (e.g. Q4_0, Q4K); §3.4.
granularity: Option<String>FDXScaleGranularity symbol: PerTensor|PerToken|PerChannel|PerBlock (FDX §6.2).
block_shape: Option<Value>Per-output-row per-block grain (e.g. [block_size]) for AFFINE_BLOCK (§3.9.3 / NF4).
role: Option<String>activation|weight (FDX ScalePair role).
scale_operand: Option<String>Role of the SEPARATE-GRAPH-INPUT scale operand when the ABI takes the
scale as its own input (§3.9.3). Mutually exclusive with a sidecar
scale_buffer (the ScaleDoubleDeclared check, a later step).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for QuantSpec
impl<'de> Deserialize<'de> for QuantSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for QuantSpec
impl Freeze for QuantSpecwhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<Value>: Freeze,
PhantomData<usize>: Freeze,
PhantomData<Bucket<Value, Value>>: Freeze,
*const TaggedValue is !null: Freeze,
PhantomData<TaggedValue>: Freeze,
impl Move for QuantSpec
impl RefUnwindSafe for QuantSpec
impl Send for QuantSpec
impl Sync for QuantSpec
impl Unpin for QuantSpec
impl UnsafeUnpin for QuantSpecwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<Value>: UnsafeUnpin,
PhantomData<usize>: UnsafeUnpin,
PhantomData<Bucket<Value, Value>>: UnsafeUnpin,
*const TaggedValue is !null: UnsafeUnpin,
PhantomData<TaggedValue>: UnsafeUnpin,
impl UnwindSafe for QuantSpec
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more