|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectweka.classifiers.functions.neural.NeuralConnection
weka.classifiers.functions.neural.NeuralNode
public class NeuralNode
This class is used to represent a node in the neuralnet.
| Field Summary |
|---|
| Fields inherited from class weka.classifiers.functions.neural.NeuralConnection |
|---|
CONNECTED, INPUT, OUTPUT, PURE_INPUT, PURE_OUTPUT, UNCONNECTED |
| Constructor Summary | |
|---|---|
NeuralNode(java.lang.String id,
java.util.Random r,
NeuralMethod m)
|
|
| Method Summary | |
|---|---|
double |
errorValue(boolean calculate)
Call this to get the error value of this unit. |
double[] |
getChangeInWeights()
call this function to get the chnage in weights array. |
NeuralMethod |
getMethod()
|
java.lang.String |
getRevision()
Returns the revision string. |
double[] |
getWeights()
call this function to get the weights array. |
double |
outputValue(boolean calculate)
Call this to get the output value of this unit. |
void |
removeAllInputs()
This function will remove all the inputs to this unit. |
void |
reset()
Call this to reset the value and error for this unit, ready for the next run. |
void |
restoreWeights()
Call this to have the connection restore from the saved weights. |
void |
saveWeights()
Call this to have the connection save the current weights. |
void |
setMethod(NeuralMethod m)
Set how this node should operate (note that the neural method has no internal state, so the same object can be used by any number of nodes. |
void |
updateWeights(double l,
double m)
Call this function to update the weight values at this unit. |
double |
weightValue(int n)
Call this to get the weight value on a particular connection. |
| Methods inherited from class weka.classifiers.functions.neural.NeuralConnection |
|---|
connect, disconnect, drawHighlight, drawInputLines, drawNode, drawOutputLines, getId, getInputNums, getInputs, getNumInputs, getNumOutputs, getOutputNums, getOutputs, getType, getX, getY, onUnit, removeAllOutputs, setType, setX, setY |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public NeuralNode(java.lang.String id,
java.util.Random r,
NeuralMethod m)
id - The string name for this node (used to id this node).r - A random number generator used to generate initial weights.m - The methods this node should use to update.| Method Detail |
|---|
public void setMethod(NeuralMethod m)
m - The new method.public NeuralMethod getMethod()
public double outputValue(boolean calculate)
outputValue in class NeuralConnectioncalculate - True if the value should be calculated if it hasn't been
already.
public double errorValue(boolean calculate)
errorValue in class NeuralConnectioncalculate - True if the value should be calculated if it hasn't been
already.
public void reset()
reset in class NeuralConnectionpublic void saveWeights()
saveWeights in class NeuralConnectionpublic void restoreWeights()
restoreWeights in class NeuralConnectionpublic double weightValue(int n)
weightValue in class NeuralConnectionn - The connection number to get the weight for, -1 if The threshold
weight should be returned.
public double[] getWeights()
public double[] getChangeInWeights()
public void updateWeights(double l,
double m)
updateWeights in class NeuralConnectionl - The learning rate to use.m - The momentum to use.public void removeAllInputs()
removeAllInputs in class NeuralConnectionpublic java.lang.String getRevision()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||