AUthor: Zhu benfu address: Guilin University of electronic science and technology, intelligent science and technology E-Mial: zhubenfulovepoem@163.comQQ: 896922782 technology exchange group:
Image Processing Analysis and Machine Vision(Group Number:
109128646This group is mainly responsible for image processing and analysis of theoretical research and engineering practices related to communication and machine vision. Project Cooperation Group:
Borman smart technology hi-tech(Group Number:
173234390) Obligation 1: Technical dating, project cooperation, and casual chatting in family life !......
Obligation 2: regularly announce potential project solutions and ideas for everyone to use software and hardware research for high-speed signal collection and processing, intelligent information processing, computer vision, intelligent robot, and Human-Computer Interaction
Running interface:
Input Image: You can see the basic functions
Generally binarization:
Above:
G (x, y) = high (255 white) f (x, y)> = Threshold
G (x, y) = low (0 black) f (x, y) <threshold
Below:
G (x, y) = high (255 white) f (x, y) <= Threshold
G (x, y) = low (0 black) f (x, y)> threshold
Dual-threshold binarization:
G (x, y) = high (255 white) f (x, y)> = threshold_low & F (x, y) <= threshold_high
G (x, y) = low (0 black) other cases
Edge Detection and Extraction
Because the edge is the part with sharp gray-scale changes, the operation of differential as the part of extraction function variation can be used in Edge Detection and extraction.
(1) first differential calculus (gradient operation)
We can regard the image 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 );
Here, I is the pixel value (such as RGB value) of the image, and (I, j) is the coordinate of the pixel.
The mean value difference can also be used for image gradients:
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 edges are generally implemented by performing gradient operations on the image.
After the microscore is obtained, the intensity and direction of the edge can be calculated using the following formula:
Strength: SQRT (dx ^ 2 + dy ^ 2)
Or: | (dx | + | dy |
Direction: vector (dx, Dy) Direction
(2) second-order differential (Laplace Operation)
The next differentiation of the gradient. This method is applicable only to the intensity of edge detection (not in any direction). It is expressed in the following form in digital image processing:
L (x, y) = 4f (x, y)-| f (x, Y-1) + f (x, y + 1) + f (x-1, Y) + f (x + 1, Y) |
The difference between adjacent pixels is called the difference, and the coefficient group used for the differential operation between pixels is called the differential operator. The calculation formula of FX and FY in the gradient operation is as follows, the formula for the Laplace operation is based on these two differential operators. The actual differential operation is to calculate the target pixel and its surrounding pixels, multiply by the sum of the numeric Matrix Coefficients corresponding to the differential operator, and the calculation result is used as the gray value of the target pixel after the differential operation.
This routine is not complete yet and needs to be improved.
Color Conversion:
(1) Color Strip preparation: overlapping relationship of RGB
(2) Conversion between RGB and Y (brightness, relative to grayscale image), chromatic aberration C1 and C2:
Y = 0.3r + 0.59G + 0.11b
C1 = R-Y = maid-0.59g-0.11b
C2 = B-Y =-0.3r-0.59G + 0.89b
Brightness, color difference RGB:
R = Y + C1;
G = Y-(0.3/0.9) * C1-(0.11/0.59) * C2;
B = Y + C2;
The relationship between chromatic aberration and tone and saturation:
Color h Represents the color difference signal B-Y (C2)
The number of degrees at which the coordinate axis starts to rotate;
The saturation s indicates the distance from the origin.
H = actan (C1/C2 );
S = SQRT (C1 ^ 2 + C2 ^ 2 );
Reverse conversion;
C1 = S * Sinh;
C2 = S * cosh;
(4) gradient-to-gray images ;()
(3) chroma key signal, which is a hard key signal used for synthesis from the blue background standing in front of the person's image.
In the actual chroma key, not only blue, but also other colors can be used as the background for extraction. There are various techniques in natural image synthesis, you can use simple image processing to try the effect similar to the chroma key,
For example, use (R + G)/2-b to extract the blue color with the size of this value. When the value is blue, it is negative, which means that the smaller the value, the closer it is to the blue.