pub struct CheckpointConfig {
pub enable_compression: bool,
pub include_tape: bool,
pub verify_checksum: bool,
pub incremental: bool,
}Expand description
Configuration for checkpoint creation and loading.
Fields§
§enable_compression: boolEnable compression (reduces file size but increases save time)
include_tape: boolInclude forward tape in checkpoint (needed for gradient computation)
verify_checksum: boolVerify checksum on load
incremental: boolSave only tensors that changed since last checkpoint
Implementations§
Source§impl CheckpointConfig
impl CheckpointConfig
Sourcepub fn for_training() -> Self
pub fn for_training() -> Self
Create a configuration for training checkpoints (includes tape).
Sourcepub fn for_inference() -> Self
pub fn for_inference() -> Self
Create a configuration for inference checkpoints (no tape, compressed).
Sourcepub fn incremental() -> Self
pub fn incremental() -> Self
Create a configuration for incremental checkpoints.
Trait Implementations§
Source§impl Clone for CheckpointConfig
impl Clone for CheckpointConfig
Source§fn clone(&self) -> CheckpointConfig
fn clone(&self) -> CheckpointConfig
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 CheckpointConfig
impl Debug for CheckpointConfig
Auto Trait Implementations§
impl Freeze for CheckpointConfig
impl RefUnwindSafe for CheckpointConfig
impl Send for CheckpointConfig
impl Sync for CheckpointConfig
impl Unpin for CheckpointConfig
impl UnwindSafe for CheckpointConfig
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,
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