ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itk::GPUFiniteDifferenceFunction< TImageType > Class Template Referenceabstract

#include <itkGPUFiniteDifferenceFunction.h>

Detailed Description

template<typename TImageType>
class itk::GPUFiniteDifferenceFunction< TImageType >

This is a base class of GPU finite difference function. Note that unlike most GPU classes, derived class of GPUFiniteDifferenceFunction does not have corresponding CPU class as its parent but only has CPU class FiniteDifferenceFunction as its base class. Therefore, only members of FiniteDifferenceFunction are reused by its derived GPU classes.

How to use this class
GPUFiniteDifferenceFunction must be subclassed to add functionality for GPUComputeUpdate.

Definition at line 47 of file itkGPUFiniteDifferenceFunction.h.

+ Inheritance diagram for itk::GPUFiniteDifferenceFunction< TImageType >:
+ Collaboration diagram for itk::GPUFiniteDifferenceFunction< TImageType >:

Public Types

using ConstPointer = SmartPointer<const Self>
 
using DefaultBoundaryConditionType
 
using DifferenceFunctionType = Superclass
 
using FloatOffsetType
 
using ImageType
 
using NeighborhoodType
 
using PixelRealType
 
using PixelType
 
using Pointer = SmartPointer<Self>
 
using RadiusType
 
using Self = GPUFiniteDifferenceFunction
 
using Superclass = FiniteDifferenceFunction<TImageType>
 
using TimeStepType
 
- Public Types inherited from itk::FiniteDifferenceFunction< TImageType >
using ConstPointer = SmartPointer<const Self>
 
using DefaultBoundaryConditionType = ZeroFluxNeumannBoundaryCondition<ImageType>
 
using FloatOffsetType = Vector<float, Self::ImageDimension>
 
using ImageType = TImageType
 
using NeighborhoodScalesType = Vector<PixelRealType, Self::ImageDimension>
 
using NeighborhoodType = ConstNeighborhoodIterator<TImageType, DefaultBoundaryConditionType>
 
using PixelRealType = double
 
using PixelType = typename ImageType::PixelType
 
using Pointer = SmartPointer<Self>
 
using RadiusType = typename ConstNeighborhoodIterator<TImageType>::RadiusType
 
using Self = FiniteDifferenceFunction
 
using Superclass = LightObject
 
using TimeStepType = double
 
- Public Types inherited from itk::LightObject
using ConstPointer = SmartPointer<const Self>
 
using Pointer = SmartPointer<Self>
 
using Self = LightObject
 

Public Member Functions

const char * GetNameOfClass () const override
 
virtual void GPUAllocateMetricData (unsigned int numPixels)
 
virtual void GPUComputeUpdate (const typename TImageType::Pointer output, typename TImageType::Pointer update, void *gd)=0
 
virtual void GPUReleaseMetricData ()
 
PixelType ComputeUpdate (const NeighborhoodType &neighborhood, void *globalData, const FloatOffsetType &offset=FloatOffsetType(0.0)) override
 
- Public Member Functions inherited from itk::FiniteDifferenceFunction< TImageType >
virtual TimeStepType ComputeGlobalTimeStep (void *GlobalData) const =0
 
const NeighborhoodScalesType ComputeNeighborhoodScales () const
 
virtual void * GetGlobalDataPointer () const =0
 
const RadiusTypeGetRadius () const
 
void GetScaleCoefficients (PixelRealType vals[ImageDimension]) const
 
virtual void InitializeIteration ()
 
virtual void ReleaseGlobalDataPointer (void *GlobalData) const =0
 
void SetRadius (const RadiusType &r)
 
void SetScaleCoefficients (const PixelRealType vals[ImageDimension])
 
- Public Member Functions inherited from itk::LightObject
Pointer Clone () const
 
virtual Pointer CreateAnother () const
 
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
void Print (std::ostream &os, Indent indent=0) const
 
virtual void Register () const
 
virtual void SetReferenceCount (int)
 
virtual void UnRegister () const noexcept
 

Static Public Attributes

static constexpr unsigned int ImageDimension = ImageType::ImageDimension
 
- Static Public Attributes inherited from itk::FiniteDifferenceFunction< TImageType >
static constexpr unsigned int ImageDimension = ImageType::ImageDimension
 

Protected Member Functions

 GPUFiniteDifferenceFunction ()
 
 ~GPUFiniteDifferenceFunction () override=default
 
- Protected Member Functions inherited from itk::FiniteDifferenceFunction< TImageType >
 FiniteDifferenceFunction ()
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~FiniteDifferenceFunction () override=default
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 

Protected Attributes

int m_ComputeUpdateGPUKernelHandle {}
 
GPUKernelManager::Pointer m_GPUKernelManager {}
 
- Protected Attributes inherited from itk::FiniteDifferenceFunction< TImageType >
RadiusType m_Radius {}
 
PixelRealType m_ScaleCoefficients [ImageDimension] {}
 
- Protected Attributes inherited from itk::LightObject
std::atomic< int > m_ReferenceCount {}
 

Additional Inherited Members

- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Member Typedef Documentation

◆ ConstPointer

template<typename TImageType>
using itk::GPUFiniteDifferenceFunction< TImageType >::ConstPointer = SmartPointer<const Self>

Definition at line 57 of file itkGPUFiniteDifferenceFunction.h.

◆ DefaultBoundaryConditionType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::DefaultBoundaryConditionType

The default boundary condition for finite difference functions that is used unless overridden in the Evaluate() method.

Definition at line 94 of file itkFiniteDifferenceFunction.h.

◆ DifferenceFunctionType

template<typename TImageType>
using itk::GPUFiniteDifferenceFunction< TImageType >::DifferenceFunctionType = Superclass

Definition at line 55 of file itkGPUFiniteDifferenceFunction.h.

◆ FloatOffsetType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::FloatOffsetType

A floating point offset from an image grid location. Used for interpolation among grid values in a neighborhood.

Definition at line 109 of file itkFiniteDifferenceFunction.h.

◆ ImageType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::ImageType

Extract some parameters from the image type

Definition at line 82 of file itkFiniteDifferenceFunction.h.

◆ NeighborhoodType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::NeighborhoodType

The type of data structure that is passed to this function object to evaluate at a pixel that does not lie on a data set boundary.

Definition at line 101 of file itkFiniteDifferenceFunction.h.

◆ PixelRealType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::PixelRealType

Definition at line 84 of file itkFiniteDifferenceFunction.h.

◆ PixelType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::PixelType

Definition at line 83 of file itkFiniteDifferenceFunction.h.

◆ Pointer

template<typename TImageType>
using itk::GPUFiniteDifferenceFunction< TImageType >::Pointer = SmartPointer<Self>

Definition at line 56 of file itkGPUFiniteDifferenceFunction.h.

◆ RadiusType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::RadiusType

Neighborhood radius type

Definition at line 97 of file itkFiniteDifferenceFunction.h.

◆ Self

template<typename TImageType>
using itk::GPUFiniteDifferenceFunction< TImageType >::Self = GPUFiniteDifferenceFunction

Standard class type aliases.

Definition at line 53 of file itkGPUFiniteDifferenceFunction.h.

◆ Superclass

template<typename TImageType>
using itk::GPUFiniteDifferenceFunction< TImageType >::Superclass = FiniteDifferenceFunction<TImageType>

Definition at line 54 of file itkGPUFiniteDifferenceFunction.h.

◆ TimeStepType

template<typename TImageType>
using itk::FiniteDifferenceFunction< TImageType >::TimeStepType

Define the TimeStepType to always be double.

Definition at line 90 of file itkFiniteDifferenceFunction.h.

Constructor & Destructor Documentation

◆ GPUFiniteDifferenceFunction()

template<typename TImageType>
itk::GPUFiniteDifferenceFunction< TImageType >::GPUFiniteDifferenceFunction ( )
inlineprotected

Definition at line 117 of file itkGPUFiniteDifferenceFunction.h.

◆ ~GPUFiniteDifferenceFunction()

template<typename TImageType>
itk::GPUFiniteDifferenceFunction< TImageType >::~GPUFiniteDifferenceFunction ( )
overrideprotecteddefault

Member Function Documentation

◆ ComputeUpdate()

template<typename TImageType>
PixelType itk::GPUFiniteDifferenceFunction< TImageType >::ComputeUpdate ( const NeighborhoodType & neighborhood,
void * globalData,
const FloatOffsetType & offset = FloatOffsetType(0.0) )
inlineoverridevirtual

Empty implementation - this will not be used by GPU filters

Implements itk::FiniteDifferenceFunction< TImageType >.

Definition at line 90 of file itkGPUFiniteDifferenceFunction.h.

◆ GetNameOfClass()

◆ GPUAllocateMetricData()

template<typename TImageType>
virtual void itk::GPUFiniteDifferenceFunction< TImageType >::GPUAllocateMetricData ( unsigned int numPixels)
inlinevirtual

◆ GPUComputeUpdate()

template<typename TImageType>
virtual void itk::GPUFiniteDifferenceFunction< TImageType >::GPUComputeUpdate ( const typename TImageType::Pointer output,
typename TImageType::Pointer update,
void * gd )
pure virtual

GPU function to compute update buffer

Implemented in itk::GPUGradientNDAnisotropicDiffusionFunction< TImage >.

◆ GPUReleaseMetricData()

Member Data Documentation

◆ ImageDimension

template<typename TImageType>
unsigned int itk::GPUFiniteDifferenceFunction< TImageType >::ImageDimension = ImageType::ImageDimension
staticconstexpr

Save image dimension.

Definition at line 68 of file itkGPUFiniteDifferenceFunction.h.

◆ m_ComputeUpdateGPUKernelHandle

template<typename TImageType>
int itk::GPUFiniteDifferenceFunction< TImageType >::m_ComputeUpdateGPUKernelHandle {}
protected

GPU kernel handle for GPUComputeUpdate()

Definition at line 124 of file itkGPUFiniteDifferenceFunction.h.

◆ m_GPUKernelManager

template<typename TImageType>
GPUKernelManager::Pointer itk::GPUFiniteDifferenceFunction< TImageType >::m_GPUKernelManager {}
protected

GPU kernel manager for GPUFiniteDifferenceFunction class

Definition at line 121 of file itkGPUFiniteDifferenceFunction.h.


The documentation for this class was generated from the following file: