18 #ifndef itkFastSymmetricForcesDemonsRegistrationFunction_h
19 #define itkFastSymmetricForcesDemonsRegistrationFunction_h
46 template <
typename TFixedImage,
typename TMovingImage,
typename TDisplacementField>
66 using typename Superclass::MovingImageType;
67 using typename Superclass::MovingImagePointer;
70 using typename Superclass::FixedImageType;
71 using typename Superclass::FixedImagePointer;
77 using typename Superclass::DisplacementFieldType;
78 using typename Superclass::DisplacementFieldTypePointer;
81 static constexpr
unsigned int ImageDimension = Superclass::ImageDimension;
115 m_MovingImageInterpolator = ptr;
116 m_MovingImageWarper->SetInterpolator(ptr);
124 return m_MovingImageInterpolator;
141 global->m_SumOfSquaredDifference = 0.0;
142 global->m_NumberOfPixelsProcessed = 0L;
143 global->m_SumOfSquaredChange = 0;
152 ReleaseGlobalDataPointer(
void * GlobalData)
const override;
156 InitializeIteration()
override;
163 ComputeUpdate(
const NeighborhoodType & neighborhood,
165 const FloatOffsetType & offset = FloatOffsetType(0.0))
override;
177 virtual const double &
188 SetIntensityDifferenceThreshold(
double);
191 GetIntensityDifferenceThreshold()
const;
197 PrintSelf(std::ostream & os,
Indent indent)
const override;
213 double m_Normalizer{};
231 double m_DenominatorThreshold{};
234 double m_IntensityDifferenceThreshold{};
239 mutable double m_Metric{};
240 mutable double m_SumOfSquaredDifference{};
242 mutable double m_RMSChange{};
243 mutable double m_SumOfSquaredChange{};
246 mutable std::mutex m_MetricCalculationMutex{};
250 #ifndef ITK_MANUAL_INSTANTIATION
251 # include "itkFastSymmetricForcesDemonsRegistrationFunction.hxx"