Enum cosyne::Activation[][src]

pub enum Activation {
    Linear,
    Threshold,
    Sign,
    Sigmoid,
    Tanh,
    SoftSign,
    BentIdentity,
    Relu,
}

Represents which transfer function to use for evaluating neural networks.

Variants

Linear

Maps input to output directly, as if there is no transfer function.

Threshold

Outputs 1 if input is greater than 0, 0 otherwise.

Sign

Outputs 1 if input is greater than 0, 0 if input is equal to 0, -1 otherwise. Useful for simple problems and boolean logic, as it only allows three possible output values.

Sigmoid

A non-linear function. This function is the most general, so it should be defaulted to.

Tanh

Tanh activation function with output range [-1.0, 1.0]

SoftSign

SoftSign activation function

BentIdentity

BentIdentity activation function

Relu

Rectified linear unit activation function

Implementations

impl Activation[src]

pub fn get_func(&self) -> fn(_: f64) -> f64[src]

Return the corresponding function to the Activation

pub fn from_i32(n: i32) -> Activation[src]

parse the Activation from an int 32 value

Trait Implementations

impl Clone for Activation[src]

impl Copy for Activation[src]

impl Debug for Activation[src]

impl Eq for Activation[src]

impl PartialEq<Activation> for Activation[src]

impl StructuralEq for Activation[src]

impl StructuralPartialEq for Activation[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,