18 #ifndef sitkCannySegmentationLevelSetImageFilter_h
19 #define sitkCannySegmentationLevelSetImageFilter_h
143 SITK_RETURN_SELF_TYPE_HEADER
SetVariance (
double Variance ) { this->m_Variance = Variance;
return *
this; }
152 SITK_RETURN_SELF_TYPE_HEADER
SetMaximumRMSError (
double MaximumRMSError ) { this->m_MaximumRMSError = MaximumRMSError;
return *
this; }
160 SITK_RETURN_SELF_TYPE_HEADER
SetPropagationScaling (
double PropagationScaling ) { this->m_PropagationScaling = PropagationScaling;
return *
this; }
168 SITK_RETURN_SELF_TYPE_HEADER
SetCurvatureScaling (
double CurvatureScaling ) { this->m_CurvatureScaling = CurvatureScaling;
return *
this; }
176 SITK_RETURN_SELF_TYPE_HEADER
SetAdvectionScaling (
double AdvectionScaling ) { this->m_AdvectionScaling = AdvectionScaling;
return *
this; }
184 SITK_RETURN_SELF_TYPE_HEADER
SetNumberOfIterations ( uint32_t NumberOfIterations ) { this->m_NumberOfIterations = NumberOfIterations;
return *
this; }
192 SITK_RETURN_SELF_TYPE_HEADER
SetReverseExpansionDirection (
bool ReverseExpansionDirection ) { this->m_ReverseExpansionDirection = ReverseExpansionDirection;
return *
this; }
204 SITK_RETURN_SELF_TYPE_HEADER
SetIsoSurfaceValue (
double IsoSurfaceValue ) { this->m_IsoSurfaceValue = IsoSurfaceValue;
return *
this; }
235 std::string
GetName()
const {
return std::string (
"CannySegmentationLevelSetImageFilter"); }
238 std::string ToString()
const;
245 Image Execute (
const Image & initialImage,
const Image & featureImage );
252 template <
class TImageType>
Image ExecuteInternal (
const Image * initialImage,
const Image * featureImage );
260 double m_Threshold{0.0};
262 double m_Variance{0.0};
265 double m_MaximumRMSError{0.02};
268 double m_PropagationScaling{1.0};
271 double m_CurvatureScaling{1.0};
274 double m_AdvectionScaling{1.0};
277 uint32_t m_NumberOfIterations{1000u};
280 bool m_ReverseExpansionDirection{
false};
283 double m_IsoSurfaceValue{0.0};
286 uint32_t m_ElapsedIterations{0};
288 double m_RMSChange{0.0};
293 bool m_InPlace{
false};
306 SITKBasicFilters_EXPORT Image CannySegmentationLevelSet (
Image && initialImage,
const Image & featureImage,
double threshold = 0.0,
double variance = 0.0,
double maximumRMSError = 0.02,
double propagationScaling = 1.0,
double curvatureScaling = 1.0,
double advectionScaling = 1.0, uint32_t numberOfIterations = 1000u,
bool reverseExpansionDirection =
false,
double isoSurfaceValue = 0.0 );
308 SITKBasicFilters_EXPORT Image CannySegmentationLevelSet (
const Image & initialImage,
const Image & featureImage,
double threshold = 0.0,
double variance = 0.0,
double maximumRMSError = 0.02,
double propagationScaling = 1.0,
double curvatureScaling = 1.0,
double advectionScaling = 1.0, uint32_t numberOfIterations = 1000u,
bool reverseExpansionDirection =
false,
double isoSurfaceValue = 0.0 );