Main Page   Modules   Data Structures   File List   Data Fields   Globals   Related Pages  

gnn_affine : Affine Activation Function.
[Atomic Nodes.]


Detailed Description

This node type implements an Affine activatino function given by:

where the index runs over all inputs / outputs. The amplitude factors and the biases are independent and can be trained. Usually, this activation function is placed after a non-linear activation function which is limited in its output range, like a gaussian, logistic sigmoid or a hyperbolic tangent activation function, to scale the outputs to the correct magnitudes.

The function's gradients are:

with respect to its inputs, and

with respect to its parameters.

Typedefs

typedef _gnn_affine gnn_affine
 The structure for a gnn_affine : Affine Activation Function. node.


Functions

int gnn_affine_f (gnn_node *node, const gsl_vector *x, const gsl_vector *w, gsl_vector *y)
 Computes the output.

int gnn_affine_dx (gnn_node *node, const gsl_vector *x, const gsl_vector *w, const gsl_vector *dy, gsl_vector *dx)
 Computes .

int gnn_affine_dw (gnn_node *node, const gsl_vector *x, const gsl_vector *w, const gsl_vector *dy, gsl_vector *dw)
 Computes .

void gnn_affine_destroy (gnn_node *node)
 Destructor function.

gnn_nodegnn_affine_new (int input_size, double a, double b)
 Creates an Affine Activation Function node.

gnn_nodegnn_affine_standard_new (int input_size)
 Creates a standard Affine Activation Function node.


Typedef Documentation

typedef struct _gnn_affine gnn_affine
 

This datatype holds the information for a gnn_affine : Affine Activation Function. node. Basically, it extends the gnn_node with special pointers to get fast accesses to the amplitudes and variances.

Definition at line 48 of file gnn_affine.h.


Function Documentation

void gnn_affine_destroy gnn_node   node [static]
 

Parameters:
node  A pointer to the gnn_affine : Affine Activation Function. node.

Definition at line 205 of file gnn_affine.c.

int gnn_affine_dw gnn_node   node,
const gsl_vector *    x,
const gsl_vector *    w,
const gsl_vector *    dy,
gsl_vector *    dw
[static]
 

Parameters:
node  A pointer to the gnn_affine : Affine Activation Function. node.
x  The input vector .
w  The parameter vector .
dy  The vector .
dx  The output buffer vector .
Returns:
Returns 0 on success.

Definition at line 172 of file gnn_affine.c.

int gnn_affine_dx gnn_node   node,
const gsl_vector *    x,
const gsl_vector *    w,
const gsl_vector *    dy,
gsl_vector *    dx
[static]
 

Parameters:
node  A pointer to the gnn_affine : Affine Activation Function. node.
x  The input vector .
w  The parameter vector .
dy  The vector .
dx  The output buffer vector .
Returns:
Returns 0 on success.

Definition at line 137 of file gnn_affine.c.

int gnn_affine_f gnn_node   node,
const gsl_vector *    x,
const gsl_vector *    w,
gsl_vector *    y
[static]
 

Parameters:
node  A pointer to the gnn_affine : Affine Activation Function. node.
x  The input vector .
w  The parameter vector .
y  The output buffer vector .
Returns:
Returns 0 on success.

Definition at line 102 of file gnn_affine.c.

gnn_node* gnn_affine_new int    input_size,
double    a,
double    b
 

This function creates a node of the gnn_affine type. Although the parameters and , are all equal initially, they change during training.

Parameters:
input_size  The input size .
a  The (amplitude) factors.
v  The biases .
Returns:
A pointer to a new gnn_divergence : Input Divergence. node.

Definition at line 235 of file gnn_affine.c.

gnn_node* gnn_affine_standard_new int    input_size
 

This function creates a node of the gnn_affine type. The parameters are initialized with amplitudes and biases .

Parameters:
input_size  The input size .
Returns:
A pointer to a new gnn_tanh node.

Definition at line 340 of file gnn_affine.c.


Generated on Sun Jun 13 20:51:44 2004 for libgnn Gradient Retropropagation Machine Library by doxygen1.2.18