18 #ifndef itkGPUDemonsRegistrationFunction_h
19 #define itkGPUDemonsRegistrationFunction_h
57 template<
typename TFixedImage,
typename TMovingImage,
typename TDisplacementField >
96 static constexpr
unsigned int ImageDimension = Superclass::ImageDimension;
128 itkGetOpenCLSourceFromKernelMacro(GPUDemonsRegistrationFunctionKernel);
133 m_MovingImageInterpolator = ptr;
139 return m_MovingImageInterpolator;
162 void ReleaseGlobalDataPointer(
void *GlobalData)
const override;
166 void GPUAllocateMetricData(
unsigned int numPixels)
override;
170 void GPUReleaseMetricData()
override;
173 void InitializeIteration()
override;
177 virtual PixelType ComputeUpdate(
const NeighborhoodType & neighborhood,
179 const FloatOffsetType & offset =
180 FloatOffsetType(0.0) )
override;
182 virtual void GPUComputeUpdate(
const DisplacementFieldTypePointer output,
183 DisplacementFieldTypePointer update,
205 m_UseMovingImageGradient = flag;
209 return m_UseMovingImageGradient;
217 virtual void SetIntensityDifferenceThreshold(
double);
219 virtual double GetIntensityDifferenceThreshold()
const;
225 void PrintSelf(std::ostream & os,
Indent indent)
const override;
228 using FixedImageNeighborhoodIteratorType =
287 #ifndef ITK_MANUAL_INSTANTIATION
288 #include "itkGPUDemonsRegistrationFunction.hxx"
InterpolatorPointer m_MovingImageInterpolator
typename Superclass::NeighborhoodType NeighborhoodType
typename InterpolatorType::PointType PointType
GPUReduction< float >::Pointer m_GPUSquaredDifference
PixelType m_ZeroUpdateReturn
Light weight base class for most itk classes.
bool m_UseMovingImageGradient
GradientCalculatorPointer m_FixedImageGradientCalculator
typename InterpolatorType::Pointer InterpolatorPointer
unsigned long SizeValueType
void SetMovingImageInterpolator(InterpolatorType *ptr)
GPUReduction< int >::Pointer m_GPUPixelCounter
double m_SumOfSquaredChange
SizeValueType m_NumberOfPixelsProcessed
typename Superclass::NeighborhoodType NeighborhoodType
Calculate the derivative by central differencing.
virtual double GetMetric() const
itkGPUKernelClassMacro(GPUImageOpsKernel)
int m_ComputeUpdateGPUKernelHandle
double m_IntensityDifferenceThreshold
void * GetGlobalDataPointer() const override
typename FixedImageType::SpacingType SpacingType
typename Superclass::RadiusType RadiusType
typename FixedImageType::IndexType IndexType
MovingImageGradientCalculatorPointer m_MovingImageGradientCalculator
virtual double GetRMSChange() const
ImageBaseType::SizeType SizeType
GPUReduction< float >::Pointer m_GPUSquaredChange
ImageBaseType::IndexType IndexType
double m_DenominatorThreshold
virtual bool GetUseMovingImageGradient() const
InterpolatorType * GetMovingImageInterpolator()
Linearly interpolate an image at specified positions.
double m_SumOfSquaredDifference
Base class for all image interpolaters.
typename Superclass::PixelType PixelType
typename Superclass::FloatOffsetType FloatOffsetType
typename Superclass::FloatOffsetType FloatOffsetType
typename FixedImageType::SizeType SizeType
~GPUDemonsRegistrationFunction() override
std::mutex m_MetricCalculationLock
double m_SumOfSquaredChange
Control indentation during Print() invocation.
ImageBaseType::PointType PointType
typename Superclass::PixelType PixelType
virtual TimeStepType ComputeGlobalTimeStep(void *) const override
typename MovingImageGradientCalculatorType::Pointer MovingImageGradientCalculatorPointer
typename Superclass::TimeStepType TimeStepType
typename GradientCalculatorType::Pointer GradientCalculatorPointer
SizeValueType m_NumberOfPixelsProcessed
A templated class holding a n-Dimensional covariant vector.
double m_SumOfSquaredDifference
typename Superclass::RadiusType RadiusType
virtual void SetUseMovingImageGradient(bool flag)
SmartPointer< Self > Pointer