ITK  5.2.0
Insight Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members

#include <itkWatershedImageFilter.h>

+ Inheritance diagram for itk::WatershedImageFilter< TInputImage >:
+ Collaboration diagram for itk::WatershedImageFilter< TInputImage >:

Public Types

using IndexType = typename InputImageType::IndexType
 
using InputImageType = TInputImage
 
using OutputImageType = Image< IdentifierType, Self::ImageDimension >
 
using Pointer = SmartPointer< Self >
 
using RegionType = typename InputImageType::RegionType
 
using ScalarType = typename InputImageType::PixelType
 
using Self = WatershedImageFilter
 
using SizeType = typename InputImageType::SizeType
 
using Superclass = ImageToImageFilter< InputImageType, OutputImageType >
 
- Public Types inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
using ConstPointer = SmartPointer< const Self >
 
using InputImageConstPointer = typename InputImageType::ConstPointer
 
using InputImagePixelType = typename InputImageType::PixelType
 
using InputImagePointer = typename InputImageType::Pointer
 
using InputImageRegionType = typename InputImageType::RegionType
 
using InputImageType = TInputImage
 
using OutputImagePixelType = typename Superclass::OutputImagePixelType
 
using OutputImageRegionType = typename Superclass::OutputImageRegionType
 
using Pointer = SmartPointer< Self >
 
using Self = ImageToImageFilter
 
using Superclass = ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
 
- Public Types inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
using ConstPointer = SmartPointer< const Self >
 
using DataObjectIdentifierType = Superclass::DataObjectIdentifierType
 
using DataObjectPointer = DataObject::Pointer
 
using DataObjectPointerArraySizeType = Superclass::DataObjectPointerArraySizeType
 
using OutputImagePixelType = typename OutputImageType::PixelType
 
using OutputImagePointer = typename OutputImageType::Pointer
 
using OutputImageRegionType = typename OutputImageType::RegionType
 
using OutputImageType = Image< IdentifierType, TInputImage::ImageDimension >
 
using Pointer = SmartPointer< Self >
 
using Self = ImageSource
 
using Superclass = ProcessObject
 
- Public Types inherited from itk::ProcessObject
using ConstPointer = SmartPointer< const Self >
 
using DataObjectIdentifierType = DataObject::DataObjectIdentifierType
 
using DataObjectPointer = DataObject::Pointer
 
using DataObjectPointerArray = std::vector< DataObjectPointer >
 
using DataObjectPointerArraySizeType = DataObjectPointerArray::size_type
 
using MultiThreaderType = MultiThreaderBase
 
using NameArray = std::vector< DataObjectIdentifierType >
 
using Pointer = SmartPointer< Self >
 
using Self = ProcessObject
 
using Superclass = Object
 
- Public Types inherited from itk::Object
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = Object
 
using Superclass = LightObject
 
- Public Types inherited from itk::LightObject
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = LightObject
 

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother () const
 
void GenerateData () override
 
virtual const char * GetNameOfClass () const
 
- Public Member Functions inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
const InputImageTypeGetInput () const
 
const InputImageTypeGetInput (unsigned int idx) const
 
void PopBackInput () override
 
void PopFrontInput () override
 
virtual void PushBackInput (const InputImageType *input)
 
virtual void PushFrontInput (const InputImageType *input)
 
virtual void SetInput (const DataObjectIdentifierType &key, DataObject *input)
 
virtual void SetCoordinateTolerance (double _arg)
 
virtual double GetCoordinateTolerance () const
 
virtual void SetDirectionTolerance (double _arg)
 
virtual double GetDirectionTolerance () const
 
- Public Member Functions inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
OutputImageTypeGetOutput ()
 
const OutputImageTypeGetOutput () const
 
OutputImageTypeGetOutput (unsigned int idx)
 
virtual void GraftOutput (DataObject *graft)
 
virtual void GraftOutput (const DataObjectIdentifierType &key, DataObject *graft)
 
virtual void GraftNthOutput (unsigned int idx, DataObject *graft)
 
ProcessObject::DataObjectPointer MakeOutput (ProcessObject::DataObjectPointerArraySizeType idx) override
 
ProcessObject::DataObjectPointer MakeOutput (const ProcessObject::DataObjectIdentifierType &) override
 
- Public Member Functions inherited from itk::ProcessObject
virtual void AbortGenerateDataOff ()
 
virtual void AbortGenerateDataOn ()
 
virtual const bool & GetAbortGenerateData () const
 
DataObjectPointerArray GetIndexedInputs ()
 
DataObjectPointerArray GetIndexedOutputs ()
 
NameArray GetInputNames () const
 
DataObjectPointerArray GetInputs ()
 
DataObjectPointerArraySizeType GetNumberOfIndexedInputs () const
 
DataObjectPointerArraySizeType GetNumberOfIndexedOutputs () const
 
DataObjectPointerArraySizeType GetNumberOfInputs () const
 
DataObjectPointerArraySizeType GetNumberOfOutputs () const
 
virtual DataObjectPointerArraySizeType GetNumberOfValidRequiredInputs () const
 
NameArray GetOutputNames () const
 
DataObjectPointerArray GetOutputs ()
 
virtual float GetProgress () const
 
NameArray GetRequiredInputNames () const
 
bool HasInput (const DataObjectIdentifierType &key) const
 
bool HasOutput (const DataObjectIdentifierType &key) const
 
void IncrementProgress (float increment)
 
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)
 
virtual void SetReleaseDataFlag (bool val)
 
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 SetNumberOfWorkUnits (ThreadIdType _arg)
 
virtual const ThreadIdTypeGetNumberOfWorkUnits () const
 
MultiThreaderTypeGetMultiThreader () const
 
void SetMultiThreader (MultiThreaderType *threader)
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
unsigned long AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
const MetaDataDictionaryGetMetaDataDictionary () 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
 
void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetReferenceCount (int) override
 
void UnRegister () const noexcept override
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
void SetMetaDataDictionary (MetaDataDictionary &&rrhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual const std::string & GetObjectName () const
 
- Public Member Functions inherited from itk::LightObject
Pointer Clone () const
 
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
void Print (std::ostream &os, Indent indent=0) const
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
static void SetGlobalDefaultDirectionTolerance (double)
 
static double GetGlobalDefaultDirectionTolerance ()
 
static void SetGlobalDefaultCoordinateTolerance (double)
 
static double GetGlobalDefaultCoordinateTolerance ()
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool val)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Static Public Attributes

static constexpr unsigned int ImageDimension = TInputImage::ImageDimension
 
- Static Public Attributes inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
static constexpr unsigned int InputImageDimension
 
static constexpr unsigned int OutputImageDimension
 
- Static Public Attributes inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
static constexpr unsigned int OutputImageDimension
 
double m_Threshold { 0.0 }
 
double m_Level { 0.0 }
 
watershed::Segmenter< InputImageType >::Pointer m_Segmenter
 
watershed::SegmentTreeGenerator< ScalarType >::Pointer m_TreeGenerator
 
watershed::Relabeler< ScalarType, Self::ImageDimension >::Pointer m_Relabeler
 
unsigned long m_ObserverTag
 
bool m_LevelChanged
 
bool m_ThresholdChanged
 
bool m_InputChanged
 
TimeStamp m_GenerateDataMTime
 
void SetInput (const InputImageType *input) override
 
void SetInput (unsigned int i, const TInputImage *image) override
 
void SetThreshold (double)
 
virtual double GetThreshold () const
 
void SetLevel (double)
 
virtual double GetLevel () const
 
watershed::Segmenter< InputImageType >::OutputImageTypeGetBasicSegmentation ()
 
watershed::SegmentTreeGenerator< ScalarType >::SegmentTreeType * GetSegmentTree ()
 
void EnlargeOutputRequestedRegion (DataObject *data) override
 
 WatershedImageFilter ()
 
 ~WatershedImageFilter () override=default
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
void PrepareOutputs () override
 

Additional Inherited Members

- Protected Types inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
using InputToOutputRegionCopierType = ImageToImageFilterDetail::ImageRegionCopier< Self::OutputImageDimension, Self::InputImageDimension >
 
using OutputToInputRegionCopierType = ImageToImageFilterDetail::ImageRegionCopier< Self::InputImageDimension, Self::OutputImageDimension >
 
- Protected Member Functions inherited from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >
void PushBackInput (const DataObject *input) override
 
void PushFrontInput (const DataObject *input) override
 
 ImageToImageFilter ()
 
 ~ImageToImageFilter () override=default
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
void VerifyInputInformation () ITKv5_CONST override
 
void GenerateInputRequestedRegion () override
 
virtual void CallCopyOutputRegionToInputRegion (InputImageRegionType &destRegion, const OutputImageRegionType &srcRegion)
 
virtual void CallCopyInputRegionToOutputRegion (OutputImageRegionType &destRegion, const InputImageRegionType &srcRegion)
 
- Protected Member Functions inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
 ImageSource ()
 
 ~ImageSource () override=default
 
void GenerateData () override
 
void ClassicMultiThread (ThreadFunctionType callbackFunction)
 
virtual void ThreadedGenerateData (const OutputImageRegionType &region, ThreadIdType threadId)
 
virtual void DynamicThreadedGenerateData (const OutputImageRegionType &outputRegionForThread)
 
virtual void AllocateOutputs ()
 
virtual void BeforeThreadedGenerateData ()
 
virtual void AfterThreadedGenerateData ()
 
virtual const ImageRegionSplitterBaseGetImageRegionSplitter () const
 
virtual unsigned int SplitRequestedRegion (unsigned int i, unsigned int pieces, OutputImageRegionType &splitRegion)
 
virtual bool GetDynamicMultiThreading () const
 
virtual void SetDynamicMultiThreading (bool _arg)
 
virtual void DynamicMultiThreadingOn ()
 
virtual void DynamicMultiThreadingOff ()
 
- Protected Member Functions inherited from itk::ProcessObject
 ProcessObject ()
 
 ~ProcessObject () override
 
DataObjectGetInput (const DataObjectIdentifierType &key)
 
const DataObjectGetInput (const DataObjectIdentifierType &key) const
 
DataObjectGetInput (DataObjectPointerArraySizeType idx)
 
const DataObjectGetInput (DataObjectPointerArraySizeType idx) const
 
virtual void SetInput (const DataObjectIdentifierType &key, DataObject *input)
 
virtual void SetNthInput (DataObjectPointerArraySizeType idx, DataObject *input)
 
virtual void AddInput (DataObject *input)
 
virtual void RemoveInput (const DataObjectIdentifierType &key)
 
virtual void RemoveInput (DataObjectPointerArraySizeType)
 
DataObjectGetPrimaryInput ()
 
const DataObjectGetPrimaryInput () const
 
virtual void SetPrimaryInputName (const DataObjectIdentifierType &key)
 
virtual const char * GetPrimaryInputName () const
 
virtual void SetPrimaryInput (DataObject *object)
 
void SetNumberOfIndexedInputs (DataObjectPointerArraySizeType num)
 
virtual void SetNumberOfRequiredInputs (DataObjectPointerArraySizeType)
 
virtual const DataObjectPointerArraySizeTypeGetNumberOfRequiredInputs () const
 
bool RemoveRequiredInputName (const DataObjectIdentifierType &)
 
bool IsRequiredInputName (const DataObjectIdentifierType &) const
 
void SetRequiredInputNames (const NameArray &)
 
bool AddRequiredInputName (const DataObjectIdentifierType &)
 
bool AddRequiredInputName (const DataObjectIdentifierType &, DataObjectPointerArraySizeType idx)
 
void AddOptionalInputName (const DataObjectIdentifierType &)
 
void AddOptionalInputName (const DataObjectIdentifierType &, DataObjectPointerArraySizeType idx)
 
DataObjectGetOutput (const DataObjectIdentifierType &key)
 
const DataObjectGetOutput (const DataObjectIdentifierType &key) const
 
virtual void SetPrimaryOutputName (const DataObjectIdentifierType &key)
 
virtual const char * GetPrimaryOutputName () const
 
DataObjectGetOutput (DataObjectPointerArraySizeType i)
 
const DataObjectGetOutput (DataObjectPointerArraySizeType i) const
 
virtual void SetOutput (const DataObjectIdentifierType &name, DataObject *output)
 
virtual void RemoveOutput (const DataObjectIdentifierType &key)
 
DataObjectGetPrimaryOutput ()
 
const DataObjectGetPrimaryOutput () const
 
virtual void SetPrimaryOutput (DataObject *object)
 
virtual void SetNthOutput (DataObjectPointerArraySizeType idx, DataObject *output)
 
virtual void AddOutput (DataObject *output)
 
virtual void RemoveOutput (DataObjectPointerArraySizeType idx)
 
virtual void SetNumberOfRequiredOutputs (DataObjectPointerArraySizeType _arg)
 
virtual const DataObjectPointerArraySizeTypeGetNumberOfRequiredOutputs () const
 
void SetNumberOfIndexedOutputs (DataObjectPointerArraySizeType num)
 
DataObjectIdentifierType MakeNameFromInputIndex (DataObjectPointerArraySizeType idx) const
 
DataObjectIdentifierType MakeNameFromOutputIndex (DataObjectPointerArraySizeType idx) const
 
DataObjectPointerArraySizeType MakeIndexFromInputName (const DataObjectIdentifierType &name) const
 
DataObjectPointerArraySizeType MakeIndexFromOutputName (const DataObjectIdentifierType &name) const
 
bool IsIndexedInputName (const DataObjectIdentifierType &) const
 
bool IsIndexedOutputName (const DataObjectIdentifierType &) const
 
virtual void VerifyPreconditions () ITKv5_CONST
 
virtual void GenerateOutputRequestedRegion (DataObject *output)
 
virtual void GenerateOutputInformation ()
 
virtual void PropagateResetPipeline ()
 
virtual void ReleaseInputs ()
 
virtual void CacheInputReleaseDataFlags ()
 
virtual void RestoreInputReleaseDataFlags ()
 
virtual bool GetThreaderUpdateProgress () const
 
virtual void ThreaderUpdateProgressOn ()
 
virtual void ThreaderUpdateProgressOff ()
 
virtual void SetThreaderUpdateProgress (bool arg)
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
 ~Object () override
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &timeStamp)
 
- 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 ()
 
- Static Protected Member Functions inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
static const ImageRegionSplitterBaseGetGlobalDefaultSplitter ()
 
static ITK_THREAD_RETURN_FUNCTION_CALL_CONVENTION ThreaderCallback (void *arg)
 
- Static Protected Member Functions inherited from itk::ProcessObject
static constexpr float progressFixedToFloat (uint32_t fixed)
 
static uint32_t progressFloatToFixed (float f)
 
- Protected Attributes inherited from itk::ImageSource< Image< IdentifierType, TInputImage::ImageDimension > >
bool m_DynamicMultiThreading
 
- Protected Attributes inherited from itk::ProcessObject
bool m_Updating
 
TimeStamp m_OutputInformationMTime
 
- Protected Attributes inherited from itk::LightObject
std::atomic< int > m_ReferenceCount
 

Detailed Description

template<typename TInputImage>
class itk::WatershedImageFilter< TInputImage >

A low-level image analysis algorithm that automatically produces a hierarchy of segmented, labeled images from a scalar-valued image input.

Overview and terminology
This filter implements a non-streaming version of an image segmentation algorithm commonly known as "watershed segmentation". Watershed segmentation gets its name from the manner in which the algorithm segments regions into catchment basins. If a function $ f $ is a continuous height function defined over an image domain, then a catchment basin is defined as the set of points whose paths of steepest descent terminate at the same local minimum of $ f $.
The choice of height function (input) depends on the application, and the basic watershed algorithm operates independently of that choice. For intensity-based image data, you might typically use some sort of gradient magnitude calculation as input. (see itk::GradientMagnitudeImageFilter)
The watershed algorithm proceeds in several steps. First, an initial classification of all points into catchment basin regions is done by tracing each point down its path of steepest descent to a local minima. Next, neighboring regions and the boundaries between them are analyzed according to some saliency measure (such as minimum boundary height) to produce a tree of merges among adjacent regions. These merges occur at different maximum saliency values. The collective set of all possible merges up to a specified saliency "flood level" is referred to in this documentation as a "merge tree". Metaphorically, the flood level is a value that reflects the amount of precipitation that is rained into the catchment basins. As the flood level rises, boundaries between adjacent segments erode and those segments merge. The minimum value of the flood level is zero and the maximum value is the difference between the highest and lowest values in the input image.
Note that once the initial analysis and segmentation is done to produce the merge tree, it is trivial to produce a hierarchy of labeled images in constant time. The complexity of the algorithm is in the computation of the merge tree. Once that tree has been created, the initial segmented image can be relabeled to reflect any maximum saliency value found in the tree by simply identifying a subset of segment merges from the tree.
Implementational details
This filter is a wrapper for several lower level process objects (watershed algorithm components in the namespace "watershed"). For a more complete picture of the implementation, refer to the documentation of those components. The component classes were designed to operate in either a data-streaming or a non-data-streaming mode. The pipeline constructed in this class' GenerateData() method does not support streaming, but is the common use case for the components.
Description of the input to this filter
The input to this filter is a scalar itk::Image of any dimensionality. This input image is assumed to represent some sort of height function or edge map based on the original image that you want to segment (such as would be produced by itk::GradientMagnitudeImageFilter). This filter does not do any pre-processing on its input other than a thresholding step. The algorithm does not explicitly require that the input be of any particular data type, but floating point or double precision data is recommended.
The recommended pre-processing for scalar image input to this algorithm is to use one of the itk::AnisotropicDiffusionImageFilter subclasses to smooth the original image and then perform some sort of edge calculation based on gradients or curvature.
Description of the output of this filter
This filter will produce an itk::Image of IdentifierType integer type and of the same dimensionality as the input image. The IdentifierType output image is referred to as the "labeled image" in this documentation. Each pixel in the image is assigned an IdentifierType integer label that groups it within a connected region.
Some notes on filter parameters
Two parameters control the output of this filter, Threshold and Level. The units of both parameters are percentage points of the maximum height value in the input.
Threshold is used to set the absolute minimum height value used during processing. Raising this threshold percentage effectively decreases the number of local minima in the input, resulting in an initial segmentation with fewer regions. The assumption is that the shallow regions that thresholding removes are of of less interest.
The Level parameter controls the depth of metaphorical flooding of the image. That is, it sets the maximum saliency value of interest in the result. Raising and lowering the Level influences the number of segments in the basic segmentation that are merged to produce the final output. A level of 1.0 is analogous to flooding the image up to a depth that is 100 percent of the maximum value in the image. A level of 0.0 produces the basic segmentation, which will typically be very oversegmented. Level values of interest are typically low (i.e. less than about 0.40 or 40% ), since higher values quickly start to undersegment the image.
The Level parameter can be used to create a hierarchy of output images in constant time once an initial segmentation is done. A typical scenario might go like this: For the initial execution of the filter, set the Level to the maximum saliency value that you anticipate might be of interest. Once the initial Update() of this process object has finished, the Level can be manipulated anywhere below the initial setting without triggering a full update of the segmentation mini-pipeline. All that is now be required to produce the new output is a simple relabeling of the output image.
Threshold and Level parameters are controlled through the class' Get/SetThreshold() and Get/SetLevel() methods.
ITK Sphinx Examples:
Examples
Examples/Segmentation/WatershedSegmentation1.cxx, Examples/Segmentation/WatershedSegmentation2.cxx, SphinxExamples/src/Core/Common/UseParallelizeImageRegion/Code.cxx, and SphinxExamples/src/Segmentation/Watersheds/SegmentWithWatershedImageFilter/Code.cxx.

Definition at line 149 of file itkWatershedImageFilter.h.

Member Typedef Documentation

◆ IndexType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::IndexType = typename InputImageType::IndexType

Definition at line 170 of file itkWatershedImageFilter.h.

◆ InputImageType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::InputImageType = TInputImage

The type of input image.

Definition at line 159 of file itkWatershedImageFilter.h.

◆ OutputImageType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::OutputImageType = Image<IdentifierType, Self::ImageDimension>

The type of output image.

Definition at line 165 of file itkWatershedImageFilter.h.

◆ Pointer

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::Pointer = SmartPointer<Self>

Smart pointer type alias support

Definition at line 179 of file itkWatershedImageFilter.h.

◆ RegionType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::RegionType = typename InputImageType::RegionType

Other convenient type alias

Definition at line 168 of file itkWatershedImageFilter.h.

◆ ScalarType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::ScalarType = typename InputImageType::PixelType

Typedef support for the input image scalar value type.

Definition at line 176 of file itkWatershedImageFilter.h.

◆ Self

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::Self = WatershedImageFilter

Standard "Self" type alias.

Definition at line 156 of file itkWatershedImageFilter.h.

◆ SizeType

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::SizeType = typename InputImageType::SizeType

Definition at line 169 of file itkWatershedImageFilter.h.

◆ Superclass

template<typename TInputImage >
using itk::WatershedImageFilter< TInputImage >::Superclass = ImageToImageFilter<InputImageType, OutputImageType>

Standard super class type alias support

Definition at line 173 of file itkWatershedImageFilter.h.

Constructor & Destructor Documentation

◆ WatershedImageFilter()

template<typename TInputImage >
itk::WatershedImageFilter< TInputImage >::WatershedImageFilter ( )
protected

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

◆ ~WatershedImageFilter()

template<typename TInputImage >
itk::WatershedImageFilter< TInputImage >::~WatershedImageFilter ( )
overrideprotecteddefault

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Member Function Documentation

◆ CreateAnother()

template<typename TInputImage >
virtual::itk::LightObject::Pointer itk::WatershedImageFilter< TInputImage >::CreateAnother ( ) const
virtual

Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.

Reimplemented from itk::Object.

◆ EnlargeOutputRequestedRegion()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::EnlargeOutputRequestedRegion ( DataObject data)
overridevirtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Reimplemented from itk::ProcessObject.

◆ GenerateData()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::GenerateData ( )
overridevirtual

Standard process object method. This filter is not multithreaded.

Reimplemented from itk::ProcessObject.

◆ GetBasicSegmentation()

template<typename TInputImage >
watershed::Segmenter<InputImageType>::OutputImageType* itk::WatershedImageFilter< TInputImage >::GetBasicSegmentation ( )
inline

Get the basic segmentation from the Segmenter member filter.

Definition at line 239 of file itkWatershedImageFilter.h.

References itk::ProcessObject::Update().

◆ GetLevel()

template<typename TInputImage >
virtual double itk::WatershedImageFilter< TInputImage >::GetLevel ( ) const
virtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

◆ GetNameOfClass()

template<typename TInputImage >
virtual const char* itk::WatershedImageFilter< TInputImage >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods)

Reimplemented from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >.

◆ GetSegmentTree()

template<typename TInputImage >
watershed::SegmentTreeGenerator<ScalarType>::SegmentTreeType* itk::WatershedImageFilter< TInputImage >::GetSegmentTree ( )
inline

Get the segmentation tree from from the TreeGenerator member filter.

Definition at line 248 of file itkWatershedImageFilter.h.

References itk::watershed::SegmentTreeGenerator< TScalar >::GetOutputSegmentTree().

◆ GetThreshold()

template<typename TInputImage >
virtual double itk::WatershedImageFilter< TInputImage >::GetThreshold ( ) const
virtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

◆ New()

template<typename TInputImage >
static Pointer itk::WatershedImageFilter< TInputImage >::New ( )
static

Method for creation through the object factory.

◆ PrepareOutputs()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::PrepareOutputs ( )
overrideprotectedvirtual

An opportunity to Allocate/Deallocate bulk data.

Reimplemented from itk::ProcessObject.

◆ PrintSelf()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
overrideprotectedvirtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Reimplemented from itk::ProcessObject.

◆ SetInput() [1/2]

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::SetInput ( const InputImageType input)
inlineoverridevirtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Reimplemented from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >.

Definition at line 195 of file itkWatershedImageFilter.h.

References itk::ProcessObject::SetNthInput().

◆ SetInput() [2/2]

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::SetInput ( unsigned int  i,
const TInputImage *  image 
)
inlineoverridevirtual

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Reimplemented from itk::ImageToImageFilter< TInputImage, Image< IdentifierType, TInputImage::ImageDimension > >.

Definition at line 211 of file itkWatershedImageFilter.h.

◆ SetLevel()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::SetLevel ( double  )

Set/Get the flood level for generating the merge tree from the initial segmentation

◆ SetThreshold()

template<typename TInputImage >
void itk::WatershedImageFilter< TInputImage >::SetThreshold ( double  )

Set/Get the input thresholding parameter. Units are a percentage of the maximum depth in the image.

Member Data Documentation

◆ ImageDimension

template<typename TInputImage >
constexpr unsigned int itk::WatershedImageFilter< TInputImage >::ImageDimension = TInputImage::ImageDimension
staticconstexpr

Dimension of the input and output images.

Definition at line 162 of file itkWatershedImageFilter.h.

◆ m_GenerateDataMTime

template<typename TInputImage >
TimeStamp itk::WatershedImageFilter< TInputImage >::m_GenerateDataMTime
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 305 of file itkWatershedImageFilter.h.

◆ m_InputChanged

template<typename TInputImage >
bool itk::WatershedImageFilter< TInputImage >::m_InputChanged
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 303 of file itkWatershedImageFilter.h.

◆ m_Level

template<typename TInputImage >
double itk::WatershedImageFilter< TInputImage >::m_Level { 0.0 }
private

The percentage of the maximum saliency value among adjacencies in the segments of the initial segmentation to which "flooding" of the image should occur. A tree of segment merges is calculated up to this level.

Definition at line 287 of file itkWatershedImageFilter.h.

◆ m_LevelChanged

template<typename TInputImage >
bool itk::WatershedImageFilter< TInputImage >::m_LevelChanged
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 301 of file itkWatershedImageFilter.h.

◆ m_ObserverTag

template<typename TInputImage >
unsigned long itk::WatershedImageFilter< TInputImage >::m_ObserverTag
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 299 of file itkWatershedImageFilter.h.

◆ m_Relabeler

template<typename TInputImage >
watershed::Relabeler<ScalarType, Self::ImageDimension>::Pointer itk::WatershedImageFilter< TInputImage >::m_Relabeler
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 297 of file itkWatershedImageFilter.h.

◆ m_Segmenter

template<typename TInputImage >
watershed::Segmenter<InputImageType>::Pointer itk::WatershedImageFilter< TInputImage >::m_Segmenter
private

The component parts of the segmentation algorithm. These objects must save state between calls to GenerateData() so that the computationally expensive execution of segment tree generation is not unnecessarily repeated.

Definition at line 293 of file itkWatershedImageFilter.h.

◆ m_Threshold

template<typename TInputImage >
double itk::WatershedImageFilter< TInputImage >::m_Threshold { 0.0 }
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 281 of file itkWatershedImageFilter.h.

◆ m_ThresholdChanged

template<typename TInputImage >
bool itk::WatershedImageFilter< TInputImage >::m_ThresholdChanged
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 302 of file itkWatershedImageFilter.h.

◆ m_TreeGenerator

template<typename TInputImage >
watershed::SegmentTreeGenerator<ScalarType>::Pointer itk::WatershedImageFilter< TInputImage >::m_TreeGenerator
private

A Percentage of the maximum depth (max - min pixel value) in the input image. This percentage will be used to threshold the minimum values in the image.

Definition at line 295 of file itkWatershedImageFilter.h.


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