pub enum BackwardKind {
Fused(FusedOpId),
Decompose,
NotDifferentiable,
}Expand description
What kind of backward this fused op has.
Fused(id)— emit a fused-backward op with the given id. Used by ops whose backward is awkward to express as a primitive decomposition (e.g. SoftmaxLastDimBackward’s fused subtract-and- project formula).Decompose— autograd derives the backward from the primitive decomposition (lower the fused node, then run autograd over the primitives).NotDifferentiable— backward returns Err / panics cleanly. Matches today’s QMatMul / ArgMaxDim treatment.
Variants§
Trait Implementations§
Source§impl Clone for BackwardKind
impl Clone for BackwardKind
impl Copy for BackwardKind
Source§impl Debug for BackwardKind
impl Debug for BackwardKind
impl Eq for BackwardKind
Source§impl PartialEq for BackwardKind
impl PartialEq for BackwardKind
impl StructuralPartialEq for BackwardKind
Auto Trait Implementations§
impl Freeze for BackwardKind
impl RefUnwindSafe for BackwardKind
impl Send for BackwardKind
impl Sync for BackwardKind
impl Unpin for BackwardKind
impl UnsafeUnpin for BackwardKind
impl UnwindSafe for BackwardKind
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.