public class NetReporter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected Individual |
best
The overall best individual.
|
protected double |
bestFitness
Fitness value of the overall best net.
|
protected int |
bestRun
Run where overall best net emerged.
|
protected java.lang.String |
nameBase
File name base string, for saving winner networks.
|
protected java.io.PrintWriter |
printOut
Output where to write the result messages.
|
protected int |
runCount
The number of completed runs.
|
Constructor and Description |
---|
NetReporter(java.io.PrintWriter printOut,
java.lang.String nameBase)
Constructs the stat module.
|
Modifier and Type | Method and Description |
---|---|
void |
doStatistics()
Does stats after end of run.
|
void |
doStatistics(Population population)
Does population statistics, records the best individual of the run.
|
Individual |
getBestIndividual()
Returns the best individual of the current run so far.
|
java.lang.String |
netErrorString(NeuralNet net,
PatternSet patterns)
Prints some error measures for net and patterns.
|
void |
reportEnd()
Print global stats after end of evolution.
|
protected java.io.PrintWriter printOut
protected java.lang.String nameBase
protected int runCount
protected Individual best
protected double bestFitness
protected int bestRun
public NetReporter(java.io.PrintWriter printOut, java.lang.String nameBase)
printOut
- the printer for outputnameBase
- the basic name for a network filepublic void doStatistics(Population population)
population
- the populationpublic void doStatistics()
public Individual getBestIndividual()
public void reportEnd()
public java.lang.String netErrorString(NeuralNet net, PatternSet patterns)
net
- a networkpatterns
- some patterns