What are the units and limits of a image gradient magnitude? For example I know how to get the gradient magnitude of an image (see below). And the resulting Mat
Maximum Gradient Magnitude
I can hardly agree with the answer above. Please note that for a central pixel X and its 3✕3 neighbors, it cannot take the maximum horizontal and vertical gradients AT THE SAME TIME, hence for an 8-bit system, the maximum gradient a Sobel filter can achieve should be sqrt(20)*(M-m)
, where M
and m
are the same as those defined in the accepted answer. The structure of the neighborhood is [m M M; m X M; m m M]
.