ITK  4.6.0
Insight Segmentation and Registration Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Attributes | List of all members
itk::watershed::SegmentTreeGenerator< TScalar > Class Template Reference

#include <itkWatershedSegmentTreeGenerator.h>

+ Inheritance diagram for itk::watershed::SegmentTreeGenerator< TScalar >:
+ Collaboration diagram for itk::watershed::SegmentTreeGenerator< TScalar >:

Detailed Description

template<typename TScalar>
class itk::watershed::SegmentTreeGenerator< TScalar >

This filter is a process object class that implements a step in the N-d watershed segmentation algorithm. It produces an ordered list (SegmentTree) of binary merges between segments at increasing saliency levels. This filter is used in conjunction with WatershedSegmenter and WatershedRelabeler to process an initial segmentation into a final relabeled volume. See itk::WatershedImageFilter for an overview of watershed segmentation.

Inputs
There are two inputs to this filter, the second is optional. (1) A table of segments (SegmentTable) derived from a labeled image. (2) Optionally, a table of predetermined equivalencies among segments (EquivalencyTable), necessary for streaming applications where segments may be joined across streamed chunk boundaries. The flag Merge must be set to true to enable this functionality.
Outputs
The output of this filter is a list of binary merges of segments at increasing saliency. This is the data structure itk::watershed::WatershedSegmentTree referred to as a ``merge tree'' in the itk::WatershedImageFilter documentation.
Parameters
There are two parameters to this filter described below.
FloodLevel is specified as a percentage (0.0 - 1.0) of the maximum possible saliency value in the initial image from which the segment table was derived. A value of 0.0 calculates no merges. A value of 1.0 calculates all of the potential merges that can occur as the FloodLevel is increased to the maximum saliency value. Typically, there is no need to calculate merges past about 40% of the total depth. Because this is the most computationally intensive piece of the watershed segmentation algorithm, it is a good idea to tune this parameter as low as possible on larger volumes.
Merge is a boolean flag indicating whether or not to pre-merge the segments marked as equivalent in the EquivalencyTable. This is only useful for streaming applications and is turned off by default. (TRUE == merge, FALSE == do not merge).
See Also
itk::WatershedImageFilter

Definition at line 78 of file itkWatershedSegmentTreeGenerator.h.

Public Types

typedef SmartPointer< const SelfConstPointer
 
typedef DataObject::Pointer DataObjectPointer
 
typedef
ProcessObject::DataObjectPointerArraySizeType 
DataObjectPointerArraySizeType
 
typedef EquivalencyTable EquivalencyTableType
 
typedef OneWayEquivalencyTable OneWayEquivalencyTableType
 
typedef
OneWayEquivalencyTableType::Pointer 
OneWayEquivalencyTableTypePointer
 
typedef SmartPointer< SelfPointer
 
typedef TScalar ScalarType
 
typedef SegmentTable< ScalarTypeSegmentTableType
 
typedef SegmentTableType::Pointer SegmentTableTypePointer
 
typedef SegmentTree< ScalarTypeSegmentTreeType
 
typedef SegmentTreeType::Pointer SegmentTreeTypePointer
 
typedef SegmentTreeGenerator Self
 
typedef ProcessObject Superclass
 
- Public Types inherited from itk::ProcessObject
typedef SmartPointer< const SelfConstPointer
 
typedef
DataObject::DataObjectIdentifierType 
DataObjectIdentifierType
 
typedef DataObject::Pointer DataObjectPointer
 
typedef std::vector
< DataObjectPointer
DataObjectPointerArray
 
typedef
DataObjectPointerArray::size_type 
DataObjectPointerArraySizeType
 
typedef std::vector
< DataObjectIdentifierType
NameArray
 
typedef SmartPointer< SelfPointer
 
typedef ProcessObject Self
 
typedef Object Superclass
 
- Public Types inherited from itk::Object
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef Object Self
 
typedef LightObject Superclass
 
- Public Types inherited from itk::LightObject
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef LightObject Self
 

Public Member Functions

virtual void GenerateData () ITK_OVERRIDE
 
virtual double GetFloodLevel () const
 
EquivalencyTableTypeGetInputEquivalencyTable ()
 
SegmentTableTypeGetInputSegmentTable ()
 
SegmentTreeTypeGetOutputSegmentTree ()
 
virtual DataObjectPointer MakeOutput (DataObjectPointerArraySizeType idx) ITK_OVERRIDE
 
void SetFloodLevel (double)
 
void SetInputEquivalencyTable (EquivalencyTableType *eq)
 
void SetInputSegmentTable (SegmentTableType *st)
 
virtual void SetMerge (bool _arg)
 
virtual bool GetMerge () const
 
virtual void SetHighestCalculatedFloodLevel (double _arg)
 
virtual double GetHighestCalculatedFloodLevel () const
 
virtual void SetConsumeInput (bool _arg)
 
virtual bool GetConsumeInput () const
 
- Public Member Functions inherited from itk::ProcessObject
virtual void AbortGenerateDataOff ()
 
virtual void AbortGenerateDataOn ()
 
virtual void EnlargeOutputRequestedRegion (DataObject *)
 
virtual const bool & GetAbortGenerateData () const
 
NameArray GetInputNames () const
 
MultiThreader * GetMultiThreader () const
 
DataObjectPointerArraySizeType GetNumberOfIndexedInputs () const
 
DataObjectPointerArraySizeType GetNumberOfInputs () const
 
DataObjectPointerArraySizeType GetNumberOfOutputs () const
 
virtual
DataObjectPointerArraySizeType 
GetNumberOfValidRequiredInputs () const
 
NameArray GetOutputNames () const
 
virtual const float & GetProgress () const
 
NameArray GetRequiredInputNames () const
 
bool HasInput (const DataObjectIdentifierType &key) const
 
bool HasOutput (const DataObjectIdentifierType &key) const
 
virtual DataObjectPointer MakeOutput (const DataObjectIdentifierType &)
 
virtual void PrepareOutputs ()
 
virtual void PropagateRequestedRegion (DataObject *output)
 
virtual void ResetPipeline ()
 
virtual void SetAbortGenerateData (bool _arg)
 
virtual void Update ()
 
virtual void UpdateLargestPossibleRegion ()
 
virtual void UpdateOutputData (DataObject *output)
 
virtual void UpdateOutputInformation ()
 
void UpdateProgress (float progress)
 
DataObjectPointerArray GetInputs ()
 
DataObjectPointerArray GetOutputs ()
 
DataObjectPointerArray GetIndexedInputs ()
 
DataObjectPointerArray GetIndexedOutputs ()
 
DataObjectPointerArraySizeType GetNumberOfIndexedOutputs () const
 
void SetProgress (float progress)
 
virtual void SetReleaseDataFlag (bool flag)
 
virtual bool GetReleaseDataFlag () const
 
void ReleaseDataFlagOn ()
 
void ReleaseDataFlagOff ()
 
virtual void SetReleaseDataBeforeUpdateFlag (bool _arg)
 
virtual const bool & GetReleaseDataBeforeUpdateFlag () const
 
virtual void ReleaseDataBeforeUpdateFlagOn ()
 
virtual void ReleaseDataBeforeUpdateFlagOff ()
 
virtual void SetNumberOfThreads (ThreadIdType _arg)
 
virtual const ThreadIdTypeGetNumberOfThreads () const
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
MetaDataDictionaryGetMetaDataDictionary (void)
 
const MetaDataDictionaryGetMetaDataDictionary (void) const
 
virtual ModifiedTimeType GetMTime () const
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
virtual void Register () const ITK_OVERRIDE
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
virtual void SetReferenceCount (int) ITK_OVERRIDE
 
virtual void UnRegister () const ITK_OVERRIDE
 
virtual void SetObjectName (std::string _arg)
 
virtual const std::string & GetObjectName () const
 
- Public Member Functions inherited from itk::LightObject
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
 itkCloneMacro (Self)
 
void Print (std::ostream &os, Indent indent=0) const
 

Static Public Member Functions

static void MergeSegments (SegmentTableTypePointer, OneWayEquivalencyTableTypePointer, const IdentifierType, const IdentifierType)
 
static void PruneMergeSegments (SegmentTableTypePointer, OneWayEquivalencyTableTypePointer, const IdentifierType, const IdentifierType, ScalarType)
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool flag)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Protected Member Functions

void CompileMergeList (SegmentTableTypePointer, SegmentTreeTypePointer)
 
void ExtractMergeHierarchy (SegmentTableTypePointer, SegmentTreeTypePointer)
 
virtual void GenerateInputRequestedRegion () ITK_OVERRIDE
 
virtual void GenerateOutputRequestedRegion (DataObject *output) ITK_OVERRIDE
 
void MergeEquivalencies ()
 
void operator= (const Self &)
 
virtual void PrintSelf (std::ostream &os, Indent indent) const ITK_OVERRIDE
 
 SegmentTreeGenerator ()
 
 SegmentTreeGenerator (const Self &)
 
virtual ~SegmentTreeGenerator ()
 
- Protected Member Functions inherited from itk::ProcessObject
virtual void AddInput (DataObject *input)
 
virtual void AddOutput (DataObject *output)
 
virtual void CacheInputReleaseDataFlags ()
 
virtual void GenerateOutputInformation ()
 
virtual const
DataObjectPointerArraySizeType
GetNumberOfRequiredOutputs () const
 
bool IsIndexedInputName (const DataObjectIdentifierType &) const
 
bool IsIndexedOutputName (const DataObjectIdentifierType &) const
 
 itkLegacyMacro (virtual void RemoveOutput(DataObject *output))
 
 itkLegacyMacro (void SetNumberOfOutputs(DataObjectPointerArraySizeType num))
 
 itkLegacyMacro (virtual void RemoveInput(DataObject *input))
 
 itkLegacyMacro (void SetNumberOfInputs(DataObjectPointerArraySizeType num))
 
DataObjectPointerArraySizeType MakeIndexFromInputName (const DataObjectIdentifierType &name) const
 
DataObjectPointerArraySizeType MakeIndexFromOutputName (const DataObjectIdentifierType &name) const
 
DataObjectIdentifierType MakeNameFromInputIndex (DataObjectPointerArraySizeType idx) const
 
DataObjectIdentifierType MakeNameFromOutputIndex (DataObjectPointerArraySizeType idx) const
 
 ProcessObject ()
 
virtual void PropagateResetPipeline ()
 
virtual void ReleaseInputs ()
 
virtual void RemoveInput (const DataObjectIdentifierType &key)
 
virtual void RemoveInput (DataObjectPointerArraySizeType)
 
virtual void RemoveOutput (const DataObjectIdentifierType &key)
 
virtual void RemoveOutput (DataObjectPointerArraySizeType idx)
 
virtual void RestoreInputReleaseDataFlags ()
 
virtual void SetInput (const DataObjectIdentifierType &key, DataObject *input)
 
virtual void SetNthInput (DataObjectPointerArraySizeType num, DataObject *input)
 
virtual void SetNthOutput (DataObjectPointerArraySizeType num, DataObject *output)
 
void SetNumberOfIndexedInputs (DataObjectPointerArraySizeType num)
 
void SetNumberOfIndexedOutputs (DataObjectPointerArraySizeType num)
 
virtual void SetNumberOfRequiredOutputs (DataObjectPointerArraySizeType _arg)
 
virtual void SetOutput (const DataObjectIdentifierType &key, DataObject *output)
 
virtual void SetPrimaryInput (DataObject *input)
 
virtual void SetPrimaryOutput (DataObject *output)
 
virtual void VerifyInputInformation ()
 
virtual void VerifyPreconditions ()
 
 ~ProcessObject ()
 
DataObjectGetInput (const DataObjectIdentifierType &key)
 
const DataObjectGetInput (const DataObjectIdentifierType &key) const
 
DataObjectGetInput (DataObjectPointerArraySizeType idx)
 
const DataObjectGetInput (DataObjectPointerArraySizeType idx) const
 
virtual void PushBackInput (const DataObject *input)
 
virtual void PopBackInput ()
 
virtual void PushFrontInput (const DataObject *input)
 
virtual void PopFrontInput ()
 
DataObjectGetPrimaryInput ()
 
const DataObjectGetPrimaryInput () const
 
virtual void SetPrimaryInputName (const DataObjectIdentifierType &key)
 
virtual const char * GetPrimaryInputName (void) const
 
virtual void SetNumberOfRequiredInputs (DataObjectPointerArraySizeType)
 
virtual const
DataObjectPointerArraySizeType
GetNumberOfRequiredInputs () const
 
bool AddRequiredInputName (const DataObjectIdentifierType &)
 
bool AddRequiredInputName (const DataObjectIdentifierType &, DataObjectPointerArraySizeType idx)
 
bool RemoveRequiredInputName (const DataObjectIdentifierType &)
 
bool IsRequiredInputName (const DataObjectIdentifierType &) const
 
void SetRequiredInputNames (const NameArray &)
 
DataObjectGetOutput (const DataObjectIdentifierType &key)
 
const DataObjectGetOutput (const DataObjectIdentifierType &key) const
 
virtual void SetPrimaryOutputName (const DataObjectIdentifierType &key)
 
virtual const char * GetPrimaryOutputName (void) const
 
DataObjectGetOutput (DataObjectPointerArraySizeType idx)
 
const DataObjectGetOutput (DataObjectPointerArraySizeType idx) const
 
DataObjectGetPrimaryOutput ()
 
const DataObjectGetPrimaryOutput () const
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &time)
 
virtual ~Object ()
 
- 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 ()
 

Private Types

typedef itksys::hash_map
< IdentifierType, bool,
itksys::hash< IdentifierType > > 
HashMapType
 

Private Attributes

bool m_ConsumeInput
 
double m_FloodLevel
 
double m_HighestCalculatedFloodLevel
 
bool m_Merge
 
OneWayEquivalencyTableType::Pointer m_MergedSegmentsTable
 
static Pointer New ()
 
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const char * GetNameOfClass () const
 

Additional Inherited Members

- Protected Types inherited from itk::LightObject
typedef int InternalReferenceCountType
 
- Protected Attributes inherited from itk::ProcessObject
TimeStamp m_OutputInformationMTime
 
bool m_Updating
 
- Protected Attributes inherited from itk::LightObject
InternalReferenceCountType m_ReferenceCount
 
SimpleFastMutexLock m_ReferenceCountLock
 

Member Typedef Documentation

template<typename TScalar>
typedef SmartPointer< const Self > itk::watershed::SegmentTreeGenerator< TScalar >::ConstPointer

Definition at line 86 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef DataObject::Pointer itk::watershed::SegmentTreeGenerator< TScalar >::DataObjectPointer

Definition at line 99 of file itkWatershedSegmentTreeGenerator.h.

Standard itk::ProcessObject subclass method.

Definition at line 196 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef EquivalencyTable itk::watershed::SegmentTreeGenerator< TScalar >::EquivalencyTableType

Definition at line 97 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef itksys::hash_map< IdentifierType, bool, itksys::hash< IdentifierType > > itk::watershed::SegmentTreeGenerator< TScalar >::HashMapType
private

Definition at line 228 of file itkWatershedSegmentTreeGenerator.h.

Definition at line 98 of file itkWatershedSegmentTreeGenerator.h.

Definition at line 103 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef SmartPointer< Self > itk::watershed::SegmentTreeGenerator< TScalar >::Pointer

Definition at line 85 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef TScalar itk::watershed::SegmentTreeGenerator< TScalar >::ScalarType

Convenient type definitions

Definition at line 90 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef SegmentTable< ScalarType > itk::watershed::SegmentTreeGenerator< TScalar >::SegmentTableType

Definition at line 95 of file itkWatershedSegmentTreeGenerator.h.

Typedefs to avoid internal compiler error bug on Microsoft VC++

Definition at line 102 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef SegmentTree< ScalarType > itk::watershed::SegmentTreeGenerator< TScalar >::SegmentTreeType

Definition at line 96 of file itkWatershedSegmentTreeGenerator.h.

Definition at line 104 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef SegmentTreeGenerator itk::watershed::SegmentTreeGenerator< TScalar >::Self

Standard itk smart pointer declarations

Definition at line 83 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
typedef ProcessObject itk::watershed::SegmentTreeGenerator< TScalar >::Superclass

Definition at line 84 of file itkWatershedSegmentTreeGenerator.h.

Constructor & Destructor Documentation

template<typename TScalar>
itk::watershed::SegmentTreeGenerator< TScalar >::SegmentTreeGenerator ( )
protected
template<typename TScalar>
virtual itk::watershed::SegmentTreeGenerator< TScalar >::~SegmentTreeGenerator ( )
inlineprotectedvirtual

Definition at line 202 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
itk::watershed::SegmentTreeGenerator< TScalar >::SegmentTreeGenerator ( const Self )
inlineprotected

Definition at line 203 of file itkWatershedSegmentTreeGenerator.h.

Member Function Documentation

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::CompileMergeList ( SegmentTableTypePointer  ,
SegmentTreeTypePointer   
)
protected

Generates an initial list of all potentential merges in the segment table.

template<typename TScalar>
virtual::itk::LightObject::Pointer itk::watershed::SegmentTreeGenerator< TScalar >::CreateAnother ( void  ) const
virtual

Method for creation through the object factory.

Reimplemented from itk::Object.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::ExtractMergeHierarchy ( SegmentTableTypePointer  ,
SegmentTreeTypePointer   
)
protected

Compiles a list of all the actual segment merges up to the specified flood level, recomputing new potential merges as it goes.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::GenerateData ( )
virtual

Standard non-threaded itk pipeline method

Reimplemented from itk::ProcessObject.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::GenerateInputRequestedRegion ( )
protectedvirtual

What is the input requested region that is required to produce the output requested region? By default, the largest possible region is always required but this is overridden in many subclasses. For instance, for an image processing filter where an output pixel is a simple function of an input pixel, the input requested region will be set to the output requested region. For an image processing filter where an output pixel is a function of the pixels in a neighborhood of an input pixel, then the input requested region will need to be larger than the output requested region (to avoid introducing artificial boundary conditions). This function should never request an input region that is outside the the input largest possible region (i.e. implementations of this method should crop the input requested region at the boundaries of the input largest possible region).

Reimplemented from itk::ProcessObject.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::GenerateOutputRequestedRegion ( DataObject output)
protectedvirtual

Methods required by the itk pipeline

Reimplemented from itk::ProcessObject.

template<typename TScalar>
virtual bool itk::watershed::SegmentTreeGenerator< TScalar >::GetConsumeInput ( ) const
virtual

Get/Set a flag that prevents the filter from copying its input segment table before executing. This can be enabled to conserve memory, especially in streaming applications where memory is a concern. If enabled, the input to this filter must always be re-executed on updates. Default is false.

template<typename TScalar>
virtual double itk::watershed::SegmentTreeGenerator< TScalar >::GetFloodLevel ( ) const
virtual
template<typename TScalar>
virtual double itk::watershed::SegmentTreeGenerator< TScalar >::GetHighestCalculatedFloodLevel ( ) const
virtual

Get/Set HighestCalculatedFloodLevel. HighestCalculatedFloodLevel keeps track of the highest level this filter has computed. It is used to prevent unnecessary re-execution of the filter.

template<typename TScalar>
EquivalencyTableType* itk::watershed::SegmentTreeGenerator< TScalar >::GetInputEquivalencyTable ( )
inline

Definition at line 131 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
SegmentTableType* itk::watershed::SegmentTreeGenerator< TScalar >::GetInputSegmentTable ( )
inline

Get/Set the input table of segments to process

Definition at line 107 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
virtual bool itk::watershed::SegmentTreeGenerator< TScalar >::GetMerge ( ) const
virtual

Get/Set a boolean flag indicating whether or not to pre-merge the segments marked as equivalent in the EquivalencyTable. This is only useful for streaming applications and is turned off by default. (TRUE == merge, FALSE == do not merge).

template<typename TScalar>
virtual const char* itk::watershed::SegmentTreeGenerator< TScalar >::GetNameOfClass ( ) const
virtual

Method for creation through the object factory.

Reimplemented from itk::ProcessObject.

template<typename TScalar>
SegmentTreeType* itk::watershed::SegmentTreeGenerator< TScalar >::GetOutputSegmentTree ( )
inline

Get/Set the output data

Definition at line 138 of file itkWatershedSegmentTreeGenerator.h.

Referenced by itk::WatershedImageFilter< TInputImage >::GetSegmentTree().

template<typename TScalar>
virtual DataObjectPointer itk::watershed::SegmentTreeGenerator< TScalar >::MakeOutput ( DataObjectPointerArraySizeType  idx)
virtual

Make a DataObject of the correct type to used as the specified output. Every ProcessObject subclass must be able to create a DataObject that can be used as a specified output. This method is automatically called when DataObject::DisconnectPipeline() is called. DataObject::DisconnectPipeline, disconnects a data object from being an output of its current source. When the data object is disconnected, the ProcessObject needs to construct a replacement output data object so that the ProcessObject is in a valid state. So DataObject::DisconnectPipeline eventually calls ProcessObject::MakeOutput. Note that MakeOutput always returns a itkSmartPointer to a DataObject. ImageSource and MeshSource override this method to create the correct type of image and mesh respectively. If a filter has multiple outputs of different types, then that filter must provide an implementation of MakeOutput().

Reimplemented from itk::ProcessObject.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::MergeEquivalencies ( )
protected
template<typename TScalar>
static void itk::watershed::SegmentTreeGenerator< TScalar >::MergeSegments ( SegmentTableTypePointer  ,
OneWayEquivalencyTableTypePointer  ,
const IdentifierType  ,
const IdentifierType   
)
static

Performs a merge of two segments in a SegmentTable according to criteria specific to this algorithm.

template<typename TScalar>
static Pointer itk::watershed::SegmentTreeGenerator< TScalar >::New ( )
static

Method for creation through the object factory.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::operator= ( const Self )
inlineprotected

Definition at line 204 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
protectedvirtual

Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from itk::ProcessObject.

template<typename TScalar>
static void itk::watershed::SegmentTreeGenerator< TScalar >::PruneMergeSegments ( SegmentTableTypePointer  ,
OneWayEquivalencyTableTypePointer  ,
const IdentifierType  ,
const IdentifierType  ,
ScalarType   
)
static

This method should not be used. It will be removed in future versions of this filter.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::SetConsumeInput ( bool  _arg)
virtual

Get/Set a flag that prevents the filter from copying its input segment table before executing. This can be enabled to conserve memory, especially in streaming applications where memory is a concern. If enabled, the input to this filter must always be re-executed on updates. Default is false.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::SetFloodLevel ( double  )

Get/Set FloodLevel. FloodLevel is specified as a percentage (0.0 - 1.0) of the maximum possible saliency value in the initial image from which the segment table was derived. A value of 0.0 calculates no merges. A value of 1.0 calculates all of the potential merges that can occur as the FloodLevel is increased to the maximum saliency value.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::SetHighestCalculatedFloodLevel ( double  _arg)
virtual

Get/Set HighestCalculatedFloodLevel. HighestCalculatedFloodLevel keeps track of the highest level this filter has computed. It is used to prevent unnecessary re-execution of the filter.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::SetInputEquivalencyTable ( EquivalencyTableType eq)
inline

Get/Set input table of equivalencies to pre-merge before running the tree generator algorithm. Only useful for streaming applications

Definition at line 126 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
void itk::watershed::SegmentTreeGenerator< TScalar >::SetInputSegmentTable ( SegmentTableType st)
inline

Definition at line 112 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
virtual void itk::watershed::SegmentTreeGenerator< TScalar >::SetMerge ( bool  _arg)
virtual

Get/Set a boolean flag indicating whether or not to pre-merge the segments marked as equivalent in the EquivalencyTable. This is only useful for streaming applications and is turned off by default. (TRUE == merge, FALSE == do not merge).

Member Data Documentation

template<typename TScalar>
bool itk::watershed::SegmentTreeGenerator< TScalar >::m_ConsumeInput
private

Definition at line 225 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
double itk::watershed::SegmentTreeGenerator< TScalar >::m_FloodLevel
private

Definition at line 224 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
double itk::watershed::SegmentTreeGenerator< TScalar >::m_HighestCalculatedFloodLevel
private

This value keeps track of the highest level this filter has been calculated. m_FloodLevel can be manipulated anywhere below this level without re-executing the filter, preventing unnecessary updates.

Definition at line 236 of file itkWatershedSegmentTreeGenerator.h.

Referenced by itk::watershed::SegmentTreeGenerator< ScalarType >::SetInputSegmentTable().

template<typename TScalar>
bool itk::watershed::SegmentTreeGenerator< TScalar >::m_Merge
private

Definition at line 223 of file itkWatershedSegmentTreeGenerator.h.

template<typename TScalar>
OneWayEquivalencyTableType::Pointer itk::watershed::SegmentTreeGenerator< TScalar >::m_MergedSegmentsTable
private

Definition at line 230 of file itkWatershedSegmentTreeGenerator.h.


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