Seg3D  2.4
Seg3D is a free volume segmentation and processing tool developed by the NIH Center for Integrative Biomedical Computing at the University of Utah Scientific Computing and Imaging (SCI) Institute.
Classes | Public Types | Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
itk::ImageMosaicVarianceMetric< TImage, TInterpolator > Class Template Reference

Computes mean pixel variance within the overlapping regions of a mosaic. More...

#include <itkImageMosaicVarianceMetric.h>

Inheritance diagram for itk::ImageMosaicVarianceMetric< TImage, TInterpolator >:

Classes

class  image_data_t
 

Public Types

typedef ImageMosaicVarianceMetric Self
 
typedef SingleValuedCostFunction Superclass
 
typedef SmartPointer< SelfPointer
 
typedef SmartPointer< const SelfConstPointer
 
typedef TInterpolator interpolator_t
 
typedef TImage image_t
 
typedef TImage::PixelType pixel_t
 
typedef itk::Image< unsigned char, itkGetStaticConstMacro(ImageDimension)> mask_t
 
typedef Transform< Superclass::ParametersValueType, itkGetStaticConstMacro(ImageDimension), itkGetStaticConstMacro(ImageDimension)> transform_t
 
typedef transform_t::InputPointType point_t
 
typedef transform_t::ParametersType params_t
 
typedef transform_t::JacobianType jacobian_t
 
typedef float scalar_t
 
typedef CovariantVector< scalar_t, itkGetStaticConstMacro(ImageDimension)> gradient_pixel_t
 
typedef Image< gradient_pixel_t, itkGetStaticConstMacro(ImageDimension)> gradient_image_t
 
typedef GradientRecursiveGaussianImageFilter< image_t, gradient_image_t > gradient_filter_t
 
typedef Superclass::MeasureType measure_t
 
typedef Superclass::DerivativeType derivative_t
 

Public Member Functions

 itkNewMacro (Self)
 
 itkTypeMacro (ImageMosaicVarianceMetric, SingleValuedCostFunction)
 
 itkStaticConstMacro (ImageDimension, unsigned int, TImage::ImageDimension)
 
 itkGetConstReferenceMacro (NumberOfPixelsCounted, unsigned long)
 
 itkSetMacro (MosaicRegion, typename image_t::RegionType)
 
 itkGetConstReferenceMacro (MosaicRegion, typename image_t::RegionType)
 
void setup_param_map (const std::vector< bool > &params_shared, const std::vector< bool > &params_active)
 
params_t GetTransformParameters () const
 
void SetTransformParameters (const params_t &parameters) const
 
unsigned int GetNumberOfParameters () const
 
virtual void Initialize () throw (ExceptionObject)
 
measure_t GetValue (const params_t &parameters) const
 
void GetDerivative (const params_t &parameters, derivative_t &derivative) const
 
void GetValueAndDerivative (const params_t &parameters, measure_t &value, derivative_t &derivative) const
 
void CalcMosaicBBox (point_t &mosaic_min, point_t &mosaic_max, std::vector< point_t > &image_min, std::vector< point_t > &image_max) const
 
image_t::Pointer variance (measure_t &max_var, measure_t &avg_var) const
 
image_t::Pointer variance (const typename TImage::SpacingType &sp, const pnt2d_t &mosaic_min, const pnt2d_t &mosaic_max, measure_t &max_var, measure_t &avg_var) const
 
image_t::Pointer variance (const typename TImage::SpacingType &sp, const pnt2d_t &mosaic_min, const typename TImage::SizeType &sz, measure_t &max_var, measure_t &avg_var) const
 
image_t::Pointer variance () const
 

Public Attributes

std::vector< typename image_t::ConstPointer > image_
 
std::vector< typename mask_t::ConstPointer > mask_
 
std::vector< typename transform_t::Pointer > transform_
 
std::vector< typename interpolator_t::Pointer > interpolator_
 
std::vector< typename gradient_image_t::ConstPointer > gradient_
 
std::vector< std::vector< unsigned int > > address_
 
unsigned int n_shared_
 
unsigned int n_unique_
 
std::vector< bool > param_active_
 

Protected Member Functions

void PrintSelf (std::ostream &os, Indent indent) const
 

Protected Attributes

unsigned long m_NumberOfPixelsCounted
 

Detailed Description

template<class TImage, class TInterpolator>
class itk::ImageMosaicVarianceMetric< TImage, TInterpolator >

Computes mean pixel variance within the overlapping regions of a mosaic.

Member Typedef Documentation

template<class TImage , class TInterpolator >
typedef Superclass::DerivativeType itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::derivative_t

Type of the derivative.

template<class TImage , class TInterpolator >
typedef TInterpolator itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::interpolator_t

Type of the moving Image.

template<class TImage , class TInterpolator >
typedef Superclass::MeasureType itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::measure_t

Type of the measure.

template<class TImage , class TInterpolator >
typedef float itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::scalar_t

Gaussian filter to compute the gradient of the mosaic images

template<class TImage , class TInterpolator >
typedef ImageMosaicVarianceMetric itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::Self

Standard class typedefs.

template<class TImage , class TInterpolator >
typedef Transform<Superclass::ParametersValueType, itkGetStaticConstMacro(ImageDimension), itkGetStaticConstMacro(ImageDimension)> itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::transform_t

Type of the transform base class

Member Function Documentation

template<class TImage , class TInterpolator >
void itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::GetDerivative ( const params_t &  parameters,
derivative_t derivative 
) const
inline

virtual: Get the derivatives of the match measure.

template<class TImage , class TInterpolator >
unsigned int itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::GetNumberOfParameters ( ) const

virtual: Return the number of parameters required by the transforms.

NOTE: this function will fail if SetupTransformParameterOffsets has not been called yet.

template<class TImage , class TInterpolator >
params_t itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::GetTransformParameters ( ) const

Concatenate parameters of each transform into one big vector.

NOTE: this function will fail if SetupTransformParameterOffsets has not been called yet.

template<class TImage , class TInterpolator >
measure_t itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::GetValue ( const params_t &  parameters) const
inline

virtual: Get the value for single valued optimizers.

template<class TImage , class TInterpolator >
void itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::GetValueAndDerivative ( const params_t &  parameters,
measure_t value,
derivative_t derivative 
) const

virtual: Get value and derivatives for multiple valued optimizers.

template<class TImage , class TInterpolator >
virtual void itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::Initialize ( )
throw (ExceptionObject
)
virtual

Initialize the Metric by making sure that all the components are present and plugged together correctly.

template<class TImage , class TInterpolator >
itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::itkGetConstReferenceMacro ( NumberOfPixelsCounted  ,
unsigned  long 
)

Get the number of pixels considered in the computation.

template<class TImage , class TInterpolator >
itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::itkNewMacro ( Self  )

Method for creation through the object factory.

template<class TImage , class TInterpolator >
itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::itkSetMacro ( MosaicRegion  ,
typename image_t::RegionType   
)

Set/Get the region over which the metric will be computed

template<class TImage , class TInterpolator >
itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::itkStaticConstMacro ( ImageDimension  ,
unsigned  int,
TImage::ImageDimension   
)

Constant for the image dimension

template<class TImage , class TInterpolator >
itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::itkTypeMacro ( ImageMosaicVarianceMetric< TImage, TInterpolator >  ,
SingleValuedCostFunction   
)

Run-time type information (and related methods).

template<class TImage , class TInterpolator >
void itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::SetTransformParameters ( const params_t &  parameters) const

virtual: Set the parameters defining the transforms:

NOTE: this function will fail if SetupTransformParameterOffsets has not been called yet.

template<class TImage , class TInterpolator >
void itk::ImageMosaicVarianceMetric< TImage, TInterpolator >::setup_param_map ( const std::vector< bool > &  params_shared,
const std::vector< bool > &  params_active 
)

Initialize transform parameter offsets.

Setup the mapping from individual transform parameter indices to the corresponding indices in the concatenated parameter vector.

The radial distortion transforms typically share the same parameters across all images in the mosaic, therefore it is slow and unnecessary to duplicate the same parameters parameters in the concatenated parameters vector. Instead, the parameters are store only once. This also allows a significant speedup of the optimization. On the other hand, translation parameters are typically unique for each image.

params_shared is a vector of boolean flags indicating which of the transform parameters are shared (true) or unique (false).

NOTE: this function will fail if the transform_ has not been initialized.


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