(smoothing)
Basic kernels for 1st order gradient.
Horizontal kernel (transpose for vertical) :
-1 | 0 | 1 |
---|---|---|
-1 | 0 | 1 |
-1 | 0 | 1 |
First kernel :
1 | 0 |
---|---|
0 | -1 |
Second kernel :
0 | 1 |
---|---|
-1 | 0 |
Intensity :
I = sqrt(I1^2 + I2^2)
Direction :
theta = arctan(I2 / I1) + pi/4
Most popular 1st order kernels
Horizontal kernel (transpose for vertical) :
-1 | 0 | 1 |
---|---|---|
-2 | 0 | 2 |
-1 | 0 | 1 |
Intensity :
I = sqrt(Iv^2 + Ih^2)
Direction :
theta = arctan(Iv / Ih)
The filter can be seen as the convolution of two filters.
Derivative :
-1 |
---|
0 |
1 |
Smoothing :
1 | 2 | 1 |
---|
May give more accurate results than Sobel
Horizontal kernel (transpose for vertical) :
-3 | 0 | 3 |
---|---|---|
-10 | 0 | 10 |
-3 | 0 | 3 |
2nd order kernel
Kernel :
0 | 1 | 0 |
---|---|---|
1 | -4 | 1 |
0 | 1 | 0 |
Dilatation
Erosion
Ouverture
Fermeture
Best theoritical edge detector.
Noise filtering, gradient with horizontal vertical and diagonal kernels, thresholding with hysteresis taking into account the direction of the gradient.