17 #ifndef itkFrangiTubularnessImageFilter_h
18 #define itkFrangiTubularnessImageFilter_h
37 template<
typename TInput,
typename TOutput>
70 return !(*
this != other);
74 double tubularness = 0.0;
76 auto a1 =
static_cast<double>( A[0] );
77 auto a2 =
static_cast<double>( A[1] );
78 auto a3 =
static_cast<double>( A[2] );
80 double l1 = itk::Math::abs( a1 );
81 double l2 = itk::Math::abs( a2 );
82 double l3 = itk::Math::abs( a3 );
144 const double Rs = l2 / l3;
145 const double Rb = l1 / std::sqrt( l2 * l3 );
146 const double Rn = std::sqrt( l3*l3 + l2*l2 + l1*l1 );
148 tubularness = ( 1.0 - std::exp( - ( Rs * Rs ) / ( 2.0 *
m_Alpha *
m_Alpha ) ) );
149 tubularness *= ( std::exp( - ( Rb * Rb ) / ( 2.0 *
m_Beta *
m_Beta ) ) );
150 tubularness *= ( 1.0 - std::exp( - ( Rn * Rn ) / ( 2.0 *
m_Gamma *
m_Gamma ) ) );
152 return static_cast<TOutput
>( tubularness );
169 std::cout <<
"m_BrigthForeground " << value << std::endl;
181 template <
typename TInputImage,
typename TOutputImage>
185 Function::Tubularness< typename TInputImage::PixelType,
186 typename TOutputImage::PixelType> >
194 TInputImage,TOutputImage,
196 typename TInputImage::PixelType,
197 typename TOutputImage::PixelType> >;
211 this->GetFunctor().SetAlpha( value );
217 this->GetFunctor().SetBeta( value );
223 this->GetFunctor().SetGamma( value );
230 this->GetFunctor().SetBrightBackground( value );
234 #ifdef ITK_USE_CONCEPT_CHECKING
void SetGamma(double value)
~FrangiTubularnessImageFilter() override
bool operator==(const Tubularness &other) const
void SetNoiseNormalization(double value)
const Tubularness & operator=(const Tubularness &one)
typename TInputImage::PixelType InputPixelType
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
Base class for all process objects that output image data.
void SetSheetnessNormalization(double value)
void SetAlpha(double value)
bool operator!=(const Tubularness &) const
TOutput operator()(const TInput &A)
static constexpr double eps
FrangiTubularnessImageFilter()
Tubularness(const Tubularness &one)
Computes a measure of CrestLines from the Hessian Eigenvalues.
void SetBeta(double value)
Implements pixel-wise generic operation on one image.
void SetBloobinessNormalization(double value)
void SetBrightBackground(bool value)
void SetBrightBackground(bool value)
#define itkConceptMacro(name, concept)