go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkParzenWindowMutualInformationImageToImageMetric.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 __itkParzenWindowMutualInformationImageToImageMetric_H__
16 #define __itkParzenWindowMutualInformationImageToImageMetric_H__
17 
19 
20 #include "itkArray2D.h"
21 
22 namespace itk
23 {
24 
71  template <class TFixedImage,class TMovingImage >
73  public ParzenWindowHistogramImageToImageMetric< TFixedImage, TMovingImage >
74  {
75  public:
76 
80  TFixedImage, TMovingImage > Superclass;
81  typedef SmartPointer<Self> Pointer;
82  typedef SmartPointer<const Self> ConstPointer;
83 
85  itkNewMacro( Self );
86 
88  itkTypeMacro(
91 
93  typedef typename
109  typedef typename Superclass::RealType RealType;
128  typedef typename
132  typedef typename
134  typedef typename
136  typedef typename
138 
140  itkStaticConstMacro( FixedImageDimension, unsigned int,
141  FixedImageType::ImageDimension );
142 
144  itkStaticConstMacro( MovingImageDimension, unsigned int,
145  MovingImageType::ImageDimension );
146 
148  MeasureType GetValue( const ParametersType& parameters ) const;
149 
151  itkGetConstMacro( UseJacobianPreconditioning, bool );
152  itkSetMacro( UseJacobianPreconditioning, bool );
153 
154  protected:
155 
158 
161 
188 
192  virtual void GetValueAndAnalyticDerivative(
193  const ParametersType& parameters,
194  MeasureType& value, DerivativeType& derivative ) const;
195 
201  const ParametersType& parameters,
202  MeasureType& value, DerivativeType& derivative ) const;
203 
207  virtual void GetValueAndFiniteDifferenceDerivative( const ParametersType& parameters,
208  MeasureType& value, DerivativeType& derivative ) const;
209 
211  virtual void ComputeJacobianPreconditioner(
212  const TransformJacobianType & jac,
213  const NonZeroJacobianIndicesType & nzji,
214  DerivativeType & preconditioner,
215  DerivativeType & divisor ) const;
216 
218  virtual void InitializeHistograms( void );
219 
220  private:
221 
223  ParzenWindowMutualInformationImageToImageMetric( const Self& ); // purposely not implemented
225  void operator=( const Self& ); // purposely not implemented
226 
228  typedef double PRatioType;
231 
234 
237  const RealType & fixedImageValue,
238  const RealType & movingImageValue,
239  const DerivativeType & imageJacobian,
240  const NonZeroJacobianIndicesType & nzji,
241  DerivativeType & derivative ) const;
242 
244  void ComputeValueAndPRatioArray( double & MI ) const;
245 
246  }; // end class ParzenWindowMutualInformationImageToImageMetric
247 
248 } // end namespace itk
249 
250 #ifndef ITK_MANUAL_INSTANTIATION
251 #include "itkParzenWindowMutualInformationImageToImageMetric.hxx"
252 #endif
253 
254 #endif // end #ifndef __itkParzenWindowMutualInformationImageToImageMetric_H__
255 


Generated on 21-03-2014 for elastix by doxygen 1.8.1.2 elastix logo