[Insight-users] segmenting delay

Luis Ibanez luis.ibanez@kitware.com
Wed, 02 Apr 2003 20:28:39 -0500


Hi Robin,


When you apply the ConfidenceConnected segmentation
filter to a 3D image one of the elements penalizing
the speed is the way in which the floodfill iterator
was implemented.

This has been changed (today), the data structure
used by this iterator was a std::stack, and it was
replaced with a std::queue.

You may want to try this modified version.

It may be worth in your code to discriminate between
the time consumed in the preprocessing step of the
anistropic diffusion filters and the segmentation
itself.

The computing time of the confidence connected
filter depends on the complexity (shape) and size
of the object you are segmenting (it does not depend
on the total size of the image).


You may want to insert timers in your code by using
the classes:


       TimeProbe and TimeProbesCollectorBase.


http://www.itk.org/Insight/Doxygen/html/classitk_1_1TimeProbe.html
http://www.itk.org/Insight/Doxygen/html/classitk_1_1TimeProbesCollectorBase.html


The code will look like:


   TimeProbesCollectorBase  timeCollector;

   timeCollector.Start("Preprocessing");
   anisotropicDiffusionFilter->Update();
   timeCollector.Stop("Preprocessing");

   timeCollector.Start("RegionGrowing");
   confidenceConnectedFilter->Update();
   timeCollector.Stop("RegioniGrowing");

   timeCollector.Report();



Note that the strings paired in Start/Stop *must* match.

You could Stop and re-Start timers, and you can also use
nested timers. Each one rund independent of the others.

Timers precision is platform dependent, so make sure
that the processes take at least a couple of seconds.


We will be *very*  interested in hearing from your
findings if you decide to set timers in this example.



    Thanks


      Luis


---------------------------------------------------------
Robin Gandhi wrote:
> hi everyone,
>    I am semgmenting a brain tumour out of a MRI volume
> (256x256x24) using the ConfidenceConnected.cxx example
> in the Examples/Segmentation directory.
> 
> These are the parameters that I am using for this
> example, (I have changed the example to work on a 3D
> volume.)
> 
> Smoothing filter CurvatureFlowImageFilter
>    
> smoothing->SetNumberOfIterations( 10 );
> smoothing->SetTimeStep( 0.125 );
> 
> Confidenceconnected filter
> 
> confidenceConnected->SetMultiplier( 2.5 );
> confidenceConnected->SetNumberOfIterations( 5 );
> confidenceConnected->SetReplaceValue( 255 );
> confidenceConnected->SetInitialNeighborhoodRadius( 5
> );
> 
> The results of segmenting the tumor are good but it
> takes around 30 to 40 seconds to do the segmentation
> for a very small tumour volume.
> 
> Can any one suggest me the parameters I can tune 
> to reduce the processing time for this 3D volume.
> 
> thanks in advance
> --Robin.
>    
> 
> 
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Tax Center - File online, calculators, forms, and more
> http://tax.yahoo.com
> _______________________________________________
> Insight-users mailing list
> Insight-users@public.kitware.com
> http://public.kitware.com/mailman/listinfo/insight-users
>