pub struct ConversionOptions {
pub quantization: Option<String>,
pub verify: bool,
pub compute_stats: bool,
pub tolerance: f32,
pub preserve_metadata: bool,
pub add_provenance: bool,
pub tokenizer_path: Option<PathBuf>,
}Expand description
Options for conversion operations
Fields§
§quantization: Option<String>Target quantization (None = preserve original)
verify: boolVerify after conversion
compute_stats: boolCompute tensor statistics
tolerance: f32Tolerance for floating-point comparison
preserve_metadata: boolPreserve metadata from source
add_provenance: boolAdd conversion provenance to metadata
tokenizer_path: Option<PathBuf>External tokenizer.json for weights-only models (PMAT-232)
Implementations§
Source§impl ConversionOptions
impl ConversionOptions
Sourcepub fn without_quantization(&self) -> ConversionOptions
pub fn without_quantization(&self) -> ConversionOptions
Copy of these options with quantization removed.
Used for the intermediate hop of a multi-step conversion: quantizing at the intermediate step and at the final export would quantize the weights twice.
Trait Implementations§
Source§impl Clone for ConversionOptions
impl Clone for ConversionOptions
Source§fn clone(&self) -> ConversionOptions
fn clone(&self) -> ConversionOptions
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 moreSource§impl Debug for ConversionOptions
impl Debug for ConversionOptions
Source§impl Default for ConversionOptions
impl Default for ConversionOptions
Source§fn default() -> ConversionOptions
fn default() -> ConversionOptions
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ConversionOptions
impl RefUnwindSafe for ConversionOptions
impl Send for ConversionOptions
impl Sync for ConversionOptions
impl Unpin for ConversionOptions
impl UnsafeUnpin for ConversionOptions
impl UnwindSafe for ConversionOptions
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,
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