18 #ifndef itkSyNImageRegistrationMethod_h
19 #define itkSyNImageRegistrationMethod_h
66 template <
typename TFixedImage,
67 typename TMovingImage,
68 typename TOutputTransform = DisplacementFieldTransform<double, TFixedImage::ImageDimension>,
69 typename TVirtualImage = TFixedImage,
70 typename TPointSet = PointSet<unsigned int, TFixedImage::ImageDimension>>
87 static constexpr
unsigned int ImageDimension = TFixedImage::ImageDimension;
95 using typename Superclass::FixedImagesContainerType;
98 using typename Superclass::MovingImagesContainerType;
100 using typename Superclass::PointSetType;
102 using typename Superclass::PointSetsContainerType;
105 using typename Superclass::ImageMetricType;
110 using typename Superclass::FixedImageMaskType;
112 using typename Superclass::FixedImageMasksContainerType;
113 using typename Superclass::MovingImageMaskType;
115 using typename Superclass::MovingImageMasksContainerType;
118 using typename Superclass::VirtualImageBaseType;
119 using typename Superclass::VirtualImageBaseConstPointer;
121 using typename Superclass::MultiMetricType;
122 using typename Superclass::MetricType;
124 using typename Superclass::PointSetMetricType;
126 using typename Superclass::InitialTransformType;
129 using RealType =
typename OutputTransformType::ScalarType;
136 using typename Superclass::CompositeTransformType;
139 using typename Superclass::DecoratedOutputTransformType;
148 itkSetMacro(LearningRate,
RealType);
149 itkGetConstMacro(LearningRate,
RealType);
158 itkSetMacro(ConvergenceThreshold,
RealType);
159 itkGetConstMacro(ConvergenceThreshold,
RealType);
163 itkSetMacro(ConvergenceWindowSize,
unsigned int);
164 itkGetConstMacro(ConvergenceWindowSize,
unsigned int);
171 itkSetMacro(DownsampleImagesForMetricDerivatives,
bool);
172 itkGetConstMacro(DownsampleImagesForMetricDerivatives,
bool);
178 itkSetMacro(AverageMidPointGradients,
bool);
179 itkGetConstMacro(AverageMidPointGradients,
bool);
185 itkSetMacro(GaussianSmoothingVarianceForTheUpdateField,
RealType);
186 itkGetConstReferenceMacro(GaussianSmoothingVarianceForTheUpdateField,
RealType);
192 itkSetMacro(GaussianSmoothingVarianceForTheTotalField,
RealType);
193 itkGetConstReferenceMacro(GaussianSmoothingVarianceForTheTotalField,
RealType);
210 PrintSelf(std::ostream & os,
Indent indent)
const override;
214 GenerateData()
override;
227 InitializeRegistrationAtEachLevel(
const SizeValueType)
override;
262 RealType m_ConvergenceThreshold{ static_cast<RealType>(1.0
e-6) };
263 unsigned int m_ConvergenceWindowSize{ 10 };
266 bool m_DownsampleImagesForMetricDerivatives{
true };
267 bool m_AverageMidPointGradients{
false };
270 RealType m_GaussianSmoothingVarianceForTheUpdateField{ 3.0 };
271 RealType m_GaussianSmoothingVarianceForTheTotalField{ 0.5 };
275 #ifndef ITK_MANUAL_INSTANTIATION
276 # include "itkSyNImageRegistrationMethod.hxx"