LambdaNet-0.2.0.0: A configurable and extensible neural network library

Safe HaskellSafe-Inferred
LanguageHaskell98

Network.Neuron

Synopsis

Documentation

data Neuron a Source

Using this structure allows users of the library to create their own neurons by creating two functions - an activation function and its derivative - and packaging them up into a neuron type.

type ActivationFunction a = a -> a Source

type ActivationFunction' a = a -> a Source

sigmoidNeuron :: Floating a => Neuron a Source

Our provided neuron types: sigmoid, tanh, reclu

sigmoid :: Floating a => a -> a Source

The sigmoid activation function, a standard activation function defined on the range (0, 1).

sigmoid' :: Floating a => a -> a Source

The derivative of the sigmoid function conveniently can be computed in terms of the sigmoid function.

tanh :: Floating a => a -> a

tanh' :: Floating a => a -> a Source

The hyperbolic tangent activation function is provided in Prelude. Here we provide the derivative. As with the sigmoid function, the derivative of tanh can be computed in terms of tanh.

reclu :: Floating a => a -> a Source

The rectified linear activation function. This is a more "biologically accurate" activation function that still retains differentiability.

reclu' :: Floating a => a -> a Source

The derivative of the rectified linear activation function is just the sigmoid.