|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectclarion.nacs.ProbBPNet
Field Summary | |
protected double |
alpha
learning rate. |
protected double[] |
desiredOutputs
the desired outputs. |
protected int |
INPUT_NUM
the number of input units. |
protected double[] |
inputs
the inputs |
protected int |
OUTPUT_NUM
the number of output units. |
protected double[] |
outputs
the outputs. |
protected double[][] |
weights
the weights. |
Constructor Summary | |
ProbBPNet(int num1,
int num2,
double lr)
constructor. |
Method Summary | |
void |
backward()
Updates the weights. |
void |
forward()
Computes the actual outputs. |
double |
getOutput(int idx)
Returns a specific output. |
void |
getOutputs(double[] arr)
Returns the outputs. |
void |
initWeights()
initialization routine. |
void |
setDesiredOutputs(double[] arr)
Sets the desired outputs in terms of an array of activations. |
void |
setDesiredOutputs(int[] arr)
Sets the desired outputs. |
void |
setInputs(double[] arr)
Sets the inputs in terms of an array of activations. |
void |
setInputs(int[] arr)
Sets the inputs. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected double alpha
protected int INPUT_NUM
protected int OUTPUT_NUM
protected double[] inputs
protected double[] outputs
protected double[] desiredOutputs
protected double[][] weights
Constructor Detail |
public ProbBPNet(int num1, int num2, double lr)
num1
- the number of inputs.num2
- the number of outputs.lr
- learning rate.Method Detail |
public double getOutput(int idx)
idx
- the index to the specific output.
public void getOutputs(double[] arr)
arr
- the array to store the outputs.
public void setInputs(int[] arr)
arr
- the array used to set the inputs.public void setInputs(double[] arr)
arr
- the array used to set the inputs.public void setDesiredOutputs(int[] arr)
arr
- the array used to set the desired outputs.public void setDesiredOutputs(double[] arr)
arr
- the array used to set the desired outputs.public void forward()
public void backward()
public void initWeights()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |