[Insight-users] Re: AW: [vtkusers] extend boundary of image

Luis Ibanez luis.ibanez@kitware.com
Wed, 30 Apr 2003 09:57:52 -0400


Zein, Sean,


Zein:
the reimplementation you made of the connected
threshold filter, was it after we change the STL
container used by te itkFloodFillFuctionConditional
iterator ?

Please check on line 214 of the file:

   itkFloodFilledFunctionConditionalConstIterator.h:

This iterators was previously using a std::stack
as container. We recently changed to use a std::queue
that largely improves speed and reduced memory
consumption.

BTW, if after this checks you find that your reimplemen-
taion is still 3-5 times faster, and if you are willing
to contribute it to the toolkit, we will happy to include
it as a specialized case for 3D.


Sean:
Are you working in a Windows platform ?
In that case, please make sure that you do

in VC++ 6.0 Project->Setttings
in VC++ 7.0 Build->Configuration Manager

and select the 'release' mode.

This will make huge difference in performace.
Just for one thing: no methods are inlined when
you compile for debug mode, so most of the advantages
of templated code is sacrificed when you use debug.

Before you compare two ITK to any other system, make
sure that they are running in similar conditions.



Regards


   Luis



---------------
salah wrote:
> Hello Chen, Hello Luis,
> 
....

> Luis, by the way, I re-implemented the connected threshold
> segmentation filter without using the Itk iterators, and
> specificaly for 3D images, but using the same algorithms. 
> I was shocked to find that my filter is 3-5 times faster
> than that of itk.
> I attempted to do a similar re-implementation for the 
> erosion filter. To be honest, I have not seen noticible
> improvement. I would be very interested if someone provides
> me with a faster erotion filter. 
> 
 ....
> 
> 
> -----Ursprüngliche Nachricht-----
> Von: Chen Fu [mailto:novalet@yahoo.com.cn]
> Gesendet: Dienstag, 29. April 2003 13:47
> An: vtkusers@public.kitware.com
> Betreff: [vtkusers] extend boundary of image
> 
> 
> Hi!
> I recently compare the morphology operation in vtk,
> itk and matlab. To my surprise, vtk and itk is much
> slower than matlab. 
> I believe the problem is the boundary processing. In
> vtk and itk code, every pixel must take 8 compares to
> confirm whether it is inside the image boundary. But
> in matlab, the boundary is preprocessed by extending
> the size of image, so get rid of such compares. I will
> try to do some modify of vtk code to enhance its
> performance, but i am not very clearly how to do
> extend the image in vtk's pipeline architecture. 
> Maybe somebody can give me some hints?
> 
> 
> =====
> Remote Scensing Satellite Ground Station
> Chinese Academy of Science
> 
> _________________________________________________________
> Do You Yahoo!? 
> 下载免费即时聊天软件“雅虎通”感受动感聊天魅力,赶快用你的雅虎电邮帐号登陆吧~
> http://cn.rd.yahoo.com/mail_cn/tag/?http://cn.messenger.yahoo.com/
> _______________________________________________
> This is the private VTK discussion list. 
> Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>