go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkAdvancedCombinationTransform.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 #ifndef __itkAdvancedCombinationTransform_h
15 #define __itkAdvancedCombinationTransform_h
16 
17 #include "itkAdvancedTransform.h"
18 #include "itkExceptionObject.h"
19 
20 namespace itk
21 {
22 
51 template< typename TScalarType, unsigned int NDimensions = 3 >
53  public AdvancedTransform< TScalarType, NDimensions, NDimensions >
54 {
55 public:
56 
59  typedef AdvancedTransform< TScalarType,
60  NDimensions, NDimensions > Superclass;
61  typedef SmartPointer< Self > Pointer;
62  typedef SmartPointer< const Self > ConstPointer;
63 
65  itkNewMacro( Self );
66 
69 
71  itkStaticConstMacro( SpaceDimension, unsigned int, NDimensions );
72 
94  typedef typename Superclass::TransformCategoryType TransformCategoryType;
95 
98  typedef typename TransformType::Pointer TransformTypePointer;
99  typedef typename TransformType::ConstPointer TransformTypeConstPointer;
100 
109 
118 
120  virtual void SetInitialTransform( InitialTransformType * _arg );
121 
122  itkGetObjectMacro( InitialTransform, InitialTransformType );
123  itkGetConstObjectMacro( InitialTransform, InitialTransformType );
124 
129  virtual void SetCurrentTransform( CurrentTransformType * _arg );
130 
131  itkGetObjectMacro( CurrentTransform, CurrentTransformType );
132  itkGetConstObjectMacro( CurrentTransform, CurrentTransformType );
133 
135  virtual SizeValueType GetNumberOfTransforms( void ) const;
136 
141  virtual const TransformTypePointer GetNthTransform( SizeValueType n ) const;
142 
144  virtual void SetUseComposition( bool _arg );
145 
146  itkGetConstMacro( UseComposition, bool );
147 
149  virtual void SetUseAddition( bool _arg );
150 
151  itkGetConstMacro( UseAddition, bool );
152 
154  virtual OutputPointType TransformPoint( const InputPointType & point ) const;
155 
161  {
162  itkExceptionMacro(
163  << "TransformVector(const InputVectorType &) is not implemented "
164  << "for AdvancedCombinationTransform" );
165  }
166 
167 
169  {
170  itkExceptionMacro(
171  << "TransformVector(const InputVnlVectorType &) is not implemented "
172  << "for AdvancedCombinationTransform" );
173  }
174 
175 
177  {
178  itkExceptionMacro(
179  << "TransformCovariantVector(const InputCovariantVectorType &) is not implemented "
180  << "for AdvancedCombinationTransform" );
181  }
182 
183 
185  virtual NumberOfParametersType GetNumberOfParameters( void ) const;
186 
189 
191  virtual const ParametersType & GetParameters( void ) const;
192 
194  virtual const ParametersType & GetFixedParameters( void ) const;
195 
197  virtual void SetParameters( const ParametersType & param );
198 
202  virtual void SetParametersByValue( const ParametersType & param );
203 
205  virtual void SetFixedParameters( const ParametersType & fixedParam );
206 
217  virtual bool GetInverse( Self * inverse ) const;
218 
221  virtual bool IsLinear( void ) const;
222 
228 
230  virtual bool GetHasNonZeroSpatialHessian( void ) const;
231 
232  virtual bool HasNonZeroJacobianOfSpatialHessian( void ) const;
233 
235  virtual void GetJacobian(
236  const InputPointType & ipp,
237  JacobianType & j,
238  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
239 
241  virtual void GetSpatialJacobian(
242  const InputPointType & ipp,
243  SpatialJacobianType & sj ) const;
244 
246  virtual void GetSpatialHessian(
247  const InputPointType & ipp,
248  SpatialHessianType & sh ) const;
249 
251  virtual void GetJacobianOfSpatialJacobian(
252  const InputPointType & ipp,
254  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
255 
259  virtual void GetJacobianOfSpatialJacobian(
260  const InputPointType & ipp,
261  SpatialJacobianType & sj,
263  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
264 
266  virtual void GetJacobianOfSpatialHessian(
267  const InputPointType & ipp,
269  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
270 
274  virtual void GetJacobianOfSpatialHessian(
275  const InputPointType & ipp,
276  SpatialHessianType & sh,
278  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
279 
283  const InputPointType &,
284  JacobianType &,
285  NonZeroJacobianIndicesType & ) const;
287  const InputPointType &,
288  SpatialJacobianType & ) const;
290  const InputPointType &,
291  SpatialHessianType & ) const;
293  const InputPointType &,
295  NonZeroJacobianIndicesType & ) const;
297  const InputPointType &,
300  NonZeroJacobianIndicesType & ) const;
302  const InputPointType &,
304  NonZeroJacobianIndicesType & ) const;
306  const InputPointType &,
309  NonZeroJacobianIndicesType & ) const;
310 
311 protected:
312 
315 
318 
322 
326  virtual void UpdateCombinationMethod( void );
327 
329  virtual void NoCurrentTransformSet( void ) const throw ( ExceptionObject );
330 
338 
345  //GetJacobianFunctionPointer m_SelectedGetJacobianFunction;
346 
355 
362  const InputPointType & point ) const;
363 
368  const InputPointType & point ) const;
369 
372  const InputPointType & point ) const;
373 
376  const InputPointType & point ) const;
377 
383  inline void GetJacobianUseAddition(
384  const InputPointType &,
385  JacobianType &,
386  NonZeroJacobianIndicesType & ) const;
387 
391  inline void GetJacobianUseComposition(
392  const InputPointType &,
393  JacobianType &,
394  NonZeroJacobianIndicesType & ) const;
395 
397  inline void GetJacobianNoInitialTransform(
398  const InputPointType &,
399  JacobianType &,
400  NonZeroJacobianIndicesType & ) const;
401 
403  inline void GetJacobianNoCurrentTransform(
404  const InputPointType &,
405  JacobianType &,
406  NonZeroJacobianIndicesType & ) const;
407 
413  inline void GetSpatialJacobianUseAddition(
414  const InputPointType & ipp,
415  SpatialJacobianType & sj ) const;
416 
421  const InputPointType & ipp,
422  SpatialJacobianType & sj ) const;
423 
426  const InputPointType & ipp,
427  SpatialJacobianType & sj ) const;
428 
431  const InputPointType & ipp,
432  SpatialJacobianType & sj ) const;
433 
439  inline void GetSpatialHessianUseAddition(
440  const InputPointType & ipp,
441  SpatialHessianType & sh ) const;
442 
447  const InputPointType & ipp,
448  SpatialHessianType & sh ) const;
449 
452  const InputPointType & ipp,
453  SpatialHessianType & sh ) const;
454 
457  const InputPointType & ipp,
458  SpatialHessianType & sh ) const;
459 
466  const InputPointType & ipp,
468  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
469 
471  const InputPointType & ipp,
472  SpatialJacobianType & sj,
474  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
475 
480  const InputPointType & ipp,
482  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
483 
485  const InputPointType & ipp,
486  SpatialJacobianType & sj,
488  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
489 
492  const InputPointType & ipp,
494  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
495 
497  const InputPointType & ipp,
498  SpatialJacobianType & sj,
500  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
501 
504  const InputPointType & ipp,
506  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
507 
509  const InputPointType & ipp,
510  SpatialJacobianType & sj,
512  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
513 
520  const InputPointType & ipp,
522  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
523 
525  const InputPointType & ipp,
526  SpatialHessianType & sh,
528  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
529 
534  const InputPointType & ipp,
536  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
537 
538  virtual inline void GetJacobianOfSpatialHessianUseComposition(
539  const InputPointType & ipp,
540  SpatialHessianType & sh,
542  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
543 
546  const InputPointType & ipp,
548  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
549 
551  const InputPointType & ipp,
552  SpatialHessianType & sh,
554  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
555 
558  const InputPointType & ipp,
560  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
561 
563  const InputPointType & ipp,
564  SpatialHessianType & sh,
566  NonZeroJacobianIndicesType & nonZeroJacobianIndices ) const;
567 
571 
572 private:
573 
574  AdvancedCombinationTransform( const Self & ); // purposely not implemented
575  void operator=( const Self & ); // purposely not implemented
576 
577 };
578 
579 } // end namespace itk
580 
581 #ifndef ITK_MANUAL_INSTANTIATION
582 #include "itkAdvancedCombinationTransform.hxx"
583 #endif
584 
585 #endif // end #ifndef __itkAdvancedCombinationTransform_h
This class combines two transforms: an 'initial transform' with a 'current transform'.
Superclass::InputCovariantVectorType InputCovariantVectorType
Superclass::SpatialHessianType SpatialHessianType
OutputPointType(Self::* TransformPointFunctionPointer)(const InputPointType &) const
GetSpatialHessianFunctionPointer m_SelectedGetSpatialHessianFunction
OutputPointType TransformPointUseAddition(const InputPointType &point) const
virtual NumberOfParametersType GetNumberOfNonZeroJacobianIndices(void) const
Superclass::TransformCategoryType TransformCategoryType
virtual const TransformTypePointer GetNthTransform(SizeValueType n) const
Superclass::OutputCovariantVectorType OutputCovariantVectorType
itkStaticConstMacro(SpaceDimension, unsigned int, NDimensions)
Superclass::InverseTransformBasePointer InverseTransformBasePointer
virtual void GetJacobianOfSpatialHessian(const InputPointType &ipp, JacobianOfSpatialHessianType &jsh, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
virtual bool IsLinear(void) const
void(Self::* GetJacobianOfSpatialHessianFunctionPointer2)(const InputPointType &, SpatialHessianType &, JacobianOfSpatialHessianType &, NonZeroJacobianIndicesType &) const
Superclass::JacobianOfSpatialJacobianType JacobianOfSpatialJacobianType
void GetSpatialJacobianNoInitialTransform(const InputPointType &ipp, SpatialJacobianType &sj) const
Superclass::JacobianOfSpatialHessianType JacobianOfSpatialHessianType
void GetSpatialHessianUseAddition(const InputPointType &ipp, SpatialHessianType &sh) const
GetSparseJacobianFunctionPointer m_SelectedGetSparseJacobianFunction
void GetJacobianNoCurrentTransform(const InputPointType &, JacobianType &, NonZeroJacobianIndicesType &) const
CurrentTransformType::ConstPointer CurrentTransformConstPointer
virtual OutputVnlVectorType TransformVector(const InputVnlVectorType &) const
virtual OutputCovariantVectorType TransformCovariantVector(const InputCovariantVectorType &) const
CurrentTransformType::InverseTransformBasePointer CurrentTransformInverseTransformBasePointer
OutputPointType TransformPointNoCurrentTransform(const InputPointType &point) const
InitialTransformType::Pointer InitialTransformPointer
virtual void SetUseAddition(bool _arg)
void GetSpatialHessianNoCurrentTransform(const InputPointType &ipp, SpatialHessianType &sh) const
void GetSpatialHessianNoInitialTransform(const InputPointType &ipp, SpatialHessianType &sh) const
virtual void SetFixedParameters(const ParametersType &fixedParam)
virtual void GetSpatialHessian(const InputPointType &ipp, SpatialHessianType &sh) const
Superclass::InverseTransformBaseType InverseTransformBaseType
void GetJacobianUseComposition(const InputPointType &, JacobianType &, NonZeroJacobianIndicesType &) const
void GetJacobianOfSpatialJacobianUseComposition(const InputPointType &ipp, JacobianOfSpatialJacobianType &jsj, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
virtual TransformCategoryType GetTransformCategory() const
virtual OutputPointType TransformPoint(const InputPointType &point) const
void GetSpatialJacobianUseAddition(const InputPointType &ipp, SpatialJacobianType &sj) const
void GetJacobianOfSpatialHessianUseComposition(const InputPointType &ipp, JacobianOfSpatialHessianType &jsh, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
void GetJacobianUseAddition(const InputPointType &, JacobianType &, NonZeroJacobianIndicesType &) const
virtual bool HasNonZeroJacobianOfSpatialHessian(void) const
void(Self::* GetSpatialHessianFunctionPointer)(const InputPointType &, SpatialHessianType &) const
virtual void SetCurrentTransform(CurrentTransformType *_arg)
virtual NumberOfParametersType GetNumberOfParameters(void) const
Transform maps points, vectors and covariant vectors from an input space to an output space...
virtual OutputVectorType TransformVector(const InputVectorType &) const
virtual void SetUseComposition(bool _arg)
void(Self::* GetJacobianOfSpatialJacobianFunctionPointer2)(const InputPointType &, SpatialJacobianType &, JacobianOfSpatialJacobianType &, NonZeroJacobianIndicesType &) const
TransformPointFunctionPointer m_SelectedTransformPointFunction
CurrentTransformType::Pointer CurrentTransformPointer
void GetJacobianOfSpatialJacobianNoCurrentTransform(const InputPointType &ipp, JacobianOfSpatialJacobianType &jsj, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
void GetJacobianNoInitialTransform(const InputPointType &, JacobianType &, NonZeroJacobianIndicesType &) const
void GetSpatialHessianUseComposition(const InputPointType &ipp, SpatialHessianType &sh) const
GetJacobianOfSpatialJacobianFunctionPointer m_SelectedGetJacobianOfSpatialJacobianFunction
virtual void GetJacobian(const InputPointType &ipp, JacobianType &j, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
Superclass::SpatialJacobianType SpatialJacobianType
virtual SizeValueType GetNumberOfTransforms(void) const
GetSpatialJacobianFunctionPointer m_SelectedGetSpatialJacobianFunction
InitialTransformType::InverseTransformBasePointer InitialTransformInverseTransformBasePointer
GetJacobianOfSpatialJacobianFunctionPointer2 m_SelectedGetJacobianOfSpatialJacobianFunction2
virtual void SetInitialTransform(InitialTransformType *_arg)
InitialTransformType::ConstPointer InitialTransformConstPointer
CurrentTransformType::InverseTransformBaseType CurrentTransformInverseTransformBaseType
virtual bool GetInverse(Self *inverse) const
virtual void SetParametersByValue(const ParametersType &param)
GetJacobianOfSpatialHessianFunctionPointer m_SelectedGetJacobianOfSpatialHessianFunction
Superclass::NumberOfParametersType NumberOfParametersType
void GetJacobianOfSpatialHessianUseAddition(const InputPointType &ipp, JacobianOfSpatialHessianType &jsh, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
virtual bool GetHasNonZeroSpatialHessian(void) const
Transform< elx::TransformBase< TElastix >::CoordRepType, NInputDimensions, NOutputDimensions > TransformType
InitialTransformType::InverseTransformBaseType InitialTransformInverseTransformBaseType
void(Self::* GetJacobianOfSpatialHessianFunctionPointer)(const InputPointType &, JacobianOfSpatialHessianType &, NonZeroJacobianIndicesType &) const
void GetSpatialJacobianNoCurrentTransform(const InputPointType &ipp, SpatialJacobianType &sj) const
Superclass::NonZeroJacobianIndicesType NonZeroJacobianIndicesType
GetJacobianOfSpatialHessianFunctionPointer2 m_SelectedGetJacobianOfSpatialHessianFunction2
Superclass::OutputVnlVectorType OutputVnlVectorType
virtual void SetParameters(const ParametersType &param)
void(Self::* GetSparseJacobianFunctionPointer)(const InputPointType &, JacobianType &, NonZeroJacobianIndicesType &) const
virtual void GetJacobianOfSpatialJacobian(const InputPointType &ipp, JacobianOfSpatialJacobianType &jsj, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
virtual const ParametersType & GetParameters(void) const
virtual void UpdateCombinationMethod(void)
Superclass::InputVnlVectorType InputVnlVectorType
void(Self::* GetSpatialJacobianFunctionPointer)(const InputPointType &, SpatialJacobianType &) const
OutputPointType TransformPointNoInitialTransform(const InputPointType &point) const
void GetJacobianOfSpatialJacobianUseAddition(const InputPointType &ipp, JacobianOfSpatialJacobianType &jsj, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
void GetJacobianOfSpatialHessianNoInitialTransform(const InputPointType &ipp, JacobianOfSpatialHessianType &jsh, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
void GetJacobianOfSpatialHessianNoCurrentTransform(const InputPointType &ipp, JacobianOfSpatialHessianType &jsh, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
FixedArray< Matrix< ScalarType, InputSpaceDimension, InputSpaceDimension >, OutputSpaceDimension > SpatialHessianType
AdvancedTransform< TScalarType, NDimensions, NDimensions > Superclass
virtual void GetSpatialJacobian(const InputPointType &ipp, SpatialJacobianType &sj) const
TransformType::ConstPointer TransformTypeConstPointer
void(Self::* GetJacobianOfSpatialJacobianFunctionPointer)(const InputPointType &, JacobianOfSpatialJacobianType &, NonZeroJacobianIndicesType &) const
virtual const ParametersType & GetFixedParameters(void) const
void GetSpatialJacobianUseComposition(const InputPointType &ipp, SpatialJacobianType &sj) const
void GetJacobianOfSpatialJacobianNoInitialTransform(const InputPointType &ipp, JacobianOfSpatialJacobianType &jsj, NonZeroJacobianIndicesType &nonZeroJacobianIndices) const
virtual void NoCurrentTransformSet(void) const
Superclass::InternalMatrixType InternalMatrixType
OutputPointType TransformPointUseComposition(const InputPointType &point) const


Generated on 11-03-2014 for elastix by doxygen 1.8.6 elastix logo