SimpleITK  1.3.0.dev466
Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Friends | List of all members
itk::simple::ShapeDetectionLevelSetImageFilter Class Reference

Segments structures in images based on a user supplied edge potential map. More...

#include <sitkShapeDetectionLevelSetImageFilter.h>

+ Inheritance diagram for itk::simple::ShapeDetectionLevelSetImageFilter:
+ Collaboration diagram for itk::simple::ShapeDetectionLevelSetImageFilter:

Public Types

typedef RealPixelIDTypeList PixelIDTypeList
 
typedef ShapeDetectionLevelSetImageFilter Self
 
- Public Types inherited from itk::simple::ImageFilter< 0 >
typedef ImageFilter Self
 
- Public Types inherited from itk::simple::ProcessObject
typedef ProcessObject Self
 

Public Member Functions

Image Execute (const Image &initialImage, const Image &featureImage)
 
Image Execute (const Image &initialImage, const Image &featureImage, double maximumRMSError, double propagationScaling, double curvatureScaling, uint32_t numberOfIterations, bool reverseExpansionDirection)
 
double GetCurvatureScaling () const
 
uint32_t GetElapsedIterations () const
 Number of iterations run. More...
 
double GetMaximumRMSError () const
 
std::string GetName () const
 
uint32_t GetNumberOfIterations () const
 
double GetPropagationScaling () const
 
bool GetReverseExpansionDirection () const
 
double GetRMSChange () const
 The Root Mean Square of the levelset upon termination. More...
 
SelfReverseExpansionDirectionOff ()
 
SelfReverseExpansionDirectionOn ()
 
SelfSetCurvatureScaling (double CurvatureScaling)
 
SelfSetMaximumRMSError (double MaximumRMSError)
 
SelfSetNumberOfIterations (uint32_t NumberOfIterations)
 
SelfSetPropagationScaling (double PropagationScaling)
 
SelfSetReverseExpansionDirection (bool ReverseExpansionDirection)
 
 ShapeDetectionLevelSetImageFilter ()
 
std::string ToString () const
 
virtual ~ShapeDetectionLevelSetImageFilter ()
 
- Public Member Functions inherited from itk::simple::ImageFilter< 0 >
 ImageFilter ()
 
virtual ~ImageFilter ()=0
 
- Public Member Functions inherited from itk::simple::ProcessObject
virtual void Abort ()
 
virtual int AddCommand (itk::simple::EventEnum event, itk::simple::Command &cmd)
 Add a Command Object to observer the event. More...
 
virtual float GetProgress () const
 An Active Measurement of the progress of execution. More...
 
virtual bool HasCommand (itk::simple::EventEnum event) const
 Query of this object has any registered commands for event. More...
 
 ProcessObject ()
 
virtual void RemoveAllCommands ()
 Remove all registered commands. More...
 
virtual ~ProcessObject ()
 
virtual void DebugOn ()
 
virtual void DebugOff ()
 
virtual bool GetDebug () const
 
virtual void SetDebug (bool debugFlag)
 
virtual void SetNumberOfThreads (unsigned int n)
 
virtual unsigned int GetNumberOfThreads () const
 

Private Types

typedef Image(Self::* MemberFunctionType) (const Image *initialImage, const Image *featureImage)
 

Private Member Functions

template<class TImageType >
Image ExecuteInternal (const Image *initialImage, const Image *featureImage)
 

Private Attributes

double m_CurvatureScaling
 
uint32_t m_ElapsedIterations
 
double m_MaximumRMSError
 
nsstd::auto_ptr< detail::MemberFunctionFactory< MemberFunctionType > > m_MemberFactory
 
uint32_t m_NumberOfIterations
 
double m_PropagationScaling
 
bool m_ReverseExpansionDirection
 
double m_RMSChange
 

Friends

struct detail::MemberFunctionAddressor< MemberFunctionType >
 

Additional Inherited Members

- Static Public Member Functions inherited from itk::simple::ProcessObject
static bool GetGlobalDefaultDebug ()
 
static void GlobalDefaultDebugOff ()
 
static void GlobalDefaultDebugOn ()
 
static void SetGlobalDefaultDebug (bool debugFlag)
 
static void GlobalWarningDisplayOn ()
 
static void GlobalWarningDisplayOff ()
 
static void SetGlobalWarningDisplay (bool flag)
 
static bool GetGlobalWarningDisplay ()
 
static void SetGlobalDefaultNumberOfThreads (unsigned int n)
 
static unsigned int GetGlobalDefaultNumberOfThreads ()
 
static double GetGlobalDefaultCoordinateTolerance ()
 Access the global tolerance to determine congruent spaces. More...
 
static void SetGlobalDefaultCoordinateTolerance (double)
 Access the global tolerance to determine congruent spaces. More...
 
static double GetGlobalDefaultDirectionTolerance ()
 Access the global tolerance to determine congruent spaces. More...
 
static void SetGlobalDefaultDirectionTolerance (double)
 Access the global tolerance to determine congruent spaces. More...
 
- Protected Member Functions inherited from itk::simple::ProcessObject
virtual unsigned long AddITKObserver (const itk::EventObject &, itk::Command *)
 
virtual itk::ProcessObjectGetActiveProcess ()
 
virtual void OnActiveProcessDelete ()
 
virtual void onCommandDelete (const itk::simple::Command *cmd) SITK_NOEXCEPT
 
virtual void PreUpdate (itk::ProcessObject *p)
 
virtual void RemoveITKObserver (EventCommand &e)
 
- Protected Member Functions inherited from itk::simple::NonCopyable
 NonCopyable ()
 
- Static Protected Member Functions inherited from itk::simple::ImageFilter< 0 >
static void FixNonZeroIndex (TImageType *img)
 
- Static Protected Member Functions inherited from itk::simple::ProcessObject
template<class TImageType >
static TImageType::ConstPointer CastImageToITK (const Image &img)
 
template<class TImageType >
static Image CastITKToImage (TImageType *img)
 
template<class TPixelType , unsigned int VImageDimension, unsigned int VLength, template< typename, unsigned int > class TVector>
static Image CastITKToImage (itk::Image< TVector< TPixelType, VLength >, VImageDimension > *img)
 
static const itk::EventObjectGetITKEventObject (EventEnum e)
 
template<typename T >
static std::ostream & ToStringHelper (std::ostream &os, const T &v)
 
static std::ostream & ToStringHelper (std::ostream &os, const char &v)
 
static std::ostream & ToStringHelper (std::ostream &os, const signed char &v)
 
static std::ostream & ToStringHelper (std::ostream &os, const unsigned char &v)
 

Detailed Description

Segments structures in images based on a user supplied edge potential map.

IMPORTANT
The SegmentationLevelSetImageFilter class and the ShapeDetectionLevelSetFunction class contain additional information necessary to gain full understanding of how to use this filter.
OVERVIEW
This class is a level set method segmentation filter. An initial contour is propagated outwards (or inwards) until it ''sticks'' to the shape boundaries. This is done by using a level set speed function based on a user supplied edge potential map. This approach for segmentation follows that of Malladi et al (1995).
INPUTS
This filter requires two inputs. The first input is a initial level set. The initial level set is a real image which contains the initial contour/surface as the zero level set. For example, a signed distance function from the initial contour/surface is typically used. Note that for this algorithm the initial contour has to be wholly within (or wholly outside) the structure to be segmented.
The second input is the feature image. For this filter, this is the edge potential map. General characteristics of an edge potential map is that it has values close to zero in regions near the edges and values close to one inside the shape itself. Typically, the edge potential map is compute from the image gradient, for example:

\[ g(I) = 1 / ( 1 + | (\nabla * G)(I)| ) \]

\[ g(I) = \exp^{-|(\nabla * G)(I)|} \]

where $ I $ is image intensity and $ (\nabla * G) $ is the derivative of Gaussian operator.

See SegmentationLevelSetImageFilter and SparseFieldLevelSetImageFilter for more information on Inputs.
PARAMETERS
The PropagationScaling parameter can be used to switch from propagation outwards (POSITIVE scaling parameter) versus propagating inwards (NEGATIVE scaling parameter).

The smoothness of the resulting contour/surface can be adjusted using a combination of PropagationScaling and CurvatureScaling parameters. The larger the CurvatureScaling parameter, the smoother the resulting contour. The CurvatureScaling parameter should be non-negative for proper operation of this algorithm. To follow the implementation in Malladi et al paper, set the PropagtionScaling to $\pm 1.0$ and CurvatureScaling to $ \epsilon $ .

Note that there is no advection term for this filter. Setting the advection scaling will have no effect.

OUTPUTS
The filter outputs a single, scalar, real-valued image. Negative values in the output image represent the inside of the segmentated region and positive values in the image represent the outside of the segmented region. The zero crossings of the image correspond to the position of the propagating front.
See SparseFieldLevelSetImageFilter and SegmentationLevelSetImageFilter for more information.
REFERENCES
"Shape Modeling with Front Propagation: A Level Set Approach", R. Malladi, J. A. Sethian and B. C. Vermuri. IEEE Trans. on Pattern Analysis and Machine Intelligence, Vol 17, No. 2, pp 158-174, February 1995
See also
SegmentationLevelSetImageFilter
ShapeDetectionLevelSetFunction
SparseFieldLevelSetImageFilter
itk::simple::ShapeDetectionLevelSet for the procedural interface
itk::ShapeDetectionLevelSetImageFilter for the Doxygen on the original ITK class.

Definition at line 84 of file sitkShapeDetectionLevelSetImageFilter.h.

Member Typedef Documentation

typedef Image(Self::* itk::simple::ShapeDetectionLevelSetImageFilter::MemberFunctionType) (const Image *initialImage, const Image *featureImage)
private

Setup for member function dispatching

Definition at line 177 of file sitkShapeDetectionLevelSetImageFilter.h.

Define the pixels types supported by this filter

Definition at line 96 of file sitkShapeDetectionLevelSetImageFilter.h.

Definition at line 86 of file sitkShapeDetectionLevelSetImageFilter.h.

Constructor & Destructor Documentation

virtual itk::simple::ShapeDetectionLevelSetImageFilter::~ShapeDetectionLevelSetImageFilter ( )
virtual

Destructor

itk::simple::ShapeDetectionLevelSetImageFilter::ShapeDetectionLevelSetImageFilter ( )

Default Constructor that takes no arguments and initializes default parameters

Member Function Documentation

Image itk::simple::ShapeDetectionLevelSetImageFilter::Execute ( const Image initialImage,
const Image featureImage 
)

Execute the filter on the input image

Image itk::simple::ShapeDetectionLevelSetImageFilter::Execute ( const Image initialImage,
const Image featureImage,
double  maximumRMSError,
double  propagationScaling,
double  curvatureScaling,
uint32_t  numberOfIterations,
bool  reverseExpansionDirection 
)

Execute the filter on the input image with the given parameters

template<class TImageType >
Image itk::simple::ShapeDetectionLevelSetImageFilter::ExecuteInternal ( const Image initialImage,
const Image featureImage 
)
private
double itk::simple::ShapeDetectionLevelSetImageFilter::GetCurvatureScaling ( ) const
inline

Definition at line 122 of file sitkShapeDetectionLevelSetImageFilter.h.

uint32_t itk::simple::ShapeDetectionLevelSetImageFilter::GetElapsedIterations ( ) const
inline

Number of iterations run.

This is a measurement. Its value is updated in the Execute methods, so the value will only be valid after an execution.

Definition at line 149 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::GetMaximumRMSError ( ) const
inline

Definition at line 106 of file sitkShapeDetectionLevelSetImageFilter.h.

std::string itk::simple::ShapeDetectionLevelSetImageFilter::GetName ( ) const
inlinevirtual

Name of this class

Implements itk::simple::ProcessObject.

Definition at line 160 of file sitkShapeDetectionLevelSetImageFilter.h.

uint32_t itk::simple::ShapeDetectionLevelSetImageFilter::GetNumberOfIterations ( ) const
inline

Definition at line 130 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::GetPropagationScaling ( ) const
inline

Definition at line 114 of file sitkShapeDetectionLevelSetImageFilter.h.

bool itk::simple::ShapeDetectionLevelSetImageFilter::GetReverseExpansionDirection ( ) const
inline

Definition at line 142 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::GetRMSChange ( ) const
inline

The Root Mean Square of the levelset upon termination.

This is a measurement. Its value is updated in the Execute methods, so the value will only be valid after an execution.

Definition at line 157 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::ReverseExpansionDirectionOff ( )
inline

Definition at line 138 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::ReverseExpansionDirectionOn ( )
inline

Set the value of ReverseExpansionDirection to true or false respectfully.

Definition at line 137 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::SetCurvatureScaling ( double  CurvatureScaling)
inline

Definition at line 118 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::SetMaximumRMSError ( double  MaximumRMSError)
inline

Definition at line 102 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::SetNumberOfIterations ( uint32_t  NumberOfIterations)
inline

Definition at line 126 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::SetPropagationScaling ( double  PropagationScaling)
inline

Definition at line 110 of file sitkShapeDetectionLevelSetImageFilter.h.

Self& itk::simple::ShapeDetectionLevelSetImageFilter::SetReverseExpansionDirection ( bool  ReverseExpansionDirection)
inline

Definition at line 134 of file sitkShapeDetectionLevelSetImageFilter.h.

std::string itk::simple::ShapeDetectionLevelSetImageFilter::ToString ( ) const
virtual

Print ourselves out

Reimplemented from itk::simple::ProcessObject.

Friends And Related Function Documentation

Definition at line 181 of file sitkShapeDetectionLevelSetImageFilter.h.

Member Data Documentation

double itk::simple::ShapeDetectionLevelSetImageFilter::m_CurvatureScaling
private

Definition at line 191 of file sitkShapeDetectionLevelSetImageFilter.h.

uint32_t itk::simple::ShapeDetectionLevelSetImageFilter::m_ElapsedIterations
private

Definition at line 197 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::m_MaximumRMSError
private

Definition at line 187 of file sitkShapeDetectionLevelSetImageFilter.h.

nsstd::auto_ptr<detail::MemberFunctionFactory<MemberFunctionType> > itk::simple::ShapeDetectionLevelSetImageFilter::m_MemberFactory
private

Definition at line 183 of file sitkShapeDetectionLevelSetImageFilter.h.

uint32_t itk::simple::ShapeDetectionLevelSetImageFilter::m_NumberOfIterations
private

Definition at line 193 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::m_PropagationScaling
private

Definition at line 189 of file sitkShapeDetectionLevelSetImageFilter.h.

bool itk::simple::ShapeDetectionLevelSetImageFilter::m_ReverseExpansionDirection
private

Definition at line 195 of file sitkShapeDetectionLevelSetImageFilter.h.

double itk::simple::ShapeDetectionLevelSetImageFilter::m_RMSChange
private

Definition at line 199 of file sitkShapeDetectionLevelSetImageFilter.h.


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