Belle II Software development
|
Class to keep all parameters of an expert MLP for the neuro trigger. More...
#include <GRLMLP.h>
Public Member Functions | |
GRLMLP () | |
default constructor. | |
GRLMLP (std::vector< unsigned short > &nodes, unsigned short targets, const std::vector< float > &outputscale) | |
constructor to set all parameters (not weights and relevantID ranges). | |
~GRLMLP () | |
destructor, empty because we don't allocate memory anywhere. | |
bool | isTrained () const |
check if weights are default values or set by some trainer | |
unsigned | getNumberOfLayers () const |
get number of layers | |
unsigned | getNumberOfNodesLayer (unsigned iLayer) const |
get number of nodes in a layer | |
unsigned | getNumberOfWeights () const |
get number of weights from length of weights vector | |
unsigned | nWeightsCal () const |
calculate number of weights from number of nodes | |
unsigned | nBiasCal () const |
calculate number of weights from number of nodes | |
std::vector< float > | getWeights () const |
get weights vector | |
std::vector< float > | getBias () const |
get bias vector | |
void | setWeights (std::vector< float > &weights) |
set weights vector | |
void | setBias (std::vector< float > &bias) |
set bias vector | |
void | Trained (bool trained) |
check if weights are default values or set by some trainer | |
Private Member Functions | |
ClassDef (GRLMLP, 2) | |
Needed to make the ROOT object storable. | |
Private Attributes | |
std::vector< unsigned short > | m_nNodes |
Number of nodes in each layer, not including bias nodes. | |
std::vector< float > | m_weights |
Weights of the network. | |
std::vector< float > | m_bias |
bias of the network. | |
bool | m_trained |
Indicator whether the weights are just default values or have been set by some trainer (set to true when setWeights() is first called). | |
unsigned short | m_targetVars |
output variables: 1: z, 2: theta, 3: (z, theta) | |
std::vector< float > | m_outputScale |
Output[i] of the MLP is scaled from [-1, 1] to [outputScale[2i], outputScale[2i+1]]. | |
Friends | |
class | GRLNeuroTrainerModule |
Class to keep all parameters of an expert MLP for the neuro trigger.
GRLMLP | ( | ) |
default constructor.
Definition at line 14 of file GRLMLP.cc.
GRLMLP | ( | std::vector< unsigned short > & | nodes, |
unsigned short | targets, | ||
const std::vector< float > & | outputscale | ||
) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
unsigned nBiasCal | ( | ) | const |
calculate number of weights from number of nodes
Definition at line 45 of file GRLMLP.cc.
unsigned nWeightsCal | ( | ) | const |
|
inline |
|
inline |
|
inline |
|
friend |
|
private |
|
private |
|
private |
|
private |
Indicator whether the weights are just default values or have been set by some trainer (set to true when setWeights() is first called).
|
private |