pub enum WeightFormat {
Nvfp4,
Fp8BlockScaled,
Bf16Dense,
}Expand description
2026-09-25: On-disk weight format, derived from detect_nvfp4_variant.
Variants§
Nvfp4
2026-09-25: ModelOpt (Standard) or compressed-tensors NVFP4 on disk,
and Bf16Raw checkpoints, which the loader quantises to NVFP4.
Fp8BlockScaled
2026-09-25: Block-scaled FP8 E4M3 on disk (Fp8Dequanted).
Bf16Dense
2026-09-25: BF16 on disk. WeightFormat::detect never returns it.
Implementations§
Source§impl WeightFormat
impl WeightFormat
Sourcepub fn detect(store: &WeightStore, config: &ModelConfig) -> Self
pub fn detect(store: &WeightStore, config: &ModelConfig) -> Self
2026-09-25: Detect the weight format from a WeightStore by probing
tensor names.
pub fn is_fp8(&self) -> bool
Trait Implementations§
Source§impl Clone for WeightFormat
impl Clone for WeightFormat
Source§fn clone(&self) -> WeightFormat
fn clone(&self) -> WeightFormat
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for WeightFormat
impl Debug for WeightFormat
Source§impl PartialEq for WeightFormat
impl PartialEq for WeightFormat
impl Copy for WeightFormat
impl Eq for WeightFormat
impl StructuralPartialEq for WeightFormat
Auto Trait Implementations§
impl Freeze for WeightFormat
impl RefUnwindSafe for WeightFormat
impl Send for WeightFormat
impl Sync for WeightFormat
impl Unpin for WeightFormat
impl UnwindSafe for WeightFormat
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.