Subject: Re: 2D convolution performance expectation
Hello and thanks for the answer,
> Why are you using floating point ?
In fact I have to read the image in float format. But I don't know if it
is more efficient to convert it to integers and back to float (values
normalized between 0.0 and 1.0) for write ouput to file since I will
have to add some division operations for conversion.
> You also did not say wether the image is color or Grayscale
It is grayscale images.
> the usual manner for a kernel convolution is to use integers
> For Instance with a 7 x 7 kernel there would 49 Multiplies and additions
> and 1 divide for nearly every point in the 1000 x 1000 image array
> If you neglect the edges then the image convolution takes place over
> 951 x 951
> this is 43277 multiples and adds
> On a modern Pentium 4 with 4 MB LII cache this can all take place in the
> cache for a grayscale image which can take 2 cycles for each multiply
> and 1 cycle for each add and I think it is 10 cycles for a divide
I don't understand what do you meant by "all take place in the cache".
Do you mean load the entire image in the memory?
The problem is, for the moment, I can work with 1000*1000 images but the
final goal is to process very large images (around 20000*20000) so
performance is crucial.
> which works out to 692432 clock cycles which on a 2 GHz machine should
> only take about 339 Milliseconds for color the math is very similar
I will try to use integers to see if there is a performance increase.
View All Messages in comp.graphics.algorithms
2D convolution performance expectation =>Re: 2D convolution performance expectation =>
Re: 2D convolution performance expectation
Copyright © 2006 WatermarkFactory.com. All Rights Reserved.