go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Private Member Functions | Private Attributes
elastix::OpenCLResampler< TElastix > Class Template Reference

#include <elxOpenCLResampler.h>

Detailed Description

template<class TElastix>
class elastix::OpenCLResampler< TElastix >

A resampler based on the itk::GPUResampleImageFilter. The parameters used in this class are:

Parameters:

Resampler: Select this resampler as follows:
(Resampler "OpenCLResampler")

Resampler: Enable the OpenCL resampler as follows:
(OpenCLResamplerUseOpenCL "true")

Author
Denis P. Shamonin and Marius Staring. Division of Image Processing, Department of Radiology, Leiden, The Netherlands
Note
This work was funded by the Netherlands Organisation for Scientific Research (NWO NRG-2010.02 and NWO 639.021.124).

Definition at line 50 of file elxOpenCLResampler.h.

Inheritance diagram for elastix::OpenCLResampler< TElastix >:
Inheritance graph
[legend]

Public Types

typedef itk::SmartPointer< const SelfConstPointer
 
typedef GPUInputImageType::Pointer GPUInputImagePointer
 
typedef itk::GPUImage< InputImagePixelType, InputImageType::ImageDimension > GPUInputImageType
 
typedef float GPUInterpolatorPrecisionType
 
typedef itk::GPUImage< OutputImagePixelType, OutputImageType::ImageDimension > GPUOutputImageType
 
typedef GPUResamplerType::Pointer GPUResamplerPointer
 
typedef itk::GPUResampleImageFilter< GPUInputImageType, GPUOutputImageType, GPUInterpolatorPrecisionTypeGPUResamplerType
 
typedef InputImageType::PixelType InputImagePixelType
 
typedef Superclass1::InputImageType InputImageType
 
typedef Superclass1::InterpolatorType InterpolatorType
 
typedef OutputImageType::PixelType OutputImagePixelType
 
typedef OutputImageType::RegionType OutputImageRegionType
 
typedef Superclass1::OutputImageType OutputImageType
 
typedef itk::SmartPointer< SelfPointer
 
typedef OpenCLResampler Self
 
typedef itk::ResampleImageFilter< typename ResamplerBase< TElastix >::InputImageType, typename ResamplerBase< TElastix >::OutputImageType, typename ResamplerBase< TElastix >::CoordRepTypeSuperclass1
 
typedef ResamplerBase< TElastix > Superclass2
 
typedef Superclass1::TransformType TransformType
 
- Public Types inherited from elastix::ResamplerBase< TElastix >
typedef Superclass::ConfigurationPointer ConfigurationPointer
 
typedef Superclass::ConfigurationType ConfigurationType
 
typedef ElastixType::CoordRepType CoordRepType
 
typedef ITKBaseType::DirectionType DirectionType
 
typedef Superclass::ElastixPointer ElastixPointer
 
typedef Superclass::ElastixType ElastixType
 
typedef ITKBaseType::IndexType IndexType
 
typedef ElastixType::MovingImageType InputImageType
 
typedef ITKBaseType::InterpolatorType InterpolatorType
 
typedef itk::ResampleImageFilter< InputImageType, OutputImageType, CoordRepTypeITKBaseType
 
typedef ITKBaseType::OriginPointType OriginPointType
 
typedef ElastixType::MovingImageType OutputImageType
 
typedef ITKBaseType::PixelType OutputPixelType
 
typedef ElastixType::ParameterMapType ParameterMapType
 
typedef elx::ProgressCommand ProgressCommandType
 
typedef Superclass::RegistrationPointer RegistrationPointer
 
typedef Superclass::RegistrationType RegistrationType
 
typedef ResamplerBase Self
 
typedef ITKBaseType::SizeType SizeType
 
typedef ITKBaseType::SpacingType SpacingType
 
typedef BaseComponentSE< TElastix > Superclass
 
typedef ITKBaseType::TransformType TransformType
 
- Public Types inherited from elastix::BaseComponentSE< TElastix >
typedef ElastixType::ConfigurationPointer ConfigurationPointer
 
typedef ElastixType::ConfigurationType ConfigurationType
 
typedef ElastixType::Pointer ElastixPointer
 
typedef TElastix ElastixType
 
typedef RegistrationTypeRegistrationPointer
 
typedef ElastixType::RegistrationBaseType RegistrationType
 
typedef BaseComponentSE Self
 
typedef BaseComponent Superclass
 

Public Member Functions

virtual void BeforeRegistration (void)
 
 elxClassNameMacro ("OpenCLResampler")
 
virtual const char * GetClassName () const
 
virtual void ReadFromFile (void)
 
virtual void SetInterpolator (InterpolatorType *_arg)
 
virtual void SetTransform (const TransformType *_arg)
 
virtual void WriteToFile (void) const
 
- Public Member Functions inherited from elastix::ResamplerBase< TElastix >
virtual void AfterEachIterationBase (void)
 
virtual void AfterEachResolutionBase (void)
 
virtual void AfterRegistrationBase (void)
 
virtual int BeforeAllTransformix (void)
 
virtual void BeforeRegistrationBase (void)
 
virtual void CreateItkResultImage (void)
 
virtual void CreateTransformParametersMap (ParameterMapType *paramsMap) const
 
virtual ITKBaseTypeGetAsITKBaseType (void)
 
virtual const ITKBaseTypeGetAsITKBaseType (void) const
 
 itkStaticConstMacro (ImageDimension, unsigned int, OutputImageType::ImageDimension)
 
virtual void ResampleAndWriteResultImage (const char *filename, const bool &showProgress=true)
 
virtual void WriteResultImage (OutputImageType *imageimage, const char *filename, const bool &showProgress=true)
 
- Public Member Functions inherited from elastix::BaseComponentSE< TElastix >
virtual ConfigurationTypeGetConfiguration (void) const
 
virtual ElastixTypeGetElastix (void) const
 
virtual RegistrationPointer GetRegistration (void) const
 
virtual void SetConfiguration (ConfigurationType *_arg)
 
virtual void SetElastix (ElastixType *_arg)
 
- Public Member Functions inherited from elastix::BaseComponent
virtual void AfterEachIteration (void)
 
virtual void AfterEachResolution (void)
 
virtual void AfterRegistration (void)
 
virtual int BeforeAll (void)
 
virtual int BeforeAllBase (void)
 
virtual void BeforeEachResolution (void)
 
virtual void BeforeEachResolutionBase (void)
 
std::string ConvertSecondsToDHMS (const double totalSeconds, const unsigned int precision) const
 
virtual const char * elxGetClassName (void) const
 
virtual const char * GetComponentLabel (void) const
 
virtual void SetComponentLabel (const char *label, unsigned int idx)
 

Static Public Member Functions

static Pointer New ()
 

Protected Types

typedef itk::AdvancedCombinationTransform< InterpolatorPrecisionType, OutputImageType::ImageDimension > AdvancedCombinationTransformType
 
typedef InterpolateCopierType::GPUExplicitInterpolatorPointer GPUExplicitInterpolatorPointer
 
typedef TransformCopierType::GPUComboTransformPointer GPUTransformPointer
 
typedef InterpolateCopierType::Pointer InterpolateCopierPointer
 
typedef itk::GPUInterpolatorCopier< OpenCLImageTypes, OpenCLImageDimentions, InterpolateImageFunctionType, floatInterpolateCopierType
 
typedef itk::InterpolateImageFunction< InterpolatorInputImageType, InterpolatorCoordRepTypeInterpolateImageFunctionType
 
typedef InterpolatorType::CoordRepType InterpolatorCoordRepType
 
typedef InterpolatorType::InputImageType InterpolatorInputImageType
 
typedef ResamplerBase< TElastix >::CoordRepType InterpolatorPrecisionType
 
typedef TransformCopierType::Pointer TransformCopierPointer
 
typedef itk::GPUAdvancedCombinationTransformCopier< OpenCLImageTypes, OpenCLImageDimentions, AdvancedCombinationTransformType, floatTransformCopierType
 

Protected Member Functions

void BeforeGenerateData (void)
 
virtual void GenerateData (void)
 
 OpenCLResampler ()
 
virtual ~OpenCLResampler ()
 
- Protected Member Functions inherited from elastix::ResamplerBase< TElastix >
 ResamplerBase ()
 
virtual void SetComponents (void)
 
virtual ~ResamplerBase ()
 
- Protected Member Functions inherited from elastix::BaseComponentSE< TElastix >
 BaseComponentSE ()
 
virtual ~BaseComponentSE ()
 
- Protected Member Functions inherited from elastix::BaseComponent
 BaseComponent ()
 
virtual ~BaseComponent ()
 

Private Member Functions

 OpenCLResampler (const Self &)
 
void operator= (const Self &)
 
void SwitchingToCPUAndReport (const bool configError)
 

Private Attributes

bool m_ContextCreated
 
GPUResamplerPointer m_GPUResampler
 
bool m_GPUResamplerCreated
 
bool m_GPUResamplerReady
 
InterpolateCopierPointer m_InterpolatorCopier
 
TransformCopierPointer m_TransformCopier
 
bool m_UseOpenCL
 

Additional Inherited Members

- Protected Attributes inherited from elastix::ResamplerBase< TElastix >
bool m_ShowProgress
 
- Protected Attributes inherited from elastix::BaseComponentSE< TElastix >
ConfigurationPointer m_Configuration
 
ElastixPointer m_Elastix
 
RegistrationPointer m_Registration
 

Member Typedef Documentation

template<class TElastix >
typedef itk::AdvancedCombinationTransform< InterpolatorPrecisionType, OutputImageType::ImageDimension > elastix::OpenCLResampler< TElastix >::AdvancedCombinationTransformType
protected

Definition at line 138 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::SmartPointer< const Self > elastix::OpenCLResampler< TElastix >::ConstPointer

Definition at line 68 of file elxOpenCLResampler.h.

Definition at line 154 of file elxOpenCLResampler.h.

template<class TElastix >
typedef GPUInputImageType::Pointer elastix::OpenCLResampler< TElastix >::GPUInputImagePointer

Definition at line 96 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::GPUImage< InputImagePixelType, InputImageType::ImageDimension > elastix::OpenCLResampler< TElastix >::GPUInputImageType

GPU Typedefs for GPU image and GPU resampler.

Definition at line 95 of file elxOpenCLResampler.h.

template<class TElastix >
typedef float elastix::OpenCLResampler< TElastix >::GPUInterpolatorPrecisionType

Definition at line 99 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::GPUImage< OutputImagePixelType, OutputImageType::ImageDimension > elastix::OpenCLResampler< TElastix >::GPUOutputImageType

Definition at line 98 of file elxOpenCLResampler.h.

template<class TElastix >
typedef GPUResamplerType::Pointer elastix::OpenCLResampler< TElastix >::GPUResamplerPointer

Definition at line 105 of file elxOpenCLResampler.h.

Definition at line 104 of file elxOpenCLResampler.h.

template<class TElastix >
typedef TransformCopierType::GPUComboTransformPointer elastix::OpenCLResampler< TElastix >::GPUTransformPointer
protected

Definition at line 143 of file elxOpenCLResampler.h.

template<class TElastix >
typedef InputImageType::PixelType elastix::OpenCLResampler< TElastix >::InputImagePixelType

Definition at line 87 of file elxOpenCLResampler.h.

template<class TElastix >
typedef Superclass1::InputImageType elastix::OpenCLResampler< TElastix >::InputImageType

Definition at line 86 of file elxOpenCLResampler.h.

template<class TElastix >
typedef InterpolateCopierType::Pointer elastix::OpenCLResampler< TElastix >::InterpolateCopierPointer
protected

Definition at line 153 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::GPUInterpolatorCopier< OpenCLImageTypes, OpenCLImageDimentions, InterpolateImageFunctionType, float > elastix::OpenCLResampler< TElastix >::InterpolateCopierType
protected

Definition at line 152 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::InterpolateImageFunction< InterpolatorInputImageType, InterpolatorCoordRepType > elastix::OpenCLResampler< TElastix >::InterpolateImageFunctionType
protected

Definition at line 149 of file elxOpenCLResampler.h.

template<class TElastix >
typedef InterpolatorType::CoordRepType elastix::OpenCLResampler< TElastix >::InterpolatorCoordRepType
protected

Definition at line 147 of file elxOpenCLResampler.h.

template<class TElastix >
typedef InterpolatorType::InputImageType elastix::OpenCLResampler< TElastix >::InterpolatorInputImageType
protected

Interpolator copier

Definition at line 146 of file elxOpenCLResampler.h.

template<class TElastix >
typedef ResamplerBase< TElastix >::CoordRepType elastix::OpenCLResampler< TElastix >::InterpolatorPrecisionType
protected

Transform copier

Definition at line 136 of file elxOpenCLResampler.h.

template<class TElastix >
typedef Superclass1::InterpolatorType elastix::OpenCLResampler< TElastix >::InterpolatorType

Typedefs inherited from the superclass.

Definition at line 83 of file elxOpenCLResampler.h.

template<class TElastix >
typedef OutputImageType::PixelType elastix::OpenCLResampler< TElastix >::OutputImagePixelType

Definition at line 90 of file elxOpenCLResampler.h.

template<class TElastix >
typedef OutputImageType::RegionType elastix::OpenCLResampler< TElastix >::OutputImageRegionType

Definition at line 91 of file elxOpenCLResampler.h.

template<class TElastix >
typedef Superclass1::OutputImageType elastix::OpenCLResampler< TElastix >::OutputImageType

Definition at line 89 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::SmartPointer< Self > elastix::OpenCLResampler< TElastix >::Pointer

Definition at line 67 of file elxOpenCLResampler.h.

template<class TElastix >
typedef OpenCLResampler elastix::OpenCLResampler< TElastix >::Self

Standard ITK-stuff.

Definition at line 60 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::ResampleImageFilter< typename ResamplerBase< TElastix >::InputImageType, typename ResamplerBase< TElastix >::OutputImageType, typename ResamplerBase< TElastix >::CoordRepType > elastix::OpenCLResampler< TElastix >::Superclass1

Definition at line 65 of file elxOpenCLResampler.h.

template<class TElastix >
typedef ResamplerBase< TElastix > elastix::OpenCLResampler< TElastix >::Superclass2

Definition at line 66 of file elxOpenCLResampler.h.

template<class TElastix >
typedef TransformCopierType::Pointer elastix::OpenCLResampler< TElastix >::TransformCopierPointer
protected

Definition at line 142 of file elxOpenCLResampler.h.

template<class TElastix >
typedef itk::GPUAdvancedCombinationTransformCopier< OpenCLImageTypes, OpenCLImageDimentions, AdvancedCombinationTransformType, float > elastix::OpenCLResampler< TElastix >::TransformCopierType
protected

Definition at line 141 of file elxOpenCLResampler.h.

template<class TElastix >
typedef Superclass1::TransformType elastix::OpenCLResampler< TElastix >::TransformType

Definition at line 84 of file elxOpenCLResampler.h.

Constructor & Destructor Documentation

template<class TElastix >
elastix::OpenCLResampler< TElastix >::OpenCLResampler ( )
protected

The constructor.

template<class TElastix >
virtual elastix::OpenCLResampler< TElastix >::~OpenCLResampler ( )
inlineprotectedvirtual

The destructor.

Definition at line 127 of file elxOpenCLResampler.h.

template<class TElastix >
elastix::OpenCLResampler< TElastix >::OpenCLResampler ( const Self )
private

The private constructor.

Member Function Documentation

template<class TElastix >
void elastix::OpenCLResampler< TElastix >::BeforeGenerateData ( void  )
protected

This method performs all configuration for GPU resampler.

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::BeforeRegistration ( void  )
virtual

Do some things before registration.

Reimplemented from elastix::BaseComponent.

template<class TElastix >
elastix::OpenCLResampler< TElastix >::elxClassNameMacro ( "OpenCLResampler< TElastix >"  )

Name of this class. Use this name in the parameter file to select this specific resampler.
example: (Resampler "OpenCLResampler")

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::GenerateData ( void  )
protectedvirtual

Executes GPU resampler.

template<class TElastix >
virtual const char* elastix::OpenCLResampler< TElastix >::GetClassName ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from elastix::ResamplerBase< TElastix >.

template<class TElastix >
static Pointer elastix::OpenCLResampler< TElastix >::New ( )
static

Method for creation through the object factory.

template<class TElastix >
void elastix::OpenCLResampler< TElastix >::operator= ( const Self )
private

The private copy constructor.

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::ReadFromFile ( void  )
virtual

Function to read parameters from a file.

Reimplemented from elastix::ResamplerBase< TElastix >.

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::SetInterpolator ( InterpolatorType _arg)
virtual

Set the interpolator.

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::SetTransform ( const TransformType _arg)
virtual

Set the transform.

template<class TElastix >
void elastix::OpenCLResampler< TElastix >::SwitchingToCPUAndReport ( const bool  configError)
private

Helper method to report switching to CPU mode.

template<class TElastix >
virtual void elastix::OpenCLResampler< TElastix >::WriteToFile ( void  ) const
virtual

Function to write parameters to a file.

Reimplemented from elastix::ResamplerBase< TElastix >.

Field Documentation

template<class TElastix >
bool elastix::OpenCLResampler< TElastix >::m_ContextCreated
private

Definition at line 171 of file elxOpenCLResampler.h.

template<class TElastix >
GPUResamplerPointer elastix::OpenCLResampler< TElastix >::m_GPUResampler
private

Definition at line 168 of file elxOpenCLResampler.h.

template<class TElastix >
bool elastix::OpenCLResampler< TElastix >::m_GPUResamplerCreated
private

Definition at line 170 of file elxOpenCLResampler.h.

template<class TElastix >
bool elastix::OpenCLResampler< TElastix >::m_GPUResamplerReady
private

Definition at line 169 of file elxOpenCLResampler.h.

template<class TElastix >
InterpolateCopierPointer elastix::OpenCLResampler< TElastix >::m_InterpolatorCopier
private

Definition at line 167 of file elxOpenCLResampler.h.

template<class TElastix >
TransformCopierPointer elastix::OpenCLResampler< TElastix >::m_TransformCopier
private

Definition at line 166 of file elxOpenCLResampler.h.

template<class TElastix >
bool elastix::OpenCLResampler< TElastix >::m_UseOpenCL
private

Definition at line 172 of file elxOpenCLResampler.h.



Generated on 04-09-2015 for elastix by doxygen 1.8.9.1 elastix logo