FnLayer

Type Alias FnLayer 

Source
pub type FnLayer<'a, T> = LayerBase<Box<dyn Fn(T) -> T + 'a>, T>;
Expand description

A dynamic, functional alias of the [Layer] implementation leveraging boxed closures.

Aliased Type§

pub struct FnLayer<'a, T> {
    pub rho: Box<dyn Fn(T) -> T + 'a>,
    pub params: T,
}

Fields§

§rho: Box<dyn Fn(T) -> T + 'a>

the activation function of the layer

§params: T

the parameters of the layer; often weights and biases