Trait Backward

Source
pub trait Backward<X, Y> {
    type HParam;
    type Output;

    // Required method
    fn backward(
        &mut self,
        input: &X,
        delta: &Y,
        gamma: Self::HParam,
    ) -> Result<Self::Output>;
}
Expand description

A simple trait denoting a single backward pass through a layer of a neural network; the trait

Required Associated Types§

Required Methods§

Source

fn backward( &mut self, input: &X, delta: &Y, gamma: Self::HParam, ) -> Result<Self::Output>

Implementors§

Source§

impl<A, S, T> Backward<ArrayBase<S, Dim<[usize; 1]>>, ArrayBase<T, Dim<[usize; 0]>>> for Params<A, Ix1>
where A: Float + FromPrimitive + ScalarOperand, S: Data<Elem = A>, T: Data<Elem = A>,

Source§

impl<A, S, T> Backward<ArrayBase<S, Dim<[usize; 1]>>, ArrayBase<T, Dim<[usize; 1]>>> for Params<A, Ix2>
where A: Float + FromPrimitive + ScalarOperand, S: Data<Elem = A>, T: Data<Elem = A>,

Source§

impl<A, S, T> Backward<ArrayBase<S, Dim<[usize; 2]>>, ArrayBase<T, Dim<[usize; 1]>>> for Params<A, Ix1>
where A: Float + FromPrimitive + ScalarOperand, S: Data<Elem = A>, T: Data<Elem = A>,

Source§

impl<A, S, T> Backward<ArrayBase<S, Dim<[usize; 2]>>, ArrayBase<T, Dim<[usize; 2]>>> for Params<A, Ix2>
where A: Float + FromPrimitive + ScalarOperand, S: Data<Elem = A>, T: Data<Elem = A>,