|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.joone.engine.extenders.LearnerExtender
org.joone.engine.extenders.UpdateWeightExtender
org.joone.engine.extenders.BatchModeExtender
public class BatchModeExtender
This class implements the offline learning, that is, batch mode. Weights are updated after Monitor.getBatchSize() cycles.
| Constructor Summary | |
|---|---|
BatchModeExtender()
Creates a new instance of BatchModeExtender |
|
| Method Summary | |
|---|---|
int |
getBatchSize()
Deprecated. use monitor.getBatchSize() |
protected void |
initiateNewBatch()
Initiates a new batch (at the beginning or when the dimensions change). |
void |
postBiasUpdate(double[] currentGradientOuts)
Gives extenders a change to do some post-computing after the biases are updated. |
void |
postWeightUpdate(double[] currentPattern,
double[] currentInps)
Gives extenders a change to do some post-computing after the weights are updated. |
void |
preBiasUpdate(double[] currentGradientOuts)
Gives extenders a change to do some pre-computing before the biases are updated. |
void |
preWeightUpdate(double[] currentPattern,
double[] currentInps)
Gives extenders a change to do some pre-computing before the weights are updated. |
protected void |
resetDelta(Matrix aMatrix)
Resets delta values to zero. |
void |
setBatchSize(int aBatchSize)
Deprecated. use monitor.setBatchSize() |
boolean |
storeWeightsBiases()
Checks if the weights or biases will be stored this cycle. |
void |
updateBias(int i,
double aDelta)
Updates a bias with the calculated delta value. |
void |
updateWeight(int j,
int k,
double aDelta)
Updates a weight with the calculated delta value. |
| Methods inherited from class org.joone.engine.extenders.LearnerExtender |
|---|
getLearner, isEnabled, setEnabled, setLearner |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BatchModeExtender()
| Method Detail |
|---|
public void postBiasUpdate(double[] currentGradientOuts)
LearnerExtender
postBiasUpdate in class LearnerExtendercurrentGradientOuts - the back propagated gradients.
public void postWeightUpdate(double[] currentPattern,
double[] currentInps)
LearnerExtender
postWeightUpdate in class LearnerExtendercurrentPattern - the back propagated gradients.currentInps - the forwarded input.public void preBiasUpdate(double[] currentGradientOuts)
LearnerExtender
preBiasUpdate in class LearnerExtendercurrentGradientOuts - the back propagated gradients.
public void preWeightUpdate(double[] currentPattern,
double[] currentInps)
LearnerExtender
preWeightUpdate in class LearnerExtendercurrentPattern - the back propagated gradients.currentInps - the forwarded input.
public void updateBias(int i,
double aDelta)
UpdateWeightExtender
updateBias in class UpdateWeightExtenderi - the index of the bias to update.aDelta - the calculated delta value.
public void updateWeight(int j,
int k,
double aDelta)
UpdateWeightExtender
updateWeight in class UpdateWeightExtenderj - the input index of the weight to update.k - the output index of the weight to update.aDelta - the calculated delta value.protected void resetDelta(Matrix aMatrix)
aMatrix - the matrix for which we need to set the delta values to zero.protected void initiateNewBatch()
public void setBatchSize(int aBatchSize)
aBatchSize - the new batchsize.public int getBatchSize()
public boolean storeWeightsBiases()
UpdateWeightExtender
storeWeightsBiases in class UpdateWeightExtender
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||