Atitit image processing deep understanding of gradient principle calculation . v1 Qc8
1.1.image Processing Gradient Calculation Basic Gradient Internal Gradient External Gradient direction Gradient1
2. image Gradient is the edge of the image? 2
1.1.
image Processing Gradient Calculation Basic Gradient Internal Gradient External Gradient direction Gradient
source code based on OpenCV realized, the reason is too lazy, do not want to use Java write it from scratch!
One: Concept Introduction
Morphological operation expansion and corrosion image morphology of the most basic two morphological operations, are often combined together to achieve some complex image morphology operation, the calculation of morphological gradient of the image is one of the important operations of morphology is the expansion and corrosion of the basic operation of the appropriate combination of formation. There are four common types of gradients that can be computed:
Basic gradient
The basic gradient is to use the expanded image minus the corroded image to get the difference image, called the gradient image is also OpenCV supports the method of calculating morphological gradients, and this method of getting gradients has been called the basic gradient.
Internal gradient
is to use the original image minus the corroded image to get the difference image, called the image of the internal gradient
External gradient
After the image is inflated and subtracted from the original image, the difference image is called the external gradient of the image.
Direction gradient
The direction gradient is used The X- direction and Y -direction lines are used as structural elements to get the image gradient, and the structural elements of X are expanded and corroded to get the image after the difference is worth to be called X Direction gradient, in the y - direction straight line structure expansion and corrosion after the image is obtained after the difference value is called the y - direction gradient
2.
image Gradient is the edge of the image?
For the image gradient, looked up a lot of information, has not fully understood the meaning. What is the relationship between image gradient and image edge, forget expert pointing? Best to enclose the formula, thank you!
image can be regarded as a two-dimensional discrete function, the image gradient is actually the derivation of this two-dimensional discrete function:
Image Gradient : G (x, y) = dx i + dy j;
DX (i,j) = i (i+1,j)-I (I,J);
dy (i,j) = i (i,j+1)-I (I,J);
whereI is the value of the image pixel (for Example:RGB value ),(i,j) is the coordinate of the pixel.
image gradients can also be used in the median differential:
DX (i,j) = [I (I+1,J)-I (I-1,J)]/2;
dy (i,j) = [I (i,j+1)-I (i,j-1)]/2;
image edge is usually achieved by the gradient operation of the image.
The most important property of the image gradient is that the direction of the gradient is in the maximum change rate of the image's gray scale, which can reflect the gray change on the image edge.
It says a simple gradient definition, but there are more complex gradient formulas.
gradient of images - svan column - Blog channel -CSDN.NET.html
author :: Nickname : Old Wow's paw claw of Eagle idol wreck iconoclast image-smasher
Bird catcherWang"Bird Catcher King of kings of Kings devout pious religiousFaithDefenders DefenderOf the Faith. Kara CarlaRed Cloak CaracallaRed Cloak
abbreviation: : Emir Attilax Akbar Emil Attilax Akbar
Full Name::EmirAttilax AkbarbinMahmud bin Attila binSolomon Al Rapanui
Emil Attilax Akbar this Mahmoud this Attila Solomon al Rapa Nui
common name : Span style= "font-family: Song body; Color: #333333; font-size:12pt "> Etila ( Ayron"   Email:[email protected]
reprint Please indicate source: attilax 's Column http://www.cnblogs.com/attilax/
--atiend
Atitit image processing deep understanding of gradient principle calculation. v1 Qc8