|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.yccheok.numrecognition.NumberNeuralNetworkTrainer
public class NumberNeuralNetworkTrainer
This is the neural network used to perform training.
| Field Summary | |
|---|---|
private NumberImageFeatureFactory |
featureFactory
Feature factory for this neural network. |
private org.joone.engine.SigmoidLayer |
hidden
The hidden layer of neurons. |
private org.joone.engine.SigmoidLayer |
input
The input layer of neurons. |
private org.joone.engine.Monitor |
monitor
Monitor. |
private org.joone.engine.SigmoidLayer |
output
The output layer of neurons. |
private org.joone.engine.FullSynapse |
t1
FullSynapse. |
private org.joone.engine.FullSynapse |
t2
Full Synapse. |
private org.joone.engine.learning.TeachingSynapse |
trainer
Used to train the neural network. |
| Constructor Summary | |
|---|---|
NumberNeuralNetworkTrainer(NumberImageFeatureFactory featureFactory,
NeuralNetworkParameter neuralNetworkParameter)
Creates a new instance of NumberNeuralNetworkTrainer with specified feature factory and feature parameter. |
|
| Method Summary | |
|---|---|
void |
cicleTerminated(org.joone.engine.NeuralNetEvent e)
Please refer to JOONE doc. |
void |
errorChanged(org.joone.engine.NeuralNetEvent e)
Please refer to JOONE doc. |
int |
GenerateTraingDataFile(NumberCategory[] numberCategory,
java.lang.String trainingDataFileName)
Generate the training data file. |
int |
getHiddenRows()
Returns number of hidden neurons. |
void |
netStarted(org.joone.engine.NeuralNetEvent e)
Please refer to JOONE doc. |
void |
netStopped(org.joone.engine.NeuralNetEvent e)
Please refer to JOONE doc. |
void |
netStoppedError(org.joone.engine.NeuralNetEvent e,
java.lang.String error)
Please refer to JOONE doc. |
boolean |
saveNeuralNetwork(java.lang.String fileName)
Save the neural network. |
void |
train(NumberCategory[] numberCategory,
java.lang.String errorOutputFile,
int totCicles)
Train the neural network. |
void |
train(java.lang.String inputFile,
java.lang.String errorOutputFile,
int numOfInputRow,
int numOfPattern,
int totCicles)
Train the neural network. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private org.joone.engine.SigmoidLayer input
private org.joone.engine.SigmoidLayer hidden
private org.joone.engine.SigmoidLayer output
private org.joone.engine.learning.TeachingSynapse trainer
private org.joone.engine.FullSynapse t1
private org.joone.engine.FullSynapse t2
private org.joone.engine.Monitor monitor
private NumberImageFeatureFactory featureFactory
| Constructor Detail |
|---|
public NumberNeuralNetworkTrainer(NumberImageFeatureFactory featureFactory,
NeuralNetworkParameter neuralNetworkParameter)
featureFactory - Feature factory.neuralNetworkParameter - Neural network parameter.| Method Detail |
|---|
public void train(NumberCategory[] numberCategory,
java.lang.String errorOutputFile,
int totCicles)
numberCategory - Array of number category.errorOutputFile - File to be written to for the error rate information during training.totCicles - Total iterations during training.
public int GenerateTraingDataFile(NumberCategory[] numberCategory,
java.lang.String trainingDataFileName)
numberCategory - Array of number category.trainingDataFileName - File name of the training file to be generated.
public void train(java.lang.String inputFile,
java.lang.String errorOutputFile,
int numOfInputRow,
int numOfPattern,
int totCicles)
inputFile - Training data file name.errorOutputFile - File to be written to for the error rate information during training.numOfInputRow - Size per training pattern. This will determine the size of input
neurons.numOfPattern - Number of patterns. This is the number of lines of the training data
file.totCicles - Total iterations during training.public void netStopped(org.joone.engine.NeuralNetEvent e)
netStopped in interface org.joone.engine.NeuralNetListenere - Please refer to JOONE doc.public void cicleTerminated(org.joone.engine.NeuralNetEvent e)
cicleTerminated in interface org.joone.engine.NeuralNetListenere - Please refer to JOONE doc.public void netStarted(org.joone.engine.NeuralNetEvent e)
netStarted in interface org.joone.engine.NeuralNetListenere - Please refer to JOONE doc.public void errorChanged(org.joone.engine.NeuralNetEvent e)
errorChanged in interface org.joone.engine.NeuralNetListenere - Please refer to JOONE doc.
public void netStoppedError(org.joone.engine.NeuralNetEvent e,
java.lang.String error)
netStoppedError in interface org.joone.engine.NeuralNetListenere - Please refer to JOONE documentation.error - Please refer to JOONE documentation.public boolean saveNeuralNetwork(java.lang.String fileName)
fileName - File name to be saved into.
public int getHiddenRows()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||