[Insight-users] how to use ReinitializeLevelSetImageFilter
Baoyun Li
baoyun_li123 at yahoo.com
Tue Mar 2 12:03:51 EST 2010
Dear Luis:
Can you please tell me what is the major differnce between SignedDanielssonDistanceMapImageFilter and ReinitializeLevelSetImageFilter.
I have previously successul used SignedDanielssonDistanceMapImageFilter. Can I use it for leveselt reinitialization.
Thanks and my best regards
Baoyun
--- On Mon, 3/1/10, Luis Ibanez <luis.ibanez at kitware.com> wrote:
From: Luis Ibanez <luis.ibanez at kitware.com>
Subject: Re: [Insight-users] how to use ReinitializeLevelSetImageFilter
To: "Baoyun Li" <baoyun_li123 at yahoo.com>
Cc: insight-users at itk.org
Date: Monday, March 1, 2010, 11:50 PM
Hi Baoyun,
It looks like you missed to call the method:
SetLevelSetValue()
before you called Update() in the filter.
For guidance, please look at the file:
Insight/Testing/Code/Algorithms/
itkReinitializeLevelSetImageFilterTest.cxx
Regards,
Luis
------------------------------------------------------
On Mon, Mar 1, 2010 at 2:56 PM, Baoyun Li <baoyun_li123 at yahoo.com> wrote:
Dear All:
I tried to use ReinitializeLevelSetImageFilter. The output looks weird to me.
The input to the filter is binary image binary image with float type (255 as forground, 0 as background).
I tried narroow band on and off. However, the output of this filter gives very high value (10^38) for voxles inside the binary mask. Almost all the outside mask voxels has value zero.
Below is my code, can somebody tell where I made mistake.
Baoyun
**************************code************************
typedef typename itk::ReinitializeLevelSetImageFilter< FeatureImageType > DistanceFilterType;
typename DistanceFilterType::Pointer DistanceFilter = DistanceFilterType::New();
DistanceFilter->SetInput( thresholder->GetOutput() );
// DistanceFilter->NarrowBandingOn();
// DistanceFilter->SetNarrowBandwidth( 10 );
try
{
DistanceFilter->Update();
}
catch( itk::ExceptionObject & excep )
{
std::cerr << "Exception caught !" << std::endl;
std::cerr << excep << std::endl;
}
m_levelset2=DistanceFilter->GetOutput();
****************code end*************************
_____________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.html
Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20100302/a4089880/attachment.htm>
More information about the Insight-users
mailing list