Package org.moeaframework.core.fitness
Class IndicatorFitnessEvaluator
java.lang.Object
org.moeaframework.core.fitness.IndicatorFitnessEvaluator
- All Implemented Interfaces:
FitnessEvaluator
- Direct Known Subclasses:
AdditiveEpsilonIndicatorFitnessEvaluator
,HypervolumeFitnessEvaluator
Abstract class for assigning fitness based on a binary indicator. This class combines the pair-wise fitness of
each solution into an aggregate fitness within the entire population.
-
Constructor Summary
ConstructorDescriptionIndicatorFitnessEvaluator
(Problem problem) Constructs an indicator-based fitness for the specified problem. -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract double
calculateIndicator
(Solution solution1, Solution solution2) Returns the indicator value relative to the two solutions.void
evaluate
(Population population) Evaluates the fitness of solutions in the population, updating theFitness
attribute.Returns the problem.void
removeAndUpdate
(Population population, int removeIndex) After callingevaluate(Population)
, this method is used to iteratively remove solutions from the population while updating the fitness value.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.moeaframework.core.FitnessEvaluator
areLargerValuesPreferred
-
Constructor Details
-
IndicatorFitnessEvaluator
Constructs an indicator-based fitness for the specified problem.- Parameters:
problem
- the problem
-
-
Method Details
-
getProblem
Returns the problem.- Returns:
- the problem
-
evaluate
Description copied from interface:FitnessEvaluator
Evaluates the fitness of solutions in the population, updating theFitness
attribute.- Specified by:
evaluate
in interfaceFitnessEvaluator
- Parameters:
population
- the population to be evaluated
-
removeAndUpdate
After callingevaluate(Population)
, this method is used to iteratively remove solutions from the population while updating the fitness value. There must be no other modifications to the population between invocations ofevaluate(Population)
and this method other than removing solutions using this method.- Parameters:
population
- the populationremoveIndex
- the index to remove
-
calculateIndicator
Returns the indicator value relative to the two solutions.- Parameters:
solution1
- the first solutionsolution2
- the second solution- Returns:
- the indicator value relative to the two solutions
-