pub struct EncodedTensor {
pub name: String,
pub shape: Vec<usize>,
pub dtype: String,
pub layer_type: LayerType,
pub indices: Vec<u16>,
pub residuals: Option<Vec<i8>>,
pub residual_scale: f32,
pub stats: EncodingStats,
}Expand description
Encoded tensor data
Fields§
§name: StringOriginal tensor name
shape: Vec<usize>Original shape
dtype: StringOriginal dtype
layer_type: LayerTypeLayer type for codebook selection
indices: Vec<u16>Quantized indices
residuals: Option<Vec<i8>>Residual data (if enabled)
residual_scale: f32Scale factor for residuals
stats: EncodingStatsCompression statistics
Trait Implementations§
Source§impl Clone for EncodedTensor
impl Clone for EncodedTensor
Source§fn clone(&self) -> EncodedTensor
fn clone(&self) -> EncodedTensor
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 EncodedTensor
impl Debug for EncodedTensor
Source§impl<'de> Deserialize<'de> for EncodedTensor
impl<'de> Deserialize<'de> for EncodedTensor
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 Freeze for EncodedTensor
impl RefUnwindSafe for EncodedTensor
impl Send for EncodedTensor
impl Sync for EncodedTensor
impl Unpin for EncodedTensor
impl UnsafeUnpin for EncodedTensor
impl UnwindSafe for EncodedTensor
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