ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itk::utils Namespace Reference

Typedefs

using IndexPairType = std::pair<unsigned int, unsigned int>
 

Functions

template<typename TIndicesArrayType>
ITK_TEMPLATE_EXPORT std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > ComputeAllPermutations (const std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > &uniqueIndices)
 
template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > ComputeAllPossibleIndices (const unsigned int &order)
 
template<unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT unsigned int ComputeMaxNumberOfLevels (const Size< VImageDimension > &inputSize, const unsigned int &scaleFactor)
 
IsotropicWavelets_EXPORT unsigned int ComputeNumberOfComponents (const unsigned int &order, const unsigned int &dimension)
 
template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT void ComputeUniqueIndices (TIndicesArrayType subIndex, std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > &uniqueIndices, unsigned int init=0)
 
IsotropicWavelets_EXPORT long Factorial (long n)
 
IsotropicWavelets_EXPORT IndexPairType IndexToLevelBandSteerablePyramid (unsigned int linearIndex, unsigned int levels, unsigned int bands)
 
template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT bool LessOrEqualIndiceComparisson (const TIndicesArrayType &rhs, const TIndicesArrayType &lhs)
 

Typedef Documentation

◆ IndexPairType

using itk::utils::IndexPairType = std::pair<unsigned int, unsigned int>

Definition at line 34 of file itkWaveletUtilities.h.

Function Documentation

◆ ComputeAllPermutations()

template<typename TIndicesArrayType>
ITK_TEMPLATE_EXPORT std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > itk::utils::ComputeAllPermutations ( const std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > & uniqueIndices)

Compute all the permutations from a set of uniqueIndices.

Definition at line 108 of file itkRieszUtilities.h.

Referenced by itk::RieszFrequencyFunction< typename InputImageType::PixelType, ImageDimension >::ComputeAllPermutations(), and ComputeAllPossibleIndices().

◆ ComputeAllPossibleIndices()

template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > itk::utils::ComputeAllPossibleIndices ( const unsigned int & order)

Compute all possible indices given an order. The order imposes the constraint:

\[ \sum_{i}^{ImageDimension} \text{index}[i] = \text{order} \]

where \( \text{index}[i]>=0 \)

Definition at line 132 of file itkRieszUtilities.h.

References ComputeAllPermutations(), and ComputeUniqueIndices().

Referenced by itk::RieszFrequencyFunction< typename InputImageType::PixelType, ImageDimension >::ComputeAllPossibleIndices().

◆ ComputeMaxNumberOfLevels()

template<unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT unsigned int itk::utils::ComputeMaxNumberOfLevels ( const Size< VImageDimension > & inputSize,
const unsigned int & scaleFactor )

$; where each $J_i$ is the number of integer divisions that can be done with the $i$ size and the scale factor. returns 1 if any size is not divisible by the scale factor.

Definition at line 72 of file itkWaveletUtilities.h.

References itk::FixedArray< TValue, VLength >::Begin(), itk::FixedArray< TValue, VLength >::End(), itk::FixedArray< TValue, VLength >::Fill(), and itk::Math::FloatAlmostEqual().

◆ ComputeNumberOfComponents()

IsotropicWavelets_EXPORT unsigned int itk::utils::ComputeNumberOfComponents ( const unsigned int & order,
const unsigned int & dimension )

Compute number of components p(N, d), where N = Order, d = Dimension. p(N,d) = (N + d - 1)!/( (d-1)! N! )

Parameters
orderN of the Riesz transform
dimensiond of the image
Returns
NumberOfComponents given the order for the ImageDimension.

Referenced by itk::RieszFrequencyFunction< typename InputImageType::PixelType, ImageDimension >::ComputeNumberOfComponents(), and itk::RieszRotationMatrix< VImageDimension >::SetOrder().

◆ ComputeUniqueIndices()

template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT void itk::utils::ComputeUniqueIndices ( TIndicesArrayType subIndex,
std::set< TIndicesArrayType, std::greater< TIndicesArrayType > > & uniqueIndices,
unsigned int init = 0 )

Compute all possible unique indices given the subIndex: (X, 0, ..., 0). Where X can be any number greater than 0, but probably want to use this->m_Order.

TIndicesArrayType = std::vector<unsigned int> or any std array type with begin(), end() methods.

Parameters
subIndexIndex (X,0,...,0) where X > 0.
uniqueIndicesReference to set that store results.
initposition to evaluate subIndex. Needed for recursion purposes.

Definition at line 63 of file itkRieszUtilities.h.

References ComputeUniqueIndices().

Referenced by ComputeAllPossibleIndices(), itk::RieszFrequencyFunction< typename InputImageType::PixelType, ImageDimension >::ComputeUniqueIndices(), and ComputeUniqueIndices().

◆ Factorial()

IsotropicWavelets_EXPORT long itk::utils::Factorial ( long n)

◆ IndexToLevelBandSteerablePyramid()

IsotropicWavelets_EXPORT IndexPairType itk::utils::IndexToLevelBandSteerablePyramid ( unsigned int linearIndex,
unsigned int levels,
unsigned int bands )

Get the (Level,Band) from a linear index output. The index corresponding to the low-pass image is the last one, corresponding to the IndexPairType(this->GetLevels(), 0).

In a steerable pyramid: TotalOutputs = 1 + Levels * Bands

The outputs are ordered, if n is the linearIndex:

n:0 ---> level:0 band:1, n:1 ---> l:0, b:2, etc. until b == bands. n:bands-1 ---> l:0, b=bands

If there is more than one level:

n:bands ---> l:1, b=1

if only one level:

n:bands ---> l:0, b=0

Independently of the numbers of levels or bands, the last index is always the low pass:

nLowPass ---> l:Levels, b=0

Note that bands and levels are always >= 1. The level/bands returned here corresponds to an index.

◆ LessOrEqualIndiceComparisson()

template<typename TIndicesArrayType, unsigned int VImageDimension>
ITK_TEMPLATE_EXPORT bool itk::utils::LessOrEqualIndiceComparisson ( const TIndicesArrayType & rhs,
const TIndicesArrayType & lhs )

Definition at line 144 of file itkRieszUtilities.h.