[Insight-developers] Trying to avoid an extra copy reading files using itkImageSeriesReader

Bradley Lowekamp blowekamp at mail.nih.gov
Mon Mar 28 14:51:42 EDT 2011


Luis,

I made a new patch, which should be much more flexible.

I also discovered that the ImageSeriesReader has not been supporting VectorImages. This will be needed by SimpleITK too. For this patch, I don't think I am calculating the size of the buffer correctly, nor the off set for all types of images. Do you know what is the correct thing to do here, to support both VectorImages and Images of vector/rgb?

Thanks,
Brad

On Mar 28, 2011, at 10:32 AM, Lowekamp, Bradley (NIH/NLM/LHC) [C] wrote:

> Hello Roger,
> 
> Your benchmark program had a few more dependencies, the just ITK so I wrote my own and attached it. I used a series of tiff I have, so I hope it would be comparable. I have also arrived at a similar conclusion that the copy loop is expensive and should be avoided. However, my benchmark does indicate that the progress reporting is taking 50% of the additional execution time, which is rather different then your experiment.
> 
> 
> Testing series reader with 349 files.
> Image Size: [2048, 1536, 349]
> 
> # current ITK
> Executed 10 times with mean 24.4403s
> 
> # progress commented out
> Executed  10 times with mean 20.7206s
> 
> # copy loop commented out
> Executed with 10 times with mean 16.5306s
> 
> # gerrit patch version
> Executed 10 times with mean 16.9262s
> 
> <itkImageSeriesReaderPerformance.cxx><ATT00001..htm>

========================================================
Bradley Lowekamp  
Lockheed Martin Contractor for
Office of High Performance Computing and Communications
National Library of Medicine 
blowekamp at mail.nih.gov


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20110328/179f8fa3/attachment.htm>


More information about the Insight-developers mailing list