Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Ok, you don't have to worry. What you need to look at is not that there is a difference, but the amount of difference.

Running your code shows the same thing, lots of difference, but if instead you find diff by using the absdiff function, you see that the amount of difference is very small. The largest difference is 27 counts, and that's right at the edge of the image. If you look at the difference image, it's totally black. In fact, there isn't a difference larger than 1 except right at the edge, where the border behaves differently.

The differences of 1 are just slightly different coefficients causing rounding effects differently. When you do it twice, you round to integer values between blurs, so the second blur isn't as accurate. A single blur doesn't have that problem.