ITK  4.8.0
Insight Segmentation and Registration Toolkit
itkBSplineSyNImageRegistrationMethod.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
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 itkBSplineSyNImageRegistrationMethod_h
19 #define itkBSplineSyNImageRegistrationMethod_h
20 
22 
25 
26 namespace itk
27 {
28 
46 template<typename TFixedImage, typename TMovingImage, typename TOutputTransform =
47  BSplineSmoothingOnUpdateDisplacementFieldTransform<double, TFixedImage::ImageDimension>,
48  typename TVirtualImage = TFixedImage,
49  typename TPointSet = PointSet<unsigned int, TFixedImage::ImageDimension> >
51 : public SyNImageRegistrationMethod<TFixedImage, TMovingImage, TOutputTransform, TVirtualImage, TPointSet>
52 {
53 public:
56  typedef SyNImageRegistrationMethod<TFixedImage, TMovingImage, TOutputTransform,
57  TVirtualImage, TPointSet> Superclass;
60 
62  itkNewMacro( Self );
63 
65  itkStaticConstMacro( ImageDimension, unsigned int, TFixedImage::ImageDimension );
66 
69 
71  typedef TFixedImage FixedImageType;
72  typedef typename FixedImageType::Pointer FixedImagePointer;
74  typedef TMovingImage MovingImageType;
75  typedef typename MovingImageType::Pointer MovingImagePointer;
77 
80 
83  typedef typename ImageMetricType::Pointer ImageMetricPointer;
84  typedef typename ImageMetricType::MeasureType MeasureType;
85  typedef typename ImageMetricType::FixedImageMaskType FixedImageMaskType;
86  typedef typename ImageMetricType::MovingImageMaskType MovingImageMaskType;
87 
91 
94  typedef typename MetricType::Pointer MetricPointer;
96 
98 
100  typedef TOutputTransform OutputTransformType;
101  typedef typename OutputTransformType::Pointer OutputTransformPointer;
102  typedef typename OutputTransformType::ScalarType RealType;
103  typedef typename OutputTransformType::DerivativeType DerivativeType;
104  typedef typename DerivativeType::ValueType DerivativeValueType;
105  typedef typename OutputTransformType::DisplacementFieldType DisplacementFieldType;
106  typedef typename DisplacementFieldType::Pointer DisplacementFieldPointer;
107  typedef typename DisplacementFieldType::PixelType DisplacementVectorType;
108 
113 
116 
120  typedef typename CompositeTransformType::TransformType TransformBaseType;
121 
123  typedef typename DecoratedOutputTransformType::Pointer DecoratedOutputTransformPointer;
124 
125 protected:
128 
130  virtual void StartOptimization() ITK_OVERRIDE;
131 
132  virtual void InitializeRegistrationAtEachLevel( const SizeValueType ) ITK_OVERRIDE;
133 
135  const TransformBaseType *, const MovingImagesContainerType, const PointSetsContainerType,
136  const TransformBaseType *, const FixedImageMaskType *, MeasureType & ) ITK_OVERRIDE;
138  const ArrayType &, const WeightedMaskImageType *, const BSplinePointSetType * );
139 
140 private:
141  BSplineSyNImageRegistrationMethod( const Self & ); //purposely not implemented
142  void operator=( const Self & ); //purposely not implemented
143 };
144 } // end namespace itk
145 
146 #ifndef ITK_MANUAL_INSTANTIATION
147 #include "itkBSplineSyNImageRegistrationMethod.hxx"
148 #endif
149 
150 #endif
Superclass::DecoratedOutputTransformType DecoratedOutputTransformType
Superclass::VirtualImageBaseConstPointer VirtualImageBaseConstPointer
Implementation of an image mask as spatial object.
Superclass::PointSetMetricType PointSetMetricType
Light weight base class for most itk classes.
Superclass::MovingImagesContainerType MovingImagesContainerType
virtual void StartOptimization() override
DisplacementFieldTransformType::Pointer DisplacementFieldTransformPointer
Superclass::DisplacementFieldTransformType DisplacementFieldTransformType
Superclass::NumberOfIterationsArrayType NumberOfIterationsArrayType
Superclass::VirtualImageType VirtualImageType
Superclass::InitialTransformType InitialTransformType
Superclass::PointSetsContainerType PointSetsContainerType
DisplacementFieldTransform< RealType, ImageDimension > DisplacementFieldTransformType
unsigned long SizeValueType
Definition: itkIntTypes.h:143
ImageMetricType::MovingImageMaskType MovingImageMaskType
virtual DisplacementFieldPointer ComputeUpdateField(const FixedImagesContainerType, const PointSetsContainerType, const TransformBaseType *, const MovingImagesContainerType, const PointSetsContainerType, const TransformBaseType *, const FixedImageMaskType *, MeasureType &) override
Superclass::VirtualImageBaseConstPointer VirtualImageBaseConstPointer
Interface method for the performing greedy SyN image registration.
DecoratedOutputTransformType::Pointer DecoratedOutputTransformPointer
Superclass::VirtualImageBaseType VirtualImageBaseType
ImageMaskSpatialObject< ImageDimension > ImageMaskSpatialObjectType
Superclass::CompositeTransformType CompositeTransformType
CompositeTransformType::TransformType TransformBaseType
Superclass::PointSetsContainerType PointSetsContainerType
Superclass::FixedImagesContainerType FixedImagesContainerType
Superclass::FixedImagesContainerType FixedImagesContainerType
Superclass::MovingImagesContainerType MovingImagesContainerType
Superclass::DisplacementFieldTransformPointer DisplacementFieldTransformPointer
ImageMetricType::FixedImageMaskType FixedImageMaskType
virtual DisplacementFieldPointer BSplineSmoothDisplacementField(const DisplacementFieldType *, const ArrayType &, const WeightedMaskImageType *, const BSplinePointSetType *)
virtual void InitializeRegistrationAtEachLevel(const SizeValueType) override
Superclass::DecoratedOutputTransformType DecoratedOutputTransformType
SyNImageRegistrationMethod< TFixedImage, TMovingImage, TOutputTransform, TVirtualImage, TPointSet > Superclass
Interface method for the performing greedy B-spline SyN image registration.
Class which takes a dense displacement field image and/or a set of points with associated displacemen...
BSplineFilterType::InputPointSetType BSplinePointSetType
OutputTransformType::DisplacementFieldType DisplacementFieldType
Templated n-dimensional image class.
Definition: itkImage.h:75
DisplacementFieldToBSplineImageFilter< DisplacementFieldType > BSplineFilterType