ITK  4.2.0
Insight Segmentation and Registration Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Attributes
itk::OnePlusOneEvolutionaryOptimizer Class Reference

#include <itkOnePlusOneEvolutionaryOptimizer.h>

+ Inheritance diagram for itk::OnePlusOneEvolutionaryOptimizer:
+ Collaboration diagram for itk::OnePlusOneEvolutionaryOptimizer:

List of all members.

Public Types

typedef SmartPointer< const SelfConstPointer
typedef CostFunctionType::Pointer CostFunctionPointer
typedef SingleValuedCostFunction CostFunctionType
typedef
Statistics::RandomVariateGeneratorBase 
NormalVariateGeneratorType
typedef SmartPointer< SelfPointer
typedef
OnePlusOneEvolutionaryOptimizer 
Self
typedef
SingleValuedNonLinearOptimizer 
Superclass
- Public Types inherited from itk::SingleValuedNonLinearOptimizer
typedef
CostFunctionType::DerivativeType 
DerivativeType
typedef
CostFunctionType::MeasureType 
MeasureType
typedef Superclass::ParametersType ParametersType
- Public Types inherited from itk::NonLinearOptimizer
typedef Superclass::ScalesType ScalesType
- Public Types inherited from itk::Optimizer
- Public Types inherited from itk::Object
- Public Types inherited from itk::LightObject

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother (void) const
virtual const bool & GetCatchGetValueException ()
virtual const unsigned int & GetCurrentIteration ()
virtual const double & GetFrobeniusNorm ()
virtual const bool & GetInitialized ()
virtual const double & GetMetricWorstPossibleValue ()
bool GetMinimize () const
virtual const char * GetNameOfClass () const
const std::string GetStopConditionDescription () const
void Initialize (double initialRadius, double grow=-1, double shrink=-1)
void MinimizeOff (void)
void MinimizeOn (void)
virtual void SetCatchGetValueException (bool _arg)
virtual void SetMetricWorstPossibleValue (double _arg)
void SetMinimize (bool v)
void SetNormalVariateGenerator (NormalVariateGeneratorType *generator)
void StartOptimization ()
void StopOptimization ()
virtual void SetMaximize (bool _arg)
virtual void MaximizeOn ()
virtual void MaximizeOff ()
virtual const bool & GetMaximize ()
virtual void SetMaximumIteration (unsigned int _arg)
virtual const unsigned int & GetMaximumIteration ()
virtual void SetGrowthFactor (double _arg)
virtual const double & GetGrowthFactor ()
virtual void SetShrinkFactor (double _arg)
virtual const double & GetShrinkFactor ()
virtual void SetInitialRadius (double _arg)
virtual const double & GetInitialRadius ()
virtual void SetEpsilon (double _arg)
virtual const double & GetEpsilon ()
virtual const MeasureTypeGetCurrentCost ()
MeasureType GetValue () const
- Public Member Functions inherited from itk::SingleValuedNonLinearOptimizer
virtual const CostFunctionTypeGetCostFunction ()
MeasureType GetValue (const ParametersType &parameters) const
virtual void SetCostFunction (CostFunctionType *costFunction)

Static Public Member Functions

static Pointer New ()

Protected Member Functions

 OnePlusOneEvolutionaryOptimizer ()
 OnePlusOneEvolutionaryOptimizer (const OnePlusOneEvolutionaryOptimizer &)
void PrintSelf (std::ostream &os, Indent indent) const
virtual ~OnePlusOneEvolutionaryOptimizer ()
- Protected Member Functions inherited from itk::SingleValuedNonLinearOptimizer
 SingleValuedNonLinearOptimizer ()
virtual ~SingleValuedNonLinearOptimizer ()
 NonLinearOptimizer ()
virtual ~NonLinearOptimizer ()
- Protected Member Functions inherited from itk::Optimizer
 Optimizer ()
virtual void SetCurrentPosition (const ParametersType &param)
virtual ~Optimizer ()
- Protected Member Functions inherited from itk::Object
 Object ()
bool PrintObservers (std::ostream &os, Indent indent) const
virtual void SetTimeStamp (const TimeStamp &time)
virtual ~Object ()
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 LightObject ()
virtual void PrintHeader (std::ostream &os, Indent indent) const
virtual void PrintTrailer (std::ostream &os, Indent indent) const
virtual ~LightObject ()

Private Attributes

bool m_CatchGetValueException
MeasureType m_CurrentCost
unsigned int m_CurrentIteration
double m_Epsilon
double m_FrobeniusNorm
double m_GrowthFactor
bool m_Initialized
double m_InitialRadius
bool m_Maximize
unsigned int m_MaximumIteration
double m_MetricWorstPossibleValue
NormalVariateGeneratorType::Pointer m_RandomGenerator
double m_ShrinkFactor
bool m_Stop
std::ostringstream m_StopConditionDescription

Additional Inherited Members

- Protected Attributes inherited from itk::SingleValuedNonLinearOptimizer
CostFunctionPointer m_CostFunction

Detailed Description

1+1 evolutionary strategy optimizer

This optimizer searches for the optimal parameters. It changes its search radius and position using the grow factor ,shrink factor, and isotropic probability function (which is a random unit normal variate generator).

This optimizer needs a cost function and a random unit normal variate generator. The cost function should return cost with new position in parameter space which will be generated by 1+1 evolutionary strategy. Users should plug-in the random unit normal variate generator using SetNormalVariateGenerator method.

The SetEpsilon method is the minimum value for the frobenius_norm of the covariance matrix. If the fnorm is smaller than this value, the optimization process will stop even before it hits the maximum iteration.

Another way to stop the optimization process is calling the StopOptimization method. At next iteration after calling it, the optimization process will stop.

This optimizing scheme was initially developed and implemented by Martin Styner, Univ. of North Carolina at Chapel Hill, and his colleagues.

For more details. refer to the following articles. "Parametric estimate of intensity inhomogeneities applied to MRI" Martin Styner, G. Gerig, Christian Brechbuehler, Gabor Szekely, IEEE TRANSACTIONS ON MEDICAL IMAGING; 19(3), pp. 153-165, 2000, (http://www.cs.unc.edu/~styner/docs/tmi00.pdf)

"Evaluation of 2D/3D bias correction with 1+1ES-optimization" Martin Styner, Prof. Dr. G. Gerig (IKT, BIWI, ETH Zuerich), TR-197 (http://www.cs.unc.edu/~styner/docs/StynerTR97.pdf)

See also:
NormalVariateGenerator

Definition at line 70 of file itkOnePlusOneEvolutionaryOptimizer.h.


Member Typedef Documentation

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 78 of file itkOnePlusOneEvolutionaryOptimizer.h.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 88 of file itkOnePlusOneEvolutionaryOptimizer.h.

Type of the Cost Function

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 84 of file itkOnePlusOneEvolutionaryOptimizer.h.

Normal random variate generator type.

Definition at line 91 of file itkOnePlusOneEvolutionaryOptimizer.h.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 77 of file itkOnePlusOneEvolutionaryOptimizer.h.

Standard "Self" typedef.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 75 of file itkOnePlusOneEvolutionaryOptimizer.h.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

Definition at line 76 of file itkOnePlusOneEvolutionaryOptimizer.h.


Constructor & Destructor Documentation

itk::OnePlusOneEvolutionaryOptimizer::OnePlusOneEvolutionaryOptimizer ( )
protected
itk::OnePlusOneEvolutionaryOptimizer::OnePlusOneEvolutionaryOptimizer ( const OnePlusOneEvolutionaryOptimizer )
protected
virtual itk::OnePlusOneEvolutionaryOptimizer::~OnePlusOneEvolutionaryOptimizer ( )
protectedvirtual

Member Function Documentation

virtual::itk::LightObject::Pointer itk::OnePlusOneEvolutionaryOptimizer::CreateAnother ( void  ) const
virtual

Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

virtual const bool& itk::OnePlusOneEvolutionaryOptimizer::GetCatchGetValueException ( )
virtual
virtual const MeasureType& itk::OnePlusOneEvolutionaryOptimizer::GetCurrentCost ( )
virtual

Return Current Value

virtual const unsigned int& itk::OnePlusOneEvolutionaryOptimizer::GetCurrentIteration ( )
virtual

Return Current Iteration

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetEpsilon ( )
virtual

Set/Get the minimal size of search radius (frobenius_norm of covariance matrix).

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetFrobeniusNorm ( )
virtual

Get the current Frobenius norm of covariance matrix

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetGrowthFactor ( )
virtual

Set/Get the search radius grow factor in parameter space.

virtual const bool& itk::OnePlusOneEvolutionaryOptimizer::GetInitialized ( )
virtual

Return if optimizer has been initialized

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetInitialRadius ( )
virtual

Set/Get initial search radius in parameter space

virtual const bool& itk::OnePlusOneEvolutionaryOptimizer::GetMaximize ( )
virtual

Set if the Optimizer should Maximize the metric

virtual const unsigned int& itk::OnePlusOneEvolutionaryOptimizer::GetMaximumIteration ( )
virtual

Set/Get maximum iteration limit.

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetMetricWorstPossibleValue ( )
virtual
bool itk::OnePlusOneEvolutionaryOptimizer::GetMinimize ( ) const
inline

Definition at line 99 of file itkOnePlusOneEvolutionaryOptimizer.h.

virtual const char* itk::OnePlusOneEvolutionaryOptimizer::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from itk::SingleValuedNonLinearOptimizer.

virtual const double& itk::OnePlusOneEvolutionaryOptimizer::GetShrinkFactor ( )
virtual

Set/Get the search radius shrink factor.

const std::string itk::OnePlusOneEvolutionaryOptimizer::GetStopConditionDescription ( ) const
virtual

Get the reason for termination

Reimplemented from itk::Optimizer.

MeasureType itk::OnePlusOneEvolutionaryOptimizer::GetValue ( ) const
inline

Return Current Value

Definition at line 149 of file itkOnePlusOneEvolutionaryOptimizer.h.

void itk::OnePlusOneEvolutionaryOptimizer::Initialize ( double  initialRadius,
double  grow = -1,
double  shrink = -1 
)

Initializes the optimizer. Before running this optimizer, this function should have been called.

initialRadius: search radius in parameter space grow: search radius grow factor shrink: searhc radius shrink factor

virtual void itk::OnePlusOneEvolutionaryOptimizer::MaximizeOff ( )
virtual

Set if the Optimizer should Maximize the metric

virtual void itk::OnePlusOneEvolutionaryOptimizer::MaximizeOn ( )
virtual

Set if the Optimizer should Maximize the metric

void itk::OnePlusOneEvolutionaryOptimizer::MinimizeOff ( void  )
inline

Definition at line 105 of file itkOnePlusOneEvolutionaryOptimizer.h.

void itk::OnePlusOneEvolutionaryOptimizer::MinimizeOn ( void  )
inline

Definition at line 103 of file itkOnePlusOneEvolutionaryOptimizer.h.

static Pointer itk::OnePlusOneEvolutionaryOptimizer::New ( )
static

Method for creation through the object factory.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

void itk::OnePlusOneEvolutionaryOptimizer::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
protectedvirtual

Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from itk::SingleValuedNonLinearOptimizer.

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetCatchGetValueException ( bool  _arg)
virtual
virtual void itk::OnePlusOneEvolutionaryOptimizer::SetEpsilon ( double  _arg)
virtual

Set/Get the minimal size of search radius (frobenius_norm of covariance matrix).

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetGrowthFactor ( double  _arg)
virtual

Set/Get the search radius grow factor in parameter space.

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetInitialRadius ( double  _arg)
virtual

Set/Get initial search radius in parameter space

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetMaximize ( bool  _arg)
virtual

Set if the Optimizer should Maximize the metric

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetMaximumIteration ( unsigned int  _arg)
virtual

Set/Get maximum iteration limit.

virtual void itk::OnePlusOneEvolutionaryOptimizer::SetMetricWorstPossibleValue ( double  _arg)
virtual
void itk::OnePlusOneEvolutionaryOptimizer::SetMinimize ( bool  v)
inline

Definition at line 101 of file itkOnePlusOneEvolutionaryOptimizer.h.

void itk::OnePlusOneEvolutionaryOptimizer::SetNormalVariateGenerator ( NormalVariateGeneratorType generator)
virtual void itk::OnePlusOneEvolutionaryOptimizer::SetShrinkFactor ( double  _arg)
virtual

Set/Get the search radius shrink factor.

void itk::OnePlusOneEvolutionaryOptimizer::StartOptimization ( )
virtual

Start optimization. Optimization will stop when it meets either of two termination conditions, the maximum iteration limit or epsilon (minimal search radius)

Reimplemented from itk::Optimizer.

void itk::OnePlusOneEvolutionaryOptimizer::StopOptimization ( )
inline

when users call StartOptimization, this value will be set false. By calling StopOptimization, this flag will be set true, and optimization will stop at the next iteration.

Definition at line 166 of file itkOnePlusOneEvolutionaryOptimizer.h.


Member Data Documentation

bool itk::OnePlusOneEvolutionaryOptimizer::m_CatchGetValueException
private

Definition at line 194 of file itkOnePlusOneEvolutionaryOptimizer.h.

MeasureType itk::OnePlusOneEvolutionaryOptimizer::m_CurrentCost
private

Internal storage for the value type / used as a cache

Definition at line 217 of file itkOnePlusOneEvolutionaryOptimizer.h.

unsigned int itk::OnePlusOneEvolutionaryOptimizer::m_CurrentIteration
private

Current iteration

Definition at line 192 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_Epsilon
private

The minimal size of search radius (frobenius_norm of covariance matrix).

Definition at line 202 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_FrobeniusNorm
private

Cache variable for reporting the Frobenius Norm

Definition at line 230 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_GrowthFactor
private

Search radius growth factor in parameter space.

Definition at line 208 of file itkOnePlusOneEvolutionaryOptimizer.h.

bool itk::OnePlusOneEvolutionaryOptimizer::m_Initialized
private

Flag tells if the optimizer was initialized using Initialize function.

Definition at line 214 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_InitialRadius
private

Initial search radius in parameter space.

Definition at line 205 of file itkOnePlusOneEvolutionaryOptimizer.h.

bool itk::OnePlusOneEvolutionaryOptimizer::m_Maximize
private

Set if the Metric should be maximized: Default = False

Definition at line 198 of file itkOnePlusOneEvolutionaryOptimizer.h.

unsigned int itk::OnePlusOneEvolutionaryOptimizer::m_MaximumIteration
private

Maximum iteration limit.

Definition at line 189 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_MetricWorstPossibleValue
private

Definition at line 195 of file itkOnePlusOneEvolutionaryOptimizer.h.

NormalVariateGeneratorType::Pointer itk::OnePlusOneEvolutionaryOptimizer::m_RandomGenerator
private

Smart pointer to the normal random variate generator.

Definition at line 186 of file itkOnePlusOneEvolutionaryOptimizer.h.

double itk::OnePlusOneEvolutionaryOptimizer::m_ShrinkFactor
private

Search radius shrink factor in parameter space,

Definition at line 211 of file itkOnePlusOneEvolutionaryOptimizer.h.

bool itk::OnePlusOneEvolutionaryOptimizer::m_Stop
private

This is user-settable flag to stop optimization. when users call StartOptimization, this value will be set false. By calling StopOptimization, this flag will be set true, and optimization will stop at the next iteration.

Definition at line 223 of file itkOnePlusOneEvolutionaryOptimizer.h.

std::ostringstream itk::OnePlusOneEvolutionaryOptimizer::m_StopConditionDescription
private

Stop description

Definition at line 226 of file itkOnePlusOneEvolutionaryOptimizer.h.


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