Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType > Class Template Reference

Generates a histogram from a scalar image. More...

#include <itkMITKScalarImageToHistogramGenerator.h>

Inheritance diagram for itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >:
Collaboration diagram for itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >:

Public Types

typedef MITKScalarImageToHistogramGenerator Self
 Standard typedefs. More...
 
typedef Object Superclass
 
typedef SmartPointer< Self > Pointer
 
typedef SmartPointer< const Self > ConstPointer
 
typedef TImageType ImageType
 
typedef itk::Statistics::ImageToListSampleAdaptor< ImageType > AdaptorType
 
typedef AdaptorType::Pointer AdaptorPointer
 
typedef ImageType::PixelType PixelType
 
typedef itk::Statistics::Histogram< TMeasurementType, itk::Statistics::DenseFrequencyContainer2 > HistogramType
 
typedef itk::Statistics::SampleToHistogramFilter< AdaptorType, HistogramType > GeneratorType
 
typedef GeneratorType::Pointer GeneratorPointer
 
typedef HistogramType::Pointer HistogramPointer
 
typedef HistogramType::ConstPointer HistogramConstPointer
 

Public Member Functions

virtual const char * GetClassName () const
 
Pointer Clone () const
 
void Compute (void)
 Trigger the computation of the histogram. More...
 
void SetInput (const ImageType *image)
 Connect the input image for which the histogram is going to be computed. More...
 
const HistogramType * GetOutput () const
 Return the computed histogram. More...
 
void SetNumberOfBins (unsigned int numberOfBins)
 Set number of histogram bins. More...
 
void SetMarginalScale (double marginalScale)
 Set the marginal scale value to be passed to the histogram generator. More...
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 MITKScalarImageToHistogramGenerator ()
 Default constructor. Creates the adaptor and histogram generator. More...
 
 ~MITKScalarImageToHistogramGenerator () override
 Destructor. More...
 
void PrintSelf (std::ostream &os, Indent indent) const override
 Print the state of this object to an output stream. More...
 

Detailed Description

template<class TImageType, class TMeasurementType = typename TImageType::PixelType>
class itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >

Generates a histogram from a scalar image.

Adapts an ITK image into a list sample and uses SampleToHistogramFilter to compute a histogram. This is a MITK-specific variant that works with MITK image types.

Template Parameters
TImageTypeThe input image type.
TMeasurementTypeThe measurement type for histogram bins (defaults to pixel type).

Definition at line 35 of file itkMITKScalarImageToHistogramGenerator.h.

Member Typedef Documentation

◆ AdaptorPointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef AdaptorType::Pointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::AdaptorPointer

Definition at line 53 of file itkMITKScalarImageToHistogramGenerator.h.

◆ AdaptorType

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef itk::Statistics::ImageToListSampleAdaptor<ImageType> itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::AdaptorType

Definition at line 52 of file itkMITKScalarImageToHistogramGenerator.h.

◆ ConstPointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef SmartPointer<const Self> itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::ConstPointer

Definition at line 42 of file itkMITKScalarImageToHistogramGenerator.h.

◆ GeneratorPointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef GeneratorType::Pointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::GeneratorPointer

Definition at line 59 of file itkMITKScalarImageToHistogramGenerator.h.

◆ GeneratorType

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef itk::Statistics::SampleToHistogramFilter<AdaptorType, HistogramType> itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::GeneratorType

Definition at line 57 of file itkMITKScalarImageToHistogramGenerator.h.

◆ HistogramConstPointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef HistogramType::ConstPointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::HistogramConstPointer

Definition at line 62 of file itkMITKScalarImageToHistogramGenerator.h.

◆ HistogramPointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef HistogramType::Pointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::HistogramPointer

Definition at line 61 of file itkMITKScalarImageToHistogramGenerator.h.

◆ HistogramType

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef itk::Statistics::Histogram<TMeasurementType, itk::Statistics::DenseFrequencyContainer2> itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::HistogramType

Definition at line 56 of file itkMITKScalarImageToHistogramGenerator.h.

◆ ImageType

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef TImageType itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::ImageType

Definition at line 51 of file itkMITKScalarImageToHistogramGenerator.h.

◆ PixelType

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef ImageType::PixelType itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::PixelType

Definition at line 54 of file itkMITKScalarImageToHistogramGenerator.h.

◆ Pointer

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef SmartPointer<Self> itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::Pointer

Definition at line 41 of file itkMITKScalarImageToHistogramGenerator.h.

◆ Self

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef MITKScalarImageToHistogramGenerator itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::Self

Standard typedefs.

Definition at line 39 of file itkMITKScalarImageToHistogramGenerator.h.

◆ Superclass

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
typedef Object itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::Superclass

Definition at line 40 of file itkMITKScalarImageToHistogramGenerator.h.

Constructor & Destructor Documentation

◆ MITKScalarImageToHistogramGenerator()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::MITKScalarImageToHistogramGenerator ( )
protected

Default constructor. Creates the adaptor and histogram generator.

◆ ~MITKScalarImageToHistogramGenerator()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::~MITKScalarImageToHistogramGenerator ( )
inlineoverrideprotected

Destructor.

Definition at line 95 of file itkMITKScalarImageToHistogramGenerator.h.

Member Function Documentation

◆ Clone()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
Pointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::Clone ( ) const

◆ Compute()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
void itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::Compute ( void  )

Trigger the computation of the histogram.

◆ GetClassName()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
virtual const char* itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::GetClassName ( ) const
virtual

Run-time type information (and related methods).

◆ GetOutput()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
const HistogramType* itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::GetOutput ( ) const

Return the computed histogram.

Warning
This output is only valid after the Compute() method has been invoked.
Returns
Pointer to the computed histogram.
See also
Compute

◆ New()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
static Pointer itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::New ( )
static

standard New() method support

◆ PrintSelf()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
void itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
overrideprotected

Print the state of this object to an output stream.

◆ SetInput()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
void itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::SetInput ( const ImageType *  image)

Connect the input image for which the histogram is going to be computed.

Parameters
imageThe input scalar image.

◆ SetMarginalScale()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
void itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::SetMarginalScale ( double  marginalScale)

Set the marginal scale value to be passed to the histogram generator.

Parameters
marginalScaleThe marginal scale value.

◆ SetNumberOfBins()

template<class TImageType , class TMeasurementType = typename TImageType::PixelType>
void itk::Statistics::MITKScalarImageToHistogramGenerator< TImageType, TMeasurementType >::SetNumberOfBins ( unsigned int  numberOfBins)

Set number of histogram bins.

Parameters
numberOfBinsThe number of bins for the histogram.

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