go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkMultiResolutionImageRegistrationMethod2.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
23/*=========================================================================
24
25 Program: Insight Segmentation & Registration Toolkit
26 Module: $RCSfile$
27 Date: $Date: 2008-06-27 17:50:36 +0200 (Fri, 27 Jun 2008) $
28 Version: $Revision: 1728 $
29
30 Copyright (c) Insight Software Consortium. All rights reserved.
31 See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
32
33 This software is distributed WITHOUT ANY WARRANTY; without even
34 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
35 PURPOSE. See the above copyright notices for more information.
36
37=========================================================================*/
38#ifndef itkMultiResolutionImageRegistrationMethod2_h
39#define itkMultiResolutionImageRegistrationMethod2_h
40
41#include "itkProcessObject.h"
43#include "itkSingleValuedNonLinearOptimizer.h"
44#include "itkMultiResolutionPyramidImageFilter.h"
45#include "itkNumericTraits.h"
46#include "itkDataObjectDecorator.h"
47
48namespace itk
49{
50
96template <typename TFixedImage, typename TMovingImage>
97class ITK_TEMPLATE_EXPORT MultiResolutionImageRegistrationMethod2 : public ProcessObject
99public:
100 ITK_DISALLOW_COPY_AND_MOVE(MultiResolutionImageRegistrationMethod2);
104 using Superclass = ProcessObject;
105 using Pointer = SmartPointer<Self>;
106 using ConstPointer = SmartPointer<const Self>;
109 itkNewMacro(Self);
112 itkTypeMacro(MultiResolutionImageRegistrationMethod2, ProcessObject);
115 using FixedImageType = TFixedImage;
116 using FixedImageConstPointer = typename FixedImageType::ConstPointer;
117 using FixedImageRegionType = typename FixedImageType::RegionType;
118 using FixedImageRegionPyramidType = std::vector<FixedImageRegionType>;
121 using MovingImageType = TMovingImage;
122 using MovingImageConstPointer = typename MovingImageType::ConstPointer;
123
127
130 using TransformPointer = typename TransformType::Pointer;
131
135 using TransformOutputType = DataObjectDecorator<TransformType>;
136 using TransformOutputPointer = typename TransformOutputType::Pointer;
137 using TransformOutputConstPointer = typename TransformOutputType::ConstPointer;
138
140 using InterpolatorType = typename MetricType::InterpolatorType;
141 using InterpolatorPointer = typename InterpolatorType::Pointer;
142
145
147 using FixedImagePyramidType = MultiResolutionPyramidImageFilter<FixedImageType, FixedImageType>;
148 using FixedImagePyramidPointer = typename FixedImagePyramidType::Pointer;
149
151 using MovingImagePyramidType = MultiResolutionPyramidImageFilter<MovingImageType, MovingImageType>;
152 using MovingImagePyramidPointer = typename MovingImagePyramidType::Pointer;
153
157 using ParametersType = typename MetricType::TransformParametersType;
158
160 using DataObjectPointer = typename DataObject::Pointer;
161
163 virtual void
165
167 virtual void
169
171 itkSetConstObjectMacro(FixedImage, FixedImageType);
172 itkGetConstObjectMacro(FixedImage, FixedImageType);
173
175 itkSetConstObjectMacro(MovingImage, MovingImageType);
176 itkGetConstObjectMacro(MovingImage, MovingImageType);
177
179 itkSetObjectMacro(Optimizer, OptimizerType);
181
183 itkSetObjectMacro(Metric, MetricType);
185
187 itkSetMacro(FixedImageRegion, FixedImageRegionType);
188 itkGetConstReferenceMacro(FixedImageRegion, FixedImageRegionType);
189
191 itkSetObjectMacro(Transform, TransformType);
193
195 itkSetObjectMacro(Interpolator, InterpolatorType);
197
199 itkSetObjectMacro(FixedImagePyramid, FixedImagePyramidType);
201
203 itkSetObjectMacro(MovingImagePyramid, MovingImagePyramidType);
205
207 itkSetClampMacro(NumberOfLevels, unsigned long, 1, NumericTraits<unsigned long>::max());
208 itkGetConstMacro(NumberOfLevels, unsigned long);
209
211 itkGetConstMacro(CurrentLevel, unsigned long);
212
214 itkSetMacro(InitialTransformParameters, ParametersType);
215 itkGetConstReferenceMacro(InitialTransformParameters, ParametersType);
216
221 itkSetMacro(InitialTransformParametersOfNextLevel, ParametersType);
222 itkGetConstReferenceMacro(InitialTransformParametersOfNextLevel, ParametersType);
223
227 itkGetConstReferenceMacro(LastTransformParameters, ParametersType);
228
230 const TransformOutputType *
231 GetOutput() const;
232
236 virtual DataObjectPointer
237 MakeOutput(unsigned int idx);
238
242 ModifiedTimeType
243 GetMTime() const override;
244
245protected:
248
251
253 void
254 PrintSelf(std::ostream & os, Indent indent) const override;
255
259 void
260 GenerateData() override;
261
266 virtual void
268
270 virtual void
272
274 itkSetMacro(CurrentLevel, unsigned long);
275
281 bool m_Stop;
282
283private:
286 OptimizerType::Pointer m_Optimizer;
289
292
297
300
301 unsigned long m_NumberOfLevels;
302 unsigned long m_CurrentLevel;
303};
304
305} // end namespace itk
306
307#ifndef ITK_MANUAL_INSTANTIATION
308# include "itkMultiResolutionImageRegistrationMethod2.hxx"
309#endif
310
311#endif // end #ifndef itkMultiResolutionImageRegistrationMethod2_h
An extension of the ITK ImageToImageMetric. It is the intended base class for all elastix metrics.
Transform maps points, vectors and covariant vectors from an input space to an output space.
Base class for multi-resolution image registration methods.
itkGetModifiableObjectMacro(Interpolator, InterpolatorType)
typename TransformOutputType::ConstPointer TransformOutputConstPointer
virtual DataObjectPointer MakeOutput(unsigned int idx)
itkGetModifiableObjectMacro(Optimizer, OptimizerType)
MultiResolutionPyramidImageFilter< FixedImageType, FixedImageType > FixedImagePyramidType
itkGetModifiableObjectMacro(MovingImagePyramid, MovingImagePyramidType)
const TransformOutputType * GetOutput() const
~MultiResolutionImageRegistrationMethod2() override=default
ModifiedTimeType GetMTime() const override
itkGetModifiableObjectMacro(FixedImagePyramid, FixedImagePyramidType)
void PrintSelf(std::ostream &os, Indent indent) const override
itkGetModifiableObjectMacro(Transform, TransformType)
MultiResolutionPyramidImageFilter< MovingImageType, MovingImageType > MovingImagePyramidType


Generated on 2023-01-13 for elastix by doxygen 1.9.6 elastix logo