Class Neuron
- java.lang.Object
-
- ciir.umass.edu.learning.neuralnet.Neuron
-
- Direct Known Subclasses:
ListNeuron
public class Neuron extends java.lang.Object- Author:
- vdang This class implements individual neurons in the network.
-
-
Field Summary
Fields Modifier and Type Field Description protected doubledelta_iprotected double[]deltas_jprotected java.util.List<Synapse>inLinksstatic doublelearningRatestatic doublemomentumprotected java.util.List<Synapse>outLinksprotected doubleoutputprotected java.util.List<java.lang.Double>outputsprotected TransferFunctiontfunc
-
Constructor Summary
Constructors Constructor Description Neuron()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddOutput(double output)voidclearOutputs()voidcomputeDelta(PropParameter param)Compute delta for neurons in the output layer.voidcomputeOutput()voidcomputeOutput(int i)java.util.List<Synapse>getInLinks()java.util.List<Synapse>getOutLinks()doublegetOutput()doublegetOutput(int k)voidsetOutput(double output)voidupdateDelta(PropParameter param)Update delta from neurons in the next layer (back-propagate)voidupdateWeight(PropParameter param)Update weights of incoming links.
-
-
-
Field Detail
-
momentum
public static double momentum
-
learningRate
public static double learningRate
-
tfunc
protected TransferFunction tfunc
-
output
protected double output
-
outputs
protected java.util.List<java.lang.Double> outputs
-
delta_i
protected double delta_i
-
deltas_j
protected double[] deltas_j
-
inLinks
protected java.util.List<Synapse> inLinks
-
outLinks
protected java.util.List<Synapse> outLinks
-
-
Method Detail
-
getOutput
public double getOutput()
-
getOutput
public double getOutput(int k)
-
getInLinks
public java.util.List<Synapse> getInLinks()
-
getOutLinks
public java.util.List<Synapse> getOutLinks()
-
setOutput
public void setOutput(double output)
-
addOutput
public void addOutput(double output)
-
computeOutput
public void computeOutput()
-
computeOutput
public void computeOutput(int i)
-
clearOutputs
public void clearOutputs()
-
computeDelta
public void computeDelta(PropParameter param)
Compute delta for neurons in the output layer. ONLY for neurons in the output layer.- Parameters:
targetValue-
-
updateDelta
public void updateDelta(PropParameter param)
Update delta from neurons in the next layer (back-propagate)
-
updateWeight
public void updateWeight(PropParameter param)
Update weights of incoming links.
-
-