Package org.moeaframework.core.indicator
Class Indicators
java.lang.Object
org.moeaframework.core.indicator.Indicators
- All Implemented Interfaces:
Function<NondominatedPopulation,
Indicators.IndicatorValues>
public class Indicators
extends Object
implements Function<NondominatedPopulation,Indicators.IndicatorValues>
Helper for evaluating multiple performance indicators, primarily for avoiding repetitive calculations that
would occur if creating each indicator separately. Normalized indicators are, by default, normalized using the
provided reference set. See
DefaultNormalizer
for ways to customize normalization.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Collection of indicator results, with values defaulting to 0d/0d if not included. -
Constructor Summary
ConstructorDescriptionIndicators
(Problem problem, NondominatedPopulation referenceSet) Constructs a new Indicators object for the given problem. -
Method Summary
Modifier and TypeMethodDescriptionstatic Indicators
all
(Problem problem, NondominatedPopulation referenceSet) Creates an instance of this class that evaluates all performance indicators.apply
(NondominatedPopulation approximationSet) applyAll
(List<NondominatedPopulation> approximationSets) Calculates the indicators for a list of approximation sets.Returns the performance indicators that will be evaluated.include
(EnumSet<StandardIndicator> indicators) Enables the evaluation of the selected indicators.include
(StandardIndicator indicator) Enables the evaluation of the given performance indicator.Enables the evaluation of the additive ε-indicator metric.Enables the evaluation of all metrics.Enables the evaluation of the contribution metric.Enables the evaluation of the generational distance metric.Enables the evaluation of the generational distance plus metric.Enables the evaluation of the hypervolume metric.Enables the evaluation of the inverted generational distance metric.Enables the evaluation of the inverted generational distance plus metric.Enables the evaluation of the maximum Pareto front error metric.Enables the evaluation of the R1 indicator.Enables the evaluation of the R2 indicator.Enables the evaluation of the R3 indicator.Enables the evaluation of the spacing metric.Enables the evaluation of all standard metrics.static Indicators
of
(Problem problem, NondominatedPopulation referenceSet) Creates a new instance of this class with no configured indicators.static Indicators
standard
(Problem problem, NondominatedPopulation referenceSet) Creates an instance of this class that evaluates all standard performance indicators.withEpsilons
(Epsilons epsilons) Sets the ε values used by the indicators.withHypervolume
(double[] referencePoint) Configures the hypervolume metric using the given reference point.withHypervolume
(double[] minimum, double[] maximum) Configures the hypervolume metric using the given minimum and maximum bounds of the Pareto set.withSubdivisions
(int subdivisions) Sets the number of subdivisions used by the R-indicators.
-
Constructor Details
-
Indicators
Constructs a new Indicators object for the given problem.- Parameters:
problem
- the problemreferenceSet
- the reference set
-
-
Method Details
-
all
Creates an instance of this class that evaluates all performance indicators.- Parameters:
problem
- the problemreferenceSet
- the reference set- Returns:
- the constructed instance
-
standard
Creates an instance of this class that evaluates all standard performance indicators. This excludes the R-indicators.- Parameters:
problem
- the problemreferenceSet
- the reference set- Returns:
- the constructed instance
-
of
Creates a new instance of this class with no configured indicators.- Parameters:
problem
- the problemreferenceSet
- the reference set- Returns:
- the constructed instance
-
apply
- Specified by:
apply
in interfaceFunction<NondominatedPopulation,
Indicators.IndicatorValues>
-
applyAll
Calculates the indicators for a list of approximation sets.- Parameters:
approximationSets
- the approximation sets- Returns:
- the indicator values
-
withEpsilons
Sets the ε values used by the indicators.- Parameters:
epsilons
- the ε values- Returns:
- a reference to this object so calls can be chained together
-
withSubdivisions
Sets the number of subdivisions used by the R-indicators.- Parameters:
subdivisions
- the number of subdivisions- Returns:
- a reference to this object so calls can be chained together
-
getSelectedIndicators
Returns the performance indicators that will be evaluated.- Returns:
- the selected performance indicators
-
include
Enables the evaluation of the given performance indicator.- Parameters:
indicator
- the indicator to enable- Returns:
- a reference to this object so calls can be chained together
-
include
Enables the evaluation of the selected indicators.- Parameters:
indicators
- the indicators to enable- Returns:
- a reference to this object so calls can be chained together
-
includeHypervolume
Enables the evaluation of the hypervolume metric.- Returns:
- a reference to this object so calls can be chained together
-
withHypervolume
Configures the hypervolume metric using the given reference point. The hypervolume is then measured between the Pareto front and this reference point.- Parameters:
referencePoint
- the reference point- Returns:
- a reference to this object so calls can be chained together
-
withHypervolume
Configures the hypervolume metric using the given minimum and maximum bounds of the Pareto set.- Parameters:
minimum
- the minimum boundsmaximum
- the maximum bounds- Returns:
- a reference to this object so calls can be chained together
-
includeGenerationalDistance
Enables the evaluation of the generational distance metric.- Returns:
- a reference to this object so calls can be chained together
-
includeGenerationalDistancePlus
Enables the evaluation of the generational distance plus metric.- Returns:
- a reference to this object so calls can be chained together
-
includeInvertedGenerationalDistance
Enables the evaluation of the inverted generational distance metric.- Returns:
- a reference to this object so calls can be chained together
-
includeInvertedGenerationalDistancePlus
Enables the evaluation of the inverted generational distance plus metric.- Returns:
- a reference to this object so calls can be chained together
-
includeAdditiveEpsilonIndicator
Enables the evaluation of the additive ε-indicator metric.- Returns:
- a reference to this object so calls can be chained together
-
includeMaximumParetoFrontError
Enables the evaluation of the maximum Pareto front error metric.- Returns:
- a reference to this object so calls can be chained together
-
includeSpacing
Enables the evaluation of the spacing metric.- Returns:
- a reference to this object so calls can be chained together
-
includeContribution
Enables the evaluation of the contribution metric.- Returns:
- a reference to this object so calls can be chained together
-
includeR1
Enables the evaluation of the R1 indicator.- Returns:
- a reference to this object so calls can be chained together
-
includeR2
Enables the evaluation of the R2 indicator.- Returns:
- a reference to this object so calls can be chained together
-
includeR3
Enables the evaluation of the R3 indicator.- Returns:
- a reference to this object so calls can be chained together
-
includeStandardMetrics
Enables the evaluation of all standard metrics. This excludes the R-indicators.- Returns:
- a reference to this object so calls can be chained together
-
includeAllMetrics
Enables the evaluation of all metrics.- Returns:
- a reference to this object so calls can be chained together
-