pub struct GradientCheckpoint {
pub id: String,
pub saved_tensors: HashMap<String, Vec<f64>>,
pub memory_saved: usize,
}Expand description
Gradient checkpointing utility.
Fields§
§id: StringCheckpoint identifier
saved_tensors: HashMap<String, Vec<f64>>Saved tensors for recomputation
memory_saved: usizeMemory saved by checkpointing (bytes)
Implementations§
Trait Implementations§
Source§impl Clone for GradientCheckpoint
impl Clone for GradientCheckpoint
Source§fn clone(&self) -> GradientCheckpoint
fn clone(&self) -> GradientCheckpoint
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 moreAuto Trait Implementations§
impl Freeze for GradientCheckpoint
impl RefUnwindSafe for GradientCheckpoint
impl Send for GradientCheckpoint
impl Sync for GradientCheckpoint
impl Unpin for GradientCheckpoint
impl UnwindSafe for GradientCheckpoint
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