Laplacian of Gaussian linearity

688 Views Asked by At

It is known that when using first and especially second order derivative we should first smooth the image so in the case of Laplacian of Gaussian first to convolve with the Gaussian mask and the with the Laplacian mask. But on the other hand both of them are linear operations so should we get the same result if we first apply Laplacian and then Gaussian?

1

There are 1 best solutions below

7
On BEST ANSWER

Yes, the two operations are convolutions, linear operations, and therefore can be applied in any order to yield the exact same result. If the results are not exactly the same, it is due to rounding errors.

You can also combine both kernels and apply them as a single convolution. But it actually is computationally cheaper to compute the Gaussian and the 3x3 Laplacian separately, because the Gaussian can be computed by applying two 1D filters (i.e. it is separable), which saves a lot of computation.

For details about the different ways to compute the Laplace of Gaussian, see this answer.