JGAP

org.jgap.audit
Interface IEvolutionMonitor

All Superinterfaces:
java.io.Serializable
All Known Implementing Classes:
ChainedMonitors, EvolutionMonitor, FitnessImprovementMonitor, TimedMonitor

public interface IEvolutionMonitor
extends java.io.Serializable

Monitors evolution and decides when to stop the evolution cycle.

Since:
3.4.4

Field Summary
static java.lang.String CVS_REVISION
          String containing the CVS revision.
static java.lang.String MONITOR_EVENT_AFTER_BULK_EVAL
           
static java.lang.String MONITOR_EVENT_AFTER_OPERATE
           
static java.lang.String MONITOR_EVENT_AFTER_SELECT
           
static java.lang.String MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES1
           
static java.lang.String MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES2
           
static java.lang.String MONITOR_EVENT_BEFORE_ADD_CHROMOSOME
           
static java.lang.String MONITOR_EVENT_BEFORE_BULK_EVAL
           
static java.lang.String MONITOR_EVENT_BEFORE_OPERATE
           
static java.lang.String MONITOR_EVENT_BEFORE_SELECT
           
static java.lang.String MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES1
           
static java.lang.String MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES2
           
static java.lang.String MONITOR_EVENT_READD_FITTEST
           
static java.lang.String MONITOR_EVENT_REMOVE_CHROMOSOME
           
 
Method Summary
 void event(java.lang.String a_monitorEvent, int a_evolutionNo, java.lang.Object[] a_information)
          Called whenever it's worth monitoring.
 PopulationHistoryIndexed getPopulations()
           
 boolean nextCycle(Population a_pop, java.util.List<java.lang.String> a_messages)
          Called after another evolution cycle has been executed.
 void start(Configuration a_config)
          Called just before the evolution starts.
 

Field Detail

CVS_REVISION

static final java.lang.String CVS_REVISION
String containing the CVS revision. Read out via reflection!

See Also:
Constant Field Values

MONITOR_EVENT_REMOVE_CHROMOSOME

static final java.lang.String MONITOR_EVENT_REMOVE_CHROMOSOME
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES1

static final java.lang.String MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES1
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES2

static final java.lang.String MONITOR_EVENT_BEFORE_UPDATE_CHROMOSOMES2
See Also:
Constant Field Values

MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES1

static final java.lang.String MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES1
See Also:
Constant Field Values

MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES2

static final java.lang.String MONITOR_EVENT_AFTER_UPDATE_CHROMOSOMES2
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_SELECT

static final java.lang.String MONITOR_EVENT_BEFORE_SELECT
See Also:
Constant Field Values

MONITOR_EVENT_AFTER_SELECT

static final java.lang.String MONITOR_EVENT_AFTER_SELECT
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_OPERATE

static final java.lang.String MONITOR_EVENT_BEFORE_OPERATE
See Also:
Constant Field Values

MONITOR_EVENT_AFTER_OPERATE

static final java.lang.String MONITOR_EVENT_AFTER_OPERATE
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_BULK_EVAL

static final java.lang.String MONITOR_EVENT_BEFORE_BULK_EVAL
See Also:
Constant Field Values

MONITOR_EVENT_AFTER_BULK_EVAL

static final java.lang.String MONITOR_EVENT_AFTER_BULK_EVAL
See Also:
Constant Field Values

MONITOR_EVENT_BEFORE_ADD_CHROMOSOME

static final java.lang.String MONITOR_EVENT_BEFORE_ADD_CHROMOSOME
See Also:
Constant Field Values

MONITOR_EVENT_READD_FITTEST

static final java.lang.String MONITOR_EVENT_READD_FITTEST
See Also:
Constant Field Values
Method Detail

start

void start(Configuration a_config)
Called just before the evolution starts. Setup your monitor here.

Parameters:
a_config - the configuration used
Since:
3.4.4

nextCycle

boolean nextCycle(Population a_pop,
                  java.util.List<java.lang.String> a_messages)
Called after another evolution cycle has been executed.

Parameters:
a_pop - the currently evolved population
a_messages - the monitor can append messages here to indicate why it asks evolution to stop
Returns:
true: continue with the evolution; false: stop evolution
Since:
3.4.4

event

void event(java.lang.String a_monitorEvent,
           int a_evolutionNo,
           java.lang.Object[] a_information)
Called whenever it's worth monitoring.

Parameters:
a_monitorEvent - see constants at top of class
a_evolutionNo - the index of the evolution round (1, 2, ...)
a_information - event-specific information
Since:
3.5

getPopulations

PopulationHistoryIndexed getPopulations()
Returns:
the gathered monitoring data
Since:
3.5

JGAP