18 #ifndef sitkLabelStatisticsImageFilter_h
19 #define sitkLabelStatisticsImageFilter_h
65 SITK_RETURN_SELF_TYPE_HEADER
SetUseHistograms (
bool UseHistograms ) { this->m_UseHistograms = UseHistograms;
return *
this; }
68 SITK_RETURN_SELF_TYPE_HEADER
UseHistogramsOn() {
return this->SetUseHistograms(
true); }
69 SITK_RETURN_SELF_TYPE_HEADER
UseHistogramsOff() {
return this->SetUseHistograms(
false); }
81 double GetMinimum(int64_t label)
const {
return this->m_pfGetMinimum(label); };
90 double GetMaximum(int64_t label)
const {
return this->m_pfGetMaximum(label); };
99 double GetMean(int64_t label)
const {
return this->m_pfGetMean(label); };
108 double GetMedian(int64_t label)
const {
return this->m_pfGetMedian(label); };
117 double GetSigma(int64_t label)
const {
return this->m_pfGetSigma(label); };
126 double GetVariance(int64_t label)
const {
return this->m_pfGetVariance(label); };
135 double GetSum(int64_t label)
const {
return this->m_pfGetSum(label); };
144 uint64_t
GetCount(int64_t label)
const {
return this->m_pfGetCount(label); };
153 std::vector<int>
GetBoundingBox(int64_t label)
const {
return this->m_pfGetBoundingBox(label); };
162 std::vector<unsigned int>
GetRegion(int64_t label)
const {
return this->m_pfGetRegion(label); };
170 std::vector<int64_t>
GetLabels()
const {
return this->m_Labels; };
174 std::string
GetName()
const {
return std::string (
"LabelStatisticsImageFilter"); }
177 std::string ToString()
const;
182 void Execute (
const Image & image,
const Image & labelImage );
186 bool HasLabel(int64_t label );
189 uint64_t GetNumberOfLabels( );
197 template <
class TImageType1,
class TImageType2>
void DualExecuteInternal (
const Image * image,
const Image * labelImage );
204 bool m_UseHistograms{
true};
227 std::vector<int64_t> m_Labels{std::vector<int64_t>()};