go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxStatisticalShapePenalty.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright UMC Utrecht and contributors
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __elxStatisticalShapePenalty_H__
19 #define __elxStatisticalShapePenalty_H__
20 
21 #include "elxIncludes.h" // include first to avoid MSVS warning
23 
24 #include <vnl/vnl_matrix.h>
25 #include <vnl/vnl_vector.h>
26 #include <vcl_iostream.h>
27 
28 namespace elastix
29 {
30 using namespace itk;
31 
58 template< class TElastix >
61  typename MetricBase< TElastix >::FixedPointSetType,
62  typename MetricBase< TElastix >::MovingPointSetType >,
63  public MetricBase< TElastix >
64 {
65 public:
66 
74  typedef SmartPointer< const Self > ConstPointer;
75 
77  itkNewMacro( Self );
78 
80  itkTypeMacro( StatisticalShapePenalty,
82 
87  elxClassNameMacro( "StatisticalShapePenalty" );
88 
95 
96 // typedef typename Superclass1::FixedImageRegionType FixedImageRegionType;
103 // typedef typename Superclass1::RealType RealType;
111 
112  typedef typename OutputPointType::CoordRepType CoordRepType;
114 
116  typedef itk::Object ObjectType;
117  /*typedef itk::AdvancedTransform<
118  CoordRepType,
119  itkGetStaticConstMacro( FixedImageDimension ),
120  itkGetStaticConstMacro( MovingImageDimension ) > ITKBaseType;
121  */
122  typedef itk::AdvancedCombinationTransform< CoordRepType,
123  itkGetStaticConstMacro( FixedImageDimension ) > CombinationTransformType;
124  typedef typename
126 
137 
139  itkStaticConstMacro( FixedImageDimension, unsigned int,
140  FixedImageType::ImageDimension );
141 
143  itkStaticConstMacro( MovingImageDimension, unsigned int,
144  MovingImageType::ImageDimension );
145 
149  typedef FixedPointSetType PointSetType;
150  typedef FixedImageType ImageType;
151 
155  virtual void Initialize( void ) throw ( ExceptionObject );
156 
161  virtual void BeforeRegistration( void );
162 
163  virtual void BeforeEachResolution( void );
164 
166  unsigned int ReadLandmarks(
167  const std::string & landmarkFileName,
168  typename PointSetType::Pointer & pointSet,
169  const typename ImageType::ConstPointer image );
170 
171  unsigned int ReadShape(
172  const std::string & ShapeFileName,
173  typename PointSetType::Pointer & pointSet,
174  const typename ImageType::ConstPointer image );
175 
177  virtual void SelectNewSamples( void ){}
178 
179 protected:
180 
185 
186 private:
187 
189  StatisticalShapePenalty( const Self & ); // purposely not implemented
191  void operator=( const Self & ); // purposely not implemented
192 
193 };
194 
195 } // end namespace elastix
196 
197 #ifndef ITK_MANUAL_INSTANTIATION
198 #include "elxStatisticalShapePenalty.hxx"
199 #endif
200 
201 #endif // end #ifndef __elxStatisticalShapePenalty_H__
This class combines two transforms: an 'initial transform' with a 'current transform'.
Superclass::ElastixPointer ElastixPointer
Definition: elxMetricBase.h:86
Superclass::RegistrationType RegistrationType
Definition: elxMetricBase.h:89
Superclass::TransformJacobianType TransformJacobianType
Superclass::ConfigurationType ConfigurationType
Definition: elxMetricBase.h:87
Superclass1::CoordinateRepresentationType CoordinateRepresentationType
#define elxClassNameMacro(_name)
Definition: elxMacro.h:262
Superclass1::ParametersType ParametersType
Superclass1::MovingPointSetType MovingPointSetType
Superclass1::FixedImageMaskPointer FixedImageMaskPointer
Superclass1::FixedPointSetConstPointer FixedPointSetConstPointer
Computes the Mahalanobis distance between the transformed shape and a mean shape. A model mean and co...
Superclass1::DerivativeType DerivativeType
StatisticalShapePointPenalty< typename MetricBase< TElastix >::FixedPointSetType, typename MetricBase< TElastix >::MovingPointSetType > Superclass1
CombinationTransformType::InitialTransformType InitialTransformType
Superclass2::RegistrationPointer RegistrationPointer
itk::PointSet< CoordinateRepresentationType, FixedImageDimension, itk::DefaultStaticMeshTraits< CoordinateRepresentationType, FixedImageDimension, FixedImageDimension, CoordinateRepresentationType, CoordinateRepresentationType, CoordinateRepresentationType > > FixedPointSetType
Superclass1::MovingImageMaskPointer MovingImageMaskPointer
ElastixType::FixedImageType FixedImageType
Definition: elxMetricBase.h:93
SpatialObject< itkGetStaticConstMacro(MovingPointSetDimension) > MovingImageMaskType
Superclass::FixedPointSetType FixedPointSetType
Superclass1::TransformJacobianType TransformJacobianType
Superclass1::TransformType TransformType
Superclass1::MovingImageMaskType MovingImageMaskType
Superclass1::TransformPointer TransformPointer
SpatialObject< itkGetStaticConstMacro(FixedPointSetDimension) > FixedImageMaskType
Superclass1::InputPointType InputPointType
Superclass::MovingPointSetType MovingPointSetType
Superclass1::OutputPointType OutputPointType
Superclass2::FixedImageType FixedImageType
Superclass2::MovingImageType MovingImageType
Superclass2::ConfigurationPointer ConfigurationPointer
Superclass1::MovingPointSetConstPointer MovingPointSetConstPointer
Superclass::MovingPointSetConstPointer MovingPointSetConstPointer
Superclass::ElastixType ElastixType
Definition: elxMetricBase.h:82
Superclass2::ConfigurationType ConfigurationType
itk::SingleValuedCostFunction ITKBaseType
itk::PointSet< CoordinateRepresentationType, MovingImageDimension, itk::DefaultStaticMeshTraits< CoordinateRepresentationType, MovingImageDimension, MovingImageDimension, CoordinateRepresentationType, CoordinateRepresentationType, CoordinateRepresentationType > > MovingPointSetType
ElastixType::MovingImageType MovingImageType
Definition: elxMetricBase.h:96
Superclass1::FixedPointSetType FixedPointSetType
Superclass::RegistrationPointer RegistrationPointer
Definition: elxMetricBase.h:90
Superclass1::FixedImageMaskType FixedImageMaskType
An metric based on the itk::StatisticalShapePointPenalty.
Superclass::TransformParametersType TransformParametersType
Superclass2::ElastixPointer ElastixPointer
Superclass1::TransformParametersType TransformParametersType
Superclass::FixedPointSetConstPointer FixedPointSetConstPointer
Superclass2::RegistrationType RegistrationType
Superclass::ConfigurationPointer ConfigurationPointer
Definition: elxMetricBase.h:88
itk::AdvancedCombinationTransform< CoordRepType, itkGetStaticConstMacro(FixedImageDimension) > CombinationTransformType
OutputPointType::CoordRepType CoordRepType
This class is the elastix base class for all Metrics.
Definition: elxMetricBase.h:73


Generated on 04-09-2015 for elastix by doxygen 1.8.9.1 elastix logo