Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType > Class Template Reference

Performes deterministic streamline tracking on the input tensor image. More...

#include <itkStreamlineTrackingFilter.h>

Inheritance diagram for itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >:
Collaboration diagram for itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >:

Public Types

typedef StreamlineTrackingFilter Self
 
typedef SmartPointer< SelfPointer
 
typedef SmartPointer< const SelfConstPointer
 
typedef ImageToImageFilter< Image< DiffusionTensor3D< TTensorPixelType >, 3 >, Image< Vector< TPDPixelType, 3 >, 3 > > Superclass
 
typedef TTensorPixelType TensorComponentType
 
typedef TPDPixelType DirectionPixelType
 
typedef Superclass::InputImageType InputImageType
 
typedef Superclass::OutputImageType OutputImageType
 
typedef Superclass::OutputImageRegionType OutputImageRegionType
 
typedef itk::Image< unsigned char, 3 > ItkUcharImgType
 
typedef itk::Image< double, 3 > ItkDoubleImgType
 
typedef itk::Image< float, 3 > ItkFloatImgType
 
typedef itk::Image< vnl_vector_fixed< double, 3 >, 3 > ItkPDImgType
 
typedef vtkSmartPointer< vtkPolyData > FiberPolyDataType
 

Public Member Functions

Pointer Clone () const
 
virtual const char * GetClassName () const
 
virtual FiberPolyDataType GetFiberPolyData ()
 Output fibers. More...
 
virtual void SetSeedImage (ItkUcharImgType::Pointer _arg)
 Seeds are only placed inside of this mask. More...
 
virtual void SetMaskImage (ItkUcharImgType::Pointer _arg)
 Tracking is only performed inside of this mask image. More...
 
virtual void SetFaImage (ItkFloatImgType::Pointer _arg)
 Use this FA image instead of the automatically calculated one. Necessary for multi tensor tracking. More...
 
virtual void SetSeedsPerVoxel (int _arg)
 One seed placed in the center of each voxel or multiple seeds randomly placed inside each voxel. More...
 
virtual void SetFaThreshold (double _arg)
 FA termination criterion. More...
 
virtual void SetStepSize (double _arg)
 Integration step size in mm. More...
 
virtual void SetF (double _arg)
 Tensor deflection parameter f. More...
 
virtual void SetG (double _arg)
 Tensor deflection parameter g. More...
 
virtual void SetInterpolate (bool _arg)
 Toggle between nearest neighbour (false) and trilinear interpolation (true) More...
 
virtual void SetMinTractLength (double _arg)
 Shorter tracts are discarded. More...
 
virtual double GetMinTractLength ()
 
virtual void SetMinCurvatureRadius (double _arg)
 Tracking is stopped if curvature radius (in mm) is too small. More...
 
virtual double GetMinCurvatureRadius ()
 
virtual void SetResampleFibers (bool _arg)
 If enabled, the resulting fibers are resampled to feature point distances of 0.5*MinSpacing. This is recommendable for very short integration steps and many seeds. If disabled, the resulting fiber bundle might become very large. More...
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 StreamlineTrackingFilter ()
 
 ~StreamlineTrackingFilter ()
 
void PrintSelf (std::ostream &os, Indent indent) const
 
void CalculateNewPosition (itk::ContinuousIndex< double, 3 > &pos, vnl_vector_fixed< double, 3 > &dir, typename InputImageType::IndexType &index)
 Calculate next integration step. More...
 
double FollowStreamline (itk::ContinuousIndex< double, 3 > pos, int dirSign, vtkPoints *points, std::vector< vtkIdType > &ids, int imageIdx)
 Start streamline in one direction. More...
 
bool IsValidPosition (itk::ContinuousIndex< double, 3 > &pos, typename InputImageType::IndexType &index, vnl_vector_fixed< double, 8 > &interpWeights, int imageIdx)
 Are we outside of the mask image? Is the FA too low? More...
 
double RoundToNearest (double num)
 
void BeforeThreadedGenerateData ()
 
void ThreadedGenerateData (const OutputImageRegionType &outputRegionForThread, ThreadIdType threadId)
 
void AfterThreadedGenerateData ()
 
FiberPolyDataType AddPolyData (FiberPolyDataType poly1, FiberPolyDataType poly2)
 Combine tracking results generated by the individual threads. More...
 

Protected Attributes

FiberPolyDataType m_FiberPolyData
 
vtkSmartPointer< vtkPoints > m_Points
 
vtkSmartPointer< vtkCellArray > m_Cells
 
std::vector< ItkDoubleImgType::Pointer > m_EmaxImage
 Stores largest eigenvalues per voxel (one for each tensor) More...
 
ItkFloatImgType::Pointer m_FaImage
 FA image used to determine streamline termination. More...
 
std::vector< ItkPDImgType::Pointer > m_PdImage
 Stores principal direction of each tensor in each voxel. More...
 
std::vector< typename InputImageType::Pointer > m_InputImage
 Input tensor images. For multi tensor tracking provide multiple tensor images. More...
 
int m_NumberOfInputs
 
double m_FaThreshold
 
double m_MinCurvatureRadius
 
double m_StepSize
 
int m_MaxLength
 
double m_MinTractLength
 
int m_SeedsPerVoxel
 
double m_F
 
double m_G
 
bool m_Interpolate
 
double m_PointPistance
 
bool m_ResampleFibers
 
std::vector< int > m_ImageSize
 
std::vector< double > m_ImageSpacing
 
ItkUcharImgType::Pointer m_SeedImage
 
ItkUcharImgType::Pointer m_MaskImage
 
itk::VectorContainer< int, FiberPolyDataType >::Pointer m_PolyDataContainer
 

Detailed Description

template<class TTensorPixelType, class TPDPixelType = double>
class itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >

Performes deterministic streamline tracking on the input tensor image.

Definition at line 42 of file itkStreamlineTrackingFilter.h.

Member Typedef Documentation

template<class TTensorPixelType , class TPDPixelType = double>
typedef SmartPointer<const Self> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ConstPointer

Definition at line 51 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef TPDPixelType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::DirectionPixelType

Definition at line 62 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef vtkSmartPointer< vtkPolyData > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::FiberPolyDataType

Definition at line 70 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef Superclass::InputImageType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::InputImageType

Definition at line 63 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef itk::Image<double, 3> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ItkDoubleImgType

Definition at line 67 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef itk::Image<float, 3> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ItkFloatImgType

Definition at line 68 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef itk::Image< vnl_vector_fixed<double,3>, 3> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ItkPDImgType

Definition at line 69 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef itk::Image<unsigned char, 3> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ItkUcharImgType

Definition at line 66 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef Superclass::OutputImageRegionType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::OutputImageRegionType

Definition at line 65 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef Superclass::OutputImageType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::OutputImageType

Definition at line 64 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef SmartPointer<Self> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::Pointer

Definition at line 50 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef StreamlineTrackingFilter itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::Self

Definition at line 49 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef ImageToImageFilter< Image< DiffusionTensor3D<TTensorPixelType>, 3 >, Image< Vector< TPDPixelType, 3 >, 3 > > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::Superclass

Definition at line 52 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
typedef TTensorPixelType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::TensorComponentType

Definition at line 61 of file itkStreamlineTrackingFilter.h.

Constructor & Destructor Documentation

template<class TTensorPixelType , class TPDPixelType >
itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::StreamlineTrackingFilter ( )
protected

Definition at line 37 of file itkStreamlineTrackingFilter.cpp.

template<class TTensorPixelType , class TPDPixelType = double>
itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::~StreamlineTrackingFilter ( )
inlineprotected

Definition at line 90 of file itkStreamlineTrackingFilter.h.

Member Function Documentation

template<class TTensorPixelType , class TPDPixelType >
vtkSmartPointer< vtkPolyData > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::AddPolyData ( FiberPolyDataType  poly1,
FiberPolyDataType  poly2 
)
protected

Combine tracking results generated by the individual threads.

Definition at line 836 of file itkStreamlineTrackingFilter.cpp.

References mitk::New().

template<class TTensorPixelType , class TPDPixelType >
void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::AfterThreadedGenerateData ( )
protected

Definition at line 870 of file itkStreamlineTrackingFilter.cpp.

References MITK_INFO.

template<class TTensorPixelType , class TPDPixelType >
void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::BeforeThreadedGenerateData ( void  )
protected

Definition at line 75 of file itkStreamlineTrackingFilter.cpp.

References MITK_INFO, and mitk::New().

template<class TTensorPixelType , class TPDPixelType >
void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::CalculateNewPosition ( itk::ContinuousIndex< double, 3 > &  pos,
vnl_vector_fixed< double, 3 > &  dir,
typename InputImageType::IndexType &  index 
)
protected

Calculate next integration step.

Definition at line 234 of file itkStreamlineTrackingFilter.cpp.

References mitk::eps.

template<class TTensorPixelType , class TPDPixelType = double>
Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::Clone ( ) const
template<class TTensorPixelType , class TPDPixelType >
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::FollowStreamline ( itk::ContinuousIndex< double, 3 >  pos,
int  dirSign,
vtkPoints *  points,
std::vector< vtkIdType > &  ids,
int  imageIdx 
)
protected

Start streamline in one direction.

Definition at line 467 of file itkStreamlineTrackingFilter.cpp.

References mitk::eps.

template<class TTensorPixelType , class TPDPixelType = double>
virtual const char* itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::GetClassName ( ) const
virtual

Runtime information support.

template<class TTensorPixelType , class TPDPixelType = double>
virtual FiberPolyDataType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::GetFiberPolyData ( )
virtual

Output fibers.

template<class TTensorPixelType , class TPDPixelType = double>
virtual double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::GetMinCurvatureRadius ( )
virtual
template<class TTensorPixelType , class TPDPixelType = double>
virtual double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::GetMinTractLength ( )
virtual
template<class TTensorPixelType , class TPDPixelType >
bool itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::IsValidPosition ( itk::ContinuousIndex< double, 3 > &  pos,
typename InputImageType::IndexType &  index,
vnl_vector_fixed< double, 8 > &  interpWeights,
int  imageIdx 
)
protected

Are we outside of the mask image? Is the FA too low?

Definition at line 391 of file itkStreamlineTrackingFilter.cpp.

template<class TTensorPixelType , class TPDPixelType = double>
static Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::New ( )
static

Method for creation through the object factory.

template<class TTensorPixelType , class TPDPixelType >
void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
protected

Definition at line 885 of file itkStreamlineTrackingFilter.cpp.

template<class TTensorPixelType , class TPDPixelType >
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::RoundToNearest ( double  num)
protected

Definition at line 67 of file itkStreamlineTrackingFilter.cpp.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetF ( double  _arg)
virtual

Tensor deflection parameter f.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetFaImage ( ItkFloatImgType::Pointer  _arg)
virtual

Use this FA image instead of the automatically calculated one. Necessary for multi tensor tracking.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetFaThreshold ( double  _arg)
virtual

FA termination criterion.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetG ( double  _arg)
virtual

Tensor deflection parameter g.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetInterpolate ( bool  _arg)
virtual

Toggle between nearest neighbour (false) and trilinear interpolation (true)

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetMaskImage ( ItkUcharImgType::Pointer  _arg)
virtual

Tracking is only performed inside of this mask image.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetMinCurvatureRadius ( double  _arg)
virtual

Tracking is stopped if curvature radius (in mm) is too small.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetMinTractLength ( double  _arg)
virtual

Shorter tracts are discarded.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetResampleFibers ( bool  _arg)
virtual

If enabled, the resulting fibers are resampled to feature point distances of 0.5*MinSpacing. This is recommendable for very short integration steps and many seeds. If disabled, the resulting fiber bundle might become very large.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetSeedImage ( ItkUcharImgType::Pointer  _arg)
virtual

Seeds are only placed inside of this mask.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetSeedsPerVoxel ( int  _arg)
virtual

One seed placed in the center of each voxel or multiple seeds randomly placed inside each voxel.

template<class TTensorPixelType , class TPDPixelType = double>
virtual void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::SetStepSize ( double  _arg)
virtual

Integration step size in mm.

template<class TTensorPixelType , class TPDPixelType >
void itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::ThreadedGenerateData ( const OutputImageRegionType outputRegionForThread,
ThreadIdType  threadId 
)
protected

Definition at line 736 of file itkStreamlineTrackingFilter.cpp.

References line, and mitk::New().

Member Data Documentation

template<class TTensorPixelType , class TPDPixelType = double>
vtkSmartPointer<vtkCellArray> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_Cells
protected

Definition at line 106 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
std::vector< ItkDoubleImgType::Pointer > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_EmaxImage
protected

Stores largest eigenvalues per voxel (one for each tensor)

Definition at line 108 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_F
protected

Definition at line 120 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
ItkFloatImgType::Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_FaImage
protected

FA image used to determine streamline termination.

Definition at line 109 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_FaThreshold
protected

Definition at line 114 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
FiberPolyDataType itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_FiberPolyData
protected

Definition at line 104 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_G
protected

Definition at line 121 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
std::vector< int > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_ImageSize
protected

Definition at line 125 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
std::vector< double > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_ImageSpacing
protected

Definition at line 126 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
std::vector< typename InputImageType::Pointer > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_InputImage
protected

Input tensor images. For multi tensor tracking provide multiple tensor images.

Definition at line 111 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
bool itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_Interpolate
protected

Definition at line 122 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
ItkUcharImgType::Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_MaskImage
protected

Definition at line 128 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
int itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_MaxLength
protected

Definition at line 117 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_MinCurvatureRadius
protected

Definition at line 115 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_MinTractLength
protected

Definition at line 118 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
int itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_NumberOfInputs
protected

Definition at line 113 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
std::vector< ItkPDImgType::Pointer > itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_PdImage
protected

Stores principal direction of each tensor in each voxel.

Definition at line 110 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_PointPistance
protected

Definition at line 123 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
vtkSmartPointer<vtkPoints> itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_Points
protected

Definition at line 105 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
itk::VectorContainer< int, FiberPolyDataType >::Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_PolyDataContainer
protected

Definition at line 130 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
bool itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_ResampleFibers
protected

Definition at line 124 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
ItkUcharImgType::Pointer itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_SeedImage
protected

Definition at line 127 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
int itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_SeedsPerVoxel
protected

Definition at line 119 of file itkStreamlineTrackingFilter.h.

template<class TTensorPixelType , class TPDPixelType = double>
double itk::StreamlineTrackingFilter< TTensorPixelType, TPDPixelType >::m_StepSize
protected

Definition at line 116 of file itkStreamlineTrackingFilter.h.


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