ITK  4.3.0
Insight Segmentation and Registration Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
itk::FRPROptimizer Class Reference

#include <itkFRPROptimizer.h>

+ Inheritance diagram for itk::FRPROptimizer:
+ Collaboration diagram for itk::FRPROptimizer:

Detailed Description

Implements Fletch-Reeves & Polak-Ribiere optimization using dBrent line search.

This optimizer needs a cost function. This optimizer needs to be able to compute partial derivatives of the cost function with respect to each parameter.

The SetStepLength determines the initial distance to step in a line direction when bounding the minimum (using bracketing triple spaced using a derivative-based search strategy).

The StepTolerance terminates optimization when the parameter values are known to be within this (scaled) distance of the local extreme.

The ValueTolerance terminates optimization when the cost function values at the current parameters and at the local extreme are likely (within a second order approximation) to be within this is tolerance.

Definition at line 49 of file itkFRPROptimizer.h.

Public Types

typedef SmartPointer< const SelfConstPointer
 
typedef CostFunctionType::Pointer CostFunctionPointer
 
typedef SingleValuedCostFunction CostFunctionType
 
typedef
SingleValuedNonLinearOptimizer::ParametersType 
ParametersType
 
typedef SmartPointer< SelfPointer
 
typedef FRPROptimizer Self
 
typedef PowellOptimizer Superclass
 
- Public Types inherited from itk::PowellOptimizer
typedef SmartPointer< const SelfConstPointer
 
typedef CostFunctionType::Pointer CostFunctionPointer
 
typedef SingleValuedCostFunction CostFunctionType
 
typedef
SingleValuedNonLinearOptimizer::ParametersType 
ParametersType
 
typedef SmartPointer< SelfPointer
 
typedef PowellOptimizer Self
 
typedef
SingleValuedNonLinearOptimizer 
Superclass
 
- Public Types inherited from itk::SingleValuedNonLinearOptimizer
typedef SmartPointer< const SelfConstPointer
 
typedef CostFunctionType::Pointer CostFunctionPointer
 
typedef SingleValuedCostFunction CostFunctionType
 
typedef
CostFunctionType::DerivativeType 
DerivativeType
 
typedef
CostFunctionType::MeasureType 
MeasureType
 
typedef Superclass::ParametersType ParametersType
 
typedef SmartPointer< SelfPointer
 
typedef
SingleValuedNonLinearOptimizer 
Self
 
typedef NonLinearOptimizer Superclass
 
- Public Types inherited from itk::NonLinearOptimizer
typedef SmartPointer< const SelfConstPointer
 
typedef Superclass::ParametersType ParametersType
 
typedef SmartPointer< SelfPointer
 
typedef Superclass::ScalesType ScalesType
 
typedef NonLinearOptimizer Self
 
typedef Optimizer Superclass
 
- Public Types inherited from itk::Optimizer
typedef SmartPointer< const SelfConstPointer
 
typedef OptimizerParameters
< double > 
ParametersType
 
typedef SmartPointer< SelfPointer
 
typedef Array< double > ScalesType
 
typedef Optimizer Self
 
typedef Object Superclass
 
- Public Types inherited from itk::Object
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef Object Self
 
typedef LightObject Superclass
 
- Public Types inherited from itk::LightObject
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef LightObject Self
 

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const char * GetNameOfClass () const
 
void SetToFletchReeves ()
 
void SetToPolakRibiere ()
 
void StartOptimization ()
 
virtual void SetUseUnitLengthGradient (bool _arg)
 
virtual bool GetUseUnitLengthGradient () const
 
- Public Member Functions inherited from itk::PowellOptimizer
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const bool & GetCatchGetValueException ()
 
virtual const unsigned int & GetCurrentIteration ()
 
virtual const unsigned int & GetCurrentLineIteration ()
 
virtual const double & GetMetricWorstPossibleValue ()
 
const std::string GetStopConditionDescription () const
 
virtual void SetCatchGetValueException (bool _arg)
 
virtual void SetMetricWorstPossibleValue (double _arg)
 
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 SetMaximumLineIteration (unsigned int _arg)
 
virtual unsigned int GetMaximumLineIteration () const
 
virtual void SetStepLength (double _arg)
 
virtual const double & GetStepLength ()
 
virtual void SetStepTolerance (double _arg)
 
virtual const double & GetStepTolerance ()
 
virtual void SetValueTolerance (double _arg)
 
virtual const double & GetValueTolerance ()
 
virtual const MeasureTypeGetCurrentCost ()
 
MeasureType GetValue () const
 
- Public Member Functions inherited from itk::SingleValuedNonLinearOptimizer
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const CostFunctionTypeGetCostFunction ()
 
MeasureType GetValue (const ParametersType &parameters) const
 
virtual void SetCostFunction (CostFunctionType *costFunction)
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from itk::PowellOptimizer
static Pointer New ()
 
- Static Public Member Functions inherited from itk::SingleValuedNonLinearOptimizer
static Pointer New ()
 
- Static Public Member Functions inherited from itk::NonLinearOptimizer
static Pointer New ()
 
- Static Public Member Functions inherited from itk::Optimizer
static Pointer New ()
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool flag)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Protected Member Functions

 FRPROptimizer ()
 
virtual void GetValueAndDerivative (ParametersType &p, double *val, ParametersType *xi)
 
virtual void LineOptimize (ParametersType *p, ParametersType &xi, double *val)
 
virtual void LineOptimize (ParametersType *p, ParametersType &xi, double *val, ParametersType &tempCoord)
 
void PrintSelf (std::ostream &os, Indent indent) const
 
virtual ~FRPROptimizer ()
 
- Protected Member Functions inherited from itk::PowellOptimizer
virtual void BracketedLineOptimize (double ax, double bx, double cx, double fa, double fb, double fc, double *extX, double *extVal)
 
virtual void BracketedLineOptimize (double ax, double bx, double cx, double fa, double fb, double fc, double *extX, double *extVal, ParametersType &tempCoord)
 
double GetLineValue (double x) const
 
double GetLineValue (double x, ParametersType &tempCoord) const
 
virtual unsigned int GetSpaceDimension ()
 
virtual bool GetStop ()
 
virtual void LineBracket (double *ax, double *bx, double *cx, double *fa, double *fb, double *fc)
 
virtual void LineBracket (double *ax, double *bx, double *cx, double *fa, double *fb, double *fc, ParametersType &tempCoord)
 
 PowellOptimizer ()
 
 PowellOptimizer (const PowellOptimizer &)
 
void PrintSelf (std::ostream &os, Indent indent) const
 
virtual void SetCurrentCost (double _arg)
 
virtual void SetCurrentIteration (unsigned int _arg)
 
void SetCurrentLinePoint (double x, double fx)
 
void SetLine (const ParametersType &origin, const vnl_vector< double > &direction)
 
void SetSpaceDimension (unsigned int dim)
 
virtual void SetStop (bool _arg)
 
void Shift (double *a, double *b, double *c, double d) const
 
void Swap (double *a, double *b) const
 
virtual ~PowellOptimizer ()
 
- Protected Member Functions inherited from itk::SingleValuedNonLinearOptimizer
void PrintSelf (std::ostream &os, Indent indent) const
 
 SingleValuedNonLinearOptimizer ()
 
virtual ~SingleValuedNonLinearOptimizer ()
 
- Protected Member Functions inherited from itk::NonLinearOptimizer
 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 Types

enum  OptimizationType {
  FletchReeves,
  PolakRibiere
}
 

Private Member Functions

 FRPROptimizer (const FRPROptimizer &)
 

Private Attributes

OptimizationType m_OptimizationType
 
bool m_UseUnitLengthGradient
 

Additional Inherited Members

- Protected Types inherited from itk::LightObject
typedef int InternalReferenceCountType
 
- Protected Attributes inherited from itk::SingleValuedNonLinearOptimizer
CostFunctionPointer m_CostFunction
 

Member Typedef Documentation

Definition at line 57 of file itkFRPROptimizer.h.

Definition at line 69 of file itkFRPROptimizer.h.

Type of the Cost Function

Definition at line 65 of file itkFRPROptimizer.h.

Definition at line 59 of file itkFRPROptimizer.h.

Definition at line 56 of file itkFRPROptimizer.h.

Standard "Self" typedef.

Definition at line 54 of file itkFRPROptimizer.h.

Definition at line 55 of file itkFRPROptimizer.h.

Member Enumeration Documentation

Enumerator:
FletchReeves 
PolakRibiere 

Definition at line 107 of file itkFRPROptimizer.h.

Constructor & Destructor Documentation

itk::FRPROptimizer::FRPROptimizer ( )
protected
virtual itk::FRPROptimizer::~FRPROptimizer ( )
protectedvirtual
itk::FRPROptimizer::FRPROptimizer ( const FRPROptimizer )
private

Member Function Documentation

virtual::itk::LightObject::Pointer itk::FRPROptimizer::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::Object.

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

Run-time type information (and related methods).

Reimplemented from itk::PowellOptimizer.

virtual bool itk::FRPROptimizer::GetUseUnitLengthGradient ( ) const
virtual

Convert gradient to a unit length vector

virtual void itk::FRPROptimizer::GetValueAndDerivative ( ParametersType p,
double *  val,
ParametersType xi 
)
protectedvirtual

Get the value of the n-dimensional cost function at this scalar step distance along the current line direction from the current line origin. Line origin and distances are set via SetLine

virtual void itk::FRPROptimizer::LineOptimize ( ParametersType p,
ParametersType xi,
double *  val 
)
protectedvirtual
virtual void itk::FRPROptimizer::LineOptimize ( ParametersType p,
ParametersType xi,
double *  val,
ParametersType tempCoord 
)
protectedvirtual
static Pointer itk::FRPROptimizer::New ( )
static

Method for creation through the object factory.

void itk::FRPROptimizer::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::Object.

void itk::FRPROptimizer::SetToFletchReeves ( )

Set it to the Fletch-Reeves optimizer

void itk::FRPROptimizer::SetToPolakRibiere ( )

Set it to the Fletch-Reeves optimizer

virtual void itk::FRPROptimizer::SetUseUnitLengthGradient ( bool  _arg)
virtual

Convert gradient to a unit length vector

void itk::FRPROptimizer::StartOptimization ( )
virtual

Start optimization.

Reimplemented from itk::Optimizer.

Member Data Documentation

OptimizationType itk::FRPROptimizer::m_OptimizationType
private

Definition at line 112 of file itkFRPROptimizer.h.

bool itk::FRPROptimizer::m_UseUnitLengthGradient
private

Definition at line 114 of file itkFRPROptimizer.h.


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