Skip to main content

checkpoint

Function checkpoint 

Source
pub fn checkpoint<B: Backend, I: Tree<B>, O: Tree<B>>(
    f: impl Fn(I) -> O,
    input: I,
) -> O
Expand description

f(input), whose intermediate values reverse-mode differentiation recomputes from the inputs instead of storing (jax.checkpoint).