18 #ifndef sitkConfidenceConnectedImageFilter_h
19 #define sitkConfidenceConnectedImageFilter_h
65 SITK_RETURN_SELF_TYPE_HEADER
SetNumberOfIterations (
unsigned int NumberOfIterations ) { this->m_NumberOfIterations = NumberOfIterations;
return *
this; }
75 SITK_RETURN_SELF_TYPE_HEADER
SetMultiplier (
double Multiplier ) { this->m_Multiplier = Multiplier;
return *
this; }
85 SITK_RETURN_SELF_TYPE_HEADER
SetInitialNeighborhoodRadius (
unsigned int InitialNeighborhoodRadius ) { this->m_InitialNeighborhoodRadius = InitialNeighborhoodRadius;
return *
this; }
95 SITK_RETURN_SELF_TYPE_HEADER
SetReplaceValue (
uint8_t ReplaceValue ) { this->m_ReplaceValue = ReplaceValue;
return *
this; }
107 double GetMean()
const {
return this->m_Mean; };
118 SITK_RETURN_SELF_TYPE_HEADER
SetSeedList (
const std::vector< std::vector<unsigned int> > &t )
120 this->m_SeedList = t;
return *
this;
126 return this->m_SeedList;
132 this->m_SeedList.clear();
137 SITK_RETURN_SELF_TYPE_HEADER
SetSeed(
const std::vector<unsigned int> &idx )
139 this->m_SeedList.clear();
140 this->m_SeedList.push_back(idx);
145 SITK_RETURN_SELF_TYPE_HEADER
AddSeed(
const std::vector<unsigned int> &idx )
147 this->m_SeedList.push_back(idx);
152 std::string
GetName()
const {
return std::string (
"ConfidenceConnectedImageFilter"); }
155 std::string ToString()
const;
163 Image Execute (
const Image& image1,
const std::vector< std::vector<unsigned int> > &seedList,
unsigned int numberOfIterations,
double multiplier,
unsigned int initialNeighborhoodRadius,
uint8_t replaceValue );
169 typedef Image (Self::*MemberFunctionType)(
const Image& image1 );
170 template <
class TImageType>
Image ExecuteInternal (
const Image& image1 );
BasicPixelIDTypeList PixelIDTypeList
Self & AddSeed(const std::vector< unsigned int > &idx)
Self & SetInitialNeighborhoodRadius(unsigned int InitialNeighborhoodRadius)
#define SITKBasicFilters_EXPORT
nsstd::auto_ptr< detail::MemberFunctionFactory< MemberFunctionType > > m_MemberFactory
Self & SetMultiplier(double Multiplier)
typelist::MakeTypeList< BasicPixelID< int8_t >, BasicPixelID< uint8_t >, BasicPixelID< int16_t >, BasicPixelID< uint16_t >, BasicPixelID< int32_t >, BasicPixelID< uint32_t >, BasicPixelID< float >, BasicPixelID< double > >::Type BasicPixelIDTypeList
Self & SetSeedList(const std::vector< std::vector< unsigned int > > &t)
unsigned int m_NumberOfIterations
std::string GetName() const
std::vector< std::vector< unsigned int > > m_SeedList
unsigned int GetInitialNeighborhoodRadius() const
double GetMultiplier() const
ConfidenceConnectedImageFilter Self
Segment pixels with similar statistics using connectivity.
unsigned int GetNumberOfIterations() const
Image ConfidenceConnected(const Image &image1, const std::vector< std::vector< unsigned int > > &seedList, unsigned int numberOfIterations=4u, double multiplier=4.5, unsigned int initialNeighborhoodRadius=1u, uint8_t replaceValue=1u)
std::vector< std::vector< unsigned int > > GetSeedList() const
double GetVariance() const
Self & SetReplaceValue(uint8_t ReplaceValue)
The Image class for SimpleITK.
Self & SetNumberOfIterations(unsigned int NumberOfIterations)
Self & SetSeed(const std::vector< unsigned int > &idx)
unsigned int m_InitialNeighborhoodRadius
The base interface for SimpleITK filters that take one input image.
uint8_t GetReplaceValue() const