shark::IndicatorBasedMOCMA< Indicator > Class Template Reference

Implements the generational MO-CMA-ES. More...

#include <shark/Algorithms/DirectSearch/MOCMA.h>

+ Inheritance diagram for shark::IndicatorBasedMOCMA< Indicator >:

Public Types

enum  NotionOfSuccess { IndividualBased, PopulationBased }
 
- Public Types inherited from shark::AbstractMultiObjectiveOptimizer< RealVector >
typedef super::SearchPointType SearchPointType
 
typedef super::SolutionType SolutionType
 
typedef super::ObjectiveFunctionType ObjectiveFunctionType
 
- Public Types inherited from shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >
enum  Feature
 Models features that the optimizer requires from the objective function. More...
 
typedef RealVector SearchPointType
 
typedef RealVector ResultType
 
typedef std::vector< ResultSet< RealVector, RealVector > > SolutionType
 
typedef AbstractObjectiveFunction< RealVector, ResultTypeObjectiveFunctionType
 
typedef TypedFlags< FeatureFeatures
 
typedef TypedFeatureNotAvailableException< FeatureFeatureNotAvailableException
 

Public Member Functions

 IndicatorBasedMOCMA (DefaultRngType &rng=Rng::globalRng)
 
std::string name () const
 Returns the name of the algorithm. More...
 
std::size_t mu () const
 
std::size_t & mu ()
 
double initialSigma () const
 
double & initialSigma ()
 
NotionOfSuccess notionOfSuccess () const
 
NotionOfSuccessnotionOfSuccess ()
 
void read (InArchive &archive)
 Read the component from the supplied archive. More...
 
void write (OutArchive &archive) const
 Write the component to the supplied archive. More...
 
void init (ObjectiveFunctionType &function)
 Initializes the optimizer for the supplied objective function. More...
 
void init (ObjectiveFunctionType &function, std::vector< SearchPointType > const &initialSearchPoints)
 Initializes the algorithm for the supplied objective function. More...
 
void step (ObjectiveFunctionType const &function)
 Executes one iteration of the algorithm. More...
 
- Public Member Functions inherited from shark::AbstractMultiObjectiveOptimizer< RealVector >
virtual ~AbstractMultiObjectiveOptimizer ()
 Virtual empty d'tor. More...
 
const SolutionTypesolution () const
 Accesses the current approximation of the Pareto-set and -front, respectively. More...
 
- Public Member Functions inherited from shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >
const Featuresfeatures () const
 
virtual void updateFeatures ()
 
bool requiresValue () const
 
bool requiresFirstDerivative () const
 
bool requiresSecondDerivative () const
 
bool canSolveConstrained () const
 
bool requiresClosestFeasible () const
 
virtual ~AbstractOptimizer ()
 Empty virtual d'tor. More...
 
- Public Member Functions inherited from shark::INameable
virtual ~INameable ()
 
- Public Member Functions inherited from shark::ISerializable
virtual ~ISerializable ()
 Virtual d'tor. More...
 
void load (InArchive &archive, unsigned int version)
 Versioned loading of components, calls read(...). More...
 
void save (OutArchive &archive, unsigned int version) const
 Versioned storing of components, calls write(...). More...
 
 BOOST_SERIALIZATION_SPLIT_MEMBER ()
 

Protected Types

typedef CMAIndividual< RealVector > IndividualType
 The individual type of the SteadyState-MOCMA. More...
 

Protected Member Functions

void doInit (std::vector< SearchPointType > const &initialSearchPoints, std::vector< ResultType > const &functionValues, std::size_t mu, double initialSigma)
 
std::vector< IndividualTypegenerateOffspring () const
 
void updatePopulation (std::vector< IndividualType > const &offspringVec)
 
- Protected Member Functions inherited from shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >
void checkFeatures (ObjectiveFunctionType const &objectiveFunction)
 Convenience function that checks whether the features of the supplied objective function match with the required features of the optimizer. More...
 

Protected Attributes

std::vector< IndividualTypem_parents
 Population of size \(\mu + 1\). More...
 
- Protected Attributes inherited from shark::AbstractMultiObjectiveOptimizer< RealVector >
SolutionType m_best
 The current Pareto-set/-front. More...
 
- Protected Attributes inherited from shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >
Features m_features
 

Detailed Description

template<typename Indicator = HypervolumeIndicator>
class shark::IndicatorBasedMOCMA< Indicator >

Implements the generational MO-CMA-ES.

Please see the following papers for further reference:

  • Igel, Suttorp and Hansen. Steady-state Selection and Efficient Covariance Matrix Update in the Multi-Objective CMA-ES.
  • Voß, Hansen and Igel. Improved Step Size Adaptation for the MO-CMA-ES.

Definition at line 58 of file MOCMA.h.

Member Typedef Documentation

§ IndividualType

template<typename Indicator = HypervolumeIndicator>
typedef CMAIndividual<RealVector> shark::IndicatorBasedMOCMA< Indicator >::IndividualType
protected

The individual type of the SteadyState-MOCMA.

Definition at line 165 of file MOCMA.h.

Member Enumeration Documentation

§ NotionOfSuccess

template<typename Indicator = HypervolumeIndicator>
enum shark::IndicatorBasedMOCMA::NotionOfSuccess
Enumerator
IndividualBased 
PopulationBased 

Definition at line 60 of file MOCMA.h.

Constructor & Destructor Documentation

§ IndicatorBasedMOCMA()

Member Function Documentation

§ doInit()

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::doInit ( std::vector< SearchPointType > const &  initialSearchPoints,
std::vector< ResultType > const &  functionValues,
std::size_t  mu,
double  initialSigma 
)
inlineprotected

§ generateOffspring()

template<typename Indicator = HypervolumeIndicator>
std::vector<IndividualType> shark::IndicatorBasedMOCMA< Indicator >::generateOffspring ( ) const
inlineprotected

§ init() [1/2]

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::init ( ObjectiveFunctionType function)
inlinevirtual

Initializes the optimizer for the supplied objective function.

Tries to sample an initial starting point. If the function does not implement this feature, an exception is thrown. Otherwise, the call is dispatched to the pure-virtual function.

Parameters
functionThe function to be initialized for.
Exceptions
Exceptionif the function does not feature the proposal of starting points.

Reimplemented from shark::AbstractMultiObjectiveOptimizer< RealVector >.

Definition at line 122 of file MOCMA.h.

References shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >::checkFeatures(), shark::IndicatorBasedMOCMA< Indicator >::mu(), and SHARKEXCEPTION.

Referenced by main().

§ init() [2/2]

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::init ( ObjectiveFunctionType function,
std::vector< SearchPointType > const &  initialSearchPoints 
)
inlinevirtual

Initializes the algorithm for the supplied objective function.

Parameters
[in]functionThe objective function.
[in]initialSearchPointsA set of intiial search points.

Implements shark::AbstractMultiObjectiveOptimizer< RealVector >.

Definition at line 138 of file MOCMA.h.

References shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >::checkFeatures(), shark::IndicatorBasedMOCMA< Indicator >::doInit(), shark::IndicatorBasedMOCMA< Indicator >::initialSigma(), shark::IndicatorBasedMOCMA< Indicator >::mu(), and SHARKEXCEPTION.

§ initialSigma() [1/2]

template<typename Indicator = HypervolumeIndicator>
double shark::IndicatorBasedMOCMA< Indicator >::initialSigma ( ) const
inline

§ initialSigma() [2/2]

template<typename Indicator = HypervolumeIndicator>
double& shark::IndicatorBasedMOCMA< Indicator >::initialSigma ( )
inline

Definition at line 91 of file MOCMA.h.

§ mu() [1/2]

§ mu() [2/2]

template<typename Indicator = HypervolumeIndicator>
std::size_t& shark::IndicatorBasedMOCMA< Indicator >::mu ( )
inline

Definition at line 84 of file MOCMA.h.

§ name()

template<typename Indicator = HypervolumeIndicator>
std::string shark::IndicatorBasedMOCMA< Indicator >::name ( ) const
inlinevirtual

Returns the name of the algorithm.

Reimplemented from shark::INameable.

Definition at line 77 of file MOCMA.h.

§ notionOfSuccess() [1/2]

template<typename Indicator = HypervolumeIndicator>
NotionOfSuccess shark::IndicatorBasedMOCMA< Indicator >::notionOfSuccess ( ) const
inline

§ notionOfSuccess() [2/2]

template<typename Indicator = HypervolumeIndicator>
NotionOfSuccess& shark::IndicatorBasedMOCMA< Indicator >::notionOfSuccess ( )
inline

Definition at line 98 of file MOCMA.h.

§ read()

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::read ( InArchive archive)
inlinevirtual

Read the component from the supplied archive.

Parameters
[in,out]archiveThe archive to read from.

Reimplemented from shark::ISerializable.

Definition at line 101 of file MOCMA.h.

References shark::AbstractMultiObjectiveOptimizer< RealVector >::m_best, and shark::IndicatorBasedMOCMA< Indicator >::m_parents.

§ step()

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::step ( ObjectiveFunctionType const &  function)
inlinevirtual

Executes one iteration of the algorithm.

Parameters
[in]functionThe function to iterate upon.

Implements shark::AbstractOptimizer< RealVector, RealVector, std::vector< ResultSet< RealVector, RealVector > > >.

Definition at line 157 of file MOCMA.h.

References shark::IndicatorBasedMOCMA< Indicator >::generateOffspring(), and shark::IndicatorBasedMOCMA< Indicator >::updatePopulation().

Referenced by main().

§ updatePopulation()

§ write()

template<typename Indicator = HypervolumeIndicator>
void shark::IndicatorBasedMOCMA< Indicator >::write ( OutArchive archive) const
inlinevirtual

Write the component to the supplied archive.

Parameters
[in,out]archiveThe archive to write to.

Reimplemented from shark::ISerializable.

Definition at line 111 of file MOCMA.h.

References shark::AbstractMultiObjectiveOptimizer< RealVector >::m_best, and shark::IndicatorBasedMOCMA< Indicator >::m_parents.

Member Data Documentation

§ m_parents


The documentation for this class was generated from the following file: