pub struct ShardingMetadata {
pub shard_count: usize,
pub shard_index: usize,
pub total_size: u64,
pub pattern: Option<String>,
}Expand description
Sharding metadata for multi-file models
Fields§
§shard_count: usizeTotal number of shards
shard_index: usizeThis shard’s index (0-based)
total_size: u64Total size across all shards
pattern: Option<String>Shard file pattern (e.g., “model-{:05d}-of-{:05d}.apr”)
Trait Implementations§
Source§impl Clone for ShardingMetadata
impl Clone for ShardingMetadata
Source§fn clone(&self) -> ShardingMetadata
fn clone(&self) -> ShardingMetadata
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 ShardingMetadata
impl Debug for ShardingMetadata
Source§impl Default for ShardingMetadata
impl Default for ShardingMetadata
Source§fn default() -> ShardingMetadata
fn default() -> ShardingMetadata
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ShardingMetadata
impl<'de> Deserialize<'de> for ShardingMetadata
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 ShardingMetadata
impl RefUnwindSafe for ShardingMetadata
impl Send for ShardingMetadata
impl Sync for ShardingMetadata
impl Unpin for ShardingMetadata
impl UnsafeUnpin for ShardingMetadata
impl UnwindSafe for ShardingMetadata
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