[Insight-users] how to use ReinitializeLevelSetImageFilter

Baoyun Li baoyun_li123 at yahoo.com
Mon Mar 8 16:49:00 EST 2010


Hi, Luis:
 
Thanks so much.
 
I program is based release model. Five mimutes is for not using narrarow band. How long time usually need for this filter with narrow band 12 for the 512*512*100 ct images? My plan is to use ReinitializeLevelSetImageFilter at each iteration. Do you think it is practial in terms of computation time.
 
I now make the ReinitializeLevelSetImageFilter works using binary image. The image has 0 and 255 intensity value. I set the levesetvale to be 128, it seems works.
 
My best regars
 
Baoyun
--- On Sat, 3/6/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: Saturday, March 6, 2010, 10:28 PM



Hi Baoyun,

The input to the ReinitializeLevelSetImageFilter 
is not expected to be a binary image.

The input image is supposed to be a level set image.

The purpose of the filter is to correct the drift that will
happens in a level set image due to the inaccuracies
of computing its progress based only on a narrow band
of pixels.

Five minutes is an abnormally long time for this filter.

Are you compiling your code for "Debug" mode ?


     Luis


------------------------------------------------------------------------------------------

On Tue, Mar 2, 2010 at 11:53 AM, Baoyun Li <baoyun_li123 at yahoo.com> wrote:






Dear Luis:
 
I tried to add SetLevelSetValue(0) and SetLevelSetValue(128). And set narrowbandoff.
However, I am getting same weird result.
 
So can you tell me whether the input of ReinitializeLevelSetImageFilter is binary image.
 
And the filter needs five mintues to run, is it normal for a 512x512x60 image.
 
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/20100308/bf8ebafd/attachment-0001.htm>


More information about the Insight-users mailing list