go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxQuasiNewtonLBFGS.h
Go to the documentation of this file.
1 /*======================================================================
2 
3  This file is part of the elastix software.
4 
5  Copyright (c) University Medical Center Utrecht. All rights reserved.
6  See src/CopyrightElastix.txt or http://elastix.isi.uu.nl/legal.php for
7  details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notices for more information.
12 
13 ======================================================================*/
14 
15 #ifndef __elxQuasiNewtonLBFGS_h
16 #define __elxQuasiNewtonLBFGS_h
17 
20 #include "elxIncludes.h"
21 
22 namespace elastix
23 {
24 using namespace itk;
25 
26 
86  template <class TElastix>
88  public
90  public
91  OptimizerBase<TElastix>
92  {
93  public:
94 
99  typedef SmartPointer<Self> Pointer;
100  typedef SmartPointer<const Self> ConstPointer;
101 
103  itkNewMacro( Self );
104 
107 
112  elxClassNameMacro( "QuasiNewtonLBFGS" );
113 
116  typedef Superclass1::CostFunctionPointer CostFunctionPointer;
121 
130 
134  typedef ReceptorMemberCommand<Self> EventPassThroughType;
135  typedef typename EventPassThroughType::Pointer EventPassThroughPointer;
136 
139  virtual void StartOptimization(void);
140 
143  virtual void BeforeRegistration(void);
144  virtual void BeforeEachResolution(void);
145  virtual void AfterEachResolution(void);
146  virtual void AfterEachIteration(void);
147  virtual void AfterRegistration(void);
148 
149  itkGetConstMacro(StartLineSearch, bool);
150 
151 
152  protected:
153 
155  virtual ~QuasiNewtonLBFGS() {};
156 
157  LineOptimizerPointer m_LineOptimizer;
158 
160  virtual std::string GetLineSearchStopCondition(void) const;
161 
164  virtual std::string DeterminePhase(void) const;
165 
169  virtual bool TestConvergence( bool firstLineSearchDone );
170 
175  virtual void LineSearch(
176  const ParametersType searchDir,
177  double & step,
178  ParametersType & x,
179  MeasureType & f,
180  DerivativeType & g );
181 
182  private:
183 
184  QuasiNewtonLBFGS( const Self& ); // purposely not implemented
185  void operator=( const Self& ); // purposely not implemented
186 
187  void InvokeIterationEvent(const EventObject & event);
188 
195 
196  }; // end class QuasiNewtonLBFGS
197 
198 
199 } // end namespace elastix
200 
201 #ifndef ITK_MANUAL_INSTANTIATION
202 #include "elxQuasiNewtonLBFGS.hxx"
203 #endif
204 
205 #endif // end #ifndef __elxQuasiNewtonLBFGS_h
206 
Superclass::RegistrationPointer RegistrationPointer
Superclass::ParametersType ParametersType
MoreThuenteLineSearchOptimizer LineOptimizerType
#define elxClassNameMacro(_name)
Definition: elxMacro.h:254
Superclass::DerivativeType DerivativeType
ITK version of the lbfgs algorithm ...
This class is the elastix base class for all Optimizers.
Superclass::CostFunctionType CostFunctionType
Superclass2::RegistrationType RegistrationType
Superclass::ElastixType ElastixType
Superclass::ConfigurationPointer ConfigurationPointer
ITK version of the MoreThuente line search algorithm.
Superclass2::ElastixPointer ElastixPointer
Superclass::ElastixPointer ElastixPointer
OptimizerBase< TElastix > Superclass2
Superclass::ConfigurationType ConfigurationType
Superclass2::ConfigurationPointer ConfigurationPointer
Superclass1::ScalesType ScalesType
EventPassThroughPointer m_EventPasser
Superclass2::ConfigurationType ConfigurationType
Superclass1::CostFunctionPointer CostFunctionPointer
Superclass1::CostFunctionType CostFunctionType
Superclass1::ParametersType ParametersType
Superclass2::ITKBaseType ITKBaseType
itk::Optimizer ITKBaseType
SmartPointer< Self > Pointer
Superclass2::RegistrationPointer RegistrationPointer
Superclass1::StopConditionType StopConditionType
An optimizer based on the itk::QuasiNewtonLBFGSOptimizer.
QuasiNewtonLBFGSOptimizer Superclass1
ReceptorMemberCommand< Self > EventPassThroughType
SmartPointer< const Self > ConstPointer
Superclass1::DerivativeType DerivativeType
Superclass::RegistrationType RegistrationType
EventPassThroughType::Pointer EventPassThroughPointer
LineOptimizerType::Pointer LineOptimizerPointer
Superclass2::ElastixType ElastixType


Generated on 06-12-2013 for elastix by doxygen 1.8.5 elastix logo