/Home/aooliver/hepsoft/lcdroot/LCDRootApps/PhUtil/src/LCDNNHFSelectNoVertexGhostZpole.c File Reference

#include <math.h>

Go to the source code of this file.

Classes

struct  UT

Defines

#define Act_Logistic(sum, bias)   ( (sum+bias<10000.0) ? ( 1.0/(1.0 + exp(-sum-bias) ) ) : 0.0 )
#define NULL   (void *)0

Typedefs

typedef UT UnitType
typedef UTpUnit

Functions

int LCDNNHFSelectNoVertexGhostZpole (float *in, float *out, int init)

Variables

static UnitType Units [16]
static pUnit Sources []
static float Weights []
static UnitType Units [16]


Define Documentation

#define Act_Logistic sum,
bias   )     ( (sum+bias<10000.0) ? ( 1.0/(1.0 + exp(-sum-bias) ) ) : 0.0 )
 

Definition at line 10 of file LCDNNHFSelectNoVertexGhostZpole.c.

#define NULL   (void *)0
 

Definition at line 12 of file LCDNNHFSelectNoVertexGhostZpole.c.


Typedef Documentation

typedef struct UT * pUnit
 

typedef struct UT UnitType
 


Function Documentation

int LCDNNHFSelectNoVertexGhostZpole float *  in,
float *  out,
int  init
 

Definition at line 137 of file LCDNNHFSelectNoVertexGhostZpole.c.

References UT::act, and Units.

00138 {
00139   int member, source;
00140   float sum;
00141   enum{OK, Error, Not_Valid};
00142   pUnit unit;
00143 
00144 
00145   /* layer definition section (names & member units) */
00146 
00147   static pUnit Input[6] = {Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6}; /* members */
00148 
00149   static pUnit Hidden1[7] = {Units + 7, Units + 8, Units + 9, Units + 10, Units + 11, Units + 12, Units + 13}; /* members */
00150 
00151   static pUnit Output1[2] = {Units + 14, Units + 15}; /* members */
00152 
00153   static int Output[2] = {14, 15};
00154 
00155   for(member = 0; member < 6; member++) {
00156     Input[member]->act = in[member];
00157   }
00158 
00159   for (member = 0; member < 7; member++) {
00160     unit = Hidden1[member];
00161     sum = 0.0;
00162     for (source = 0; source < unit->NoOfSources; source++) {
00163       sum += unit->sources[source]->act
00164              * unit->weights[source];
00165     }
00166     unit->act = Act_Logistic(sum, unit->Bias);
00167   };
00168 
00169   for (member = 0; member < 2; member++) {
00170     unit = Output1[member];
00171     sum = 0.0;
00172     for (source = 0; source < unit->NoOfSources; source++) {
00173       sum += unit->sources[source]->act
00174              * unit->weights[source];
00175     }
00176     unit->act = Act_Logistic(sum, unit->Bias);
00177   };
00178 
00179   for(member = 0; member < 2; member++) {
00180     out[member] = Units[Output[member]].act;
00181   }
00182 
00183   return(OK);
00184 }


Variable Documentation

pUnit Sources[] [static]
 

Initial value:

  {
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 1, Units + 2, Units + 3, Units + 4, Units + 5, Units + 6, 
Units + 7, Units + 8, Units + 9, Units + 10, Units + 11, Units + 12, Units + 13, 
Units + 7, Units + 8, Units + 9, Units + 10, Units + 11, Units + 12, Units + 13, 

  }

Definition at line 26 of file LCDNNHFSelectNoVertexGhostZpole.c.

UnitType Units[16] [static]
 

Definition at line 54 of file LCDNNHFSelectNoVertexGhostZpole.c.

UnitType Units[16] [static]
 

Definition at line 24 of file LCDNNHFSelectNoVertexGhostZpole.c.

float Weights[] [static]
 

Initial value:

  {
-1.091470, 1.472280, -10.663780, -14.205880, -35.277870, 8.977430, 
3.353060, 2.296610, 23.082180, -11.771740, -23.037800, -1.114020, 
-1.959030, 1.007720, -71.049477, 4.672230, -27.894140, 15.685980, 
0.722460, -2.683560, 37.604359, -17.773970, -36.315941, 0.840390, 
0.919210, -0.003450, -52.938679, -12.701330, -9.339780, -9.338240, 
2.940960, 20.080669, 0.918720, -1.309030, -2.374110, -1.345020, 
-2.499760, -3.271300, -10.803810, 8.644160, -10.634920, -0.911810, 
1.486460, -2.306990, -1.243920, 2.449150, 1.102330, -3.411190, 0.346620, 
-2.256800, -1.816480, -3.744570, 2.156200, 3.470020, 1.158750, 2.578590, 

  }

Definition at line 40 of file LCDNNHFSelectNoVertexGhostZpole.c.


Generated on Tue Jul 18 18:34:05 2006 for LCDROOT by  doxygen 1.4.6