pub struct MoeBackward<B>where
B: Backend,{
pub input: <B as BackendTypes>::FloatTensorPrimitive,
pub logits: <B as BackendTypes>::FloatTensorPrimitive,
pub gate: <B as BackendTypes>::FloatTensorPrimitive,
pub up: <B as BackendTypes>::FloatTensorPrimitive,
pub down: <B as BackendTypes>::FloatTensorPrimitive,
}Expand description
Actual original first-order derivatives of the native routed expert branch.
Fields§
§input: <B as BackendTypes>::FloatTensorPrimitiveInput gradient after dispatch-copy backward, without a second routing-weight multiplication.
logits: <B as BackendTypes>::FloatTensorPrimitiveOriginal source-logits storage VJP, including nonselected softmax experts.
gate: <B as BackendTypes>::FloatTensorPrimitiveOriginal FP32 gate-weight gradients.
up: <B as BackendTypes>::FloatTensorPrimitiveOriginal FP32 up-weight gradients.
down: <B as BackendTypes>::FloatTensorPrimitiveOriginal FP32 down-weight gradients.
Trait Implementations§
Auto Trait Implementations§
impl<B> Freeze for MoeBackward<B>
impl<B> RefUnwindSafe for MoeBackward<B>
impl<B> Send for MoeBackward<B>
impl<B> Sync for MoeBackward<B>
impl<B> Unpin for MoeBackward<B>
impl<B> UnsafeUnpin for MoeBackward<B>
impl<B> UnwindSafe for MoeBackward<B>
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