Summary of the invention
For above shortcomings in prior art, the invention provides and a kind ofly can carry out to left view sheet and right view sheet the stereoscopic vision auto color calibration system of color calibration, in order to the left view sheet of the stereo visual system collection to mobile robot and the color distortion of right view sheet, adjusted, solve mobile robot's stereo visual system easily because left and right view color distortion causes the not good problem of imaging matching effect, in order to help mobile robot better to carry out object identification.
For solving the problems of the technologies described above, realize goal of the invention, the technical solution used in the present invention is as follows:
A stereoscopic vision auto color calibration system, comprises picture load module, unique point processing module, picture adjustment module; Described picture load module is used for inputting left view sheet and right view sheet; Described unique point processing module is for extracting many stack features pixel pair from left view sheet and right view sheet, the left view feature pixel of every stack features pixel centering and right view feature pixel represent Same Physical point, and according to the extracted left view feature pixel of each stack features pixel centering and the rgb value of right view feature pixel, calculate the RGB triple channel Chromaticity parameters of left view sheet and right view sheet; Described picture adjustment module utilizes RGB triple channel Chromaticity parameters to adjust the rgb value of each pixel in right view sheet, completes the color calibration to left view sheet and right view sheet.
As a kind of prioritization scheme of such scheme, in described unique point processing module, left view feature pixel and right view feature pixel are the unique point with shape facility.
As the another kind of prioritization scheme of such scheme, described unique point processing module utilizes SIFT conversion to extract left view feature pixel and right view feature pixel.
Further optimization as such scheme, described unique point processing module is according to the extracted left view feature pixel of each stack features pixel centering and the rgb value of right view feature pixel, set up color map relational expression, utilize least square method, the RGB triple channel Chromaticity parameters that calculates left view sheet and right view sheet, described color map relational expression is:
Wherein, (Rr, Gr, Br) be the rgb value of feature pixel centering right view feature pixel, (Rl, Gl, Bl) is the rgb value of this feature pixel centering left view feature pixel, (KR, BR), (KG, BG), (KB, BB) is respectively RGB triple channel Chromaticity parameters.
As the further optimization of such scheme, described picture adjustment module utilizes RGB triple channel Chromaticity parameters to adjust the rgb value of each pixel in right view sheet:
Wherein, (rr, gr, br) is the rgb value of adjusting pixel in front right view sheet, (rr ', gr ', br ') for adjusting the rgb value of this pixel in rear right view sheet.
Than prior art, tool of the present invention has the following advantages:
1, stereoscopic vision auto color calibration system provided by the invention, can adjust the color of right view sheet, left view sheet and right view sheet color are reached unanimity, solved in existing mobile robot's stereo visual system the not good problem of imaging matching effect causing due to the difference of color in left view sheet and right view sheet.
2, stereoscopic vision auto color calibration system provided by the invention, calculated amount is little, can adjust in real time online the difference of color in left view sheet and right view sheet, and real-time is good, guarantees the optimum matching effect of stereo visual system.
3, stereoscopic vision auto color calibration system provided by the invention, does not need additionally to arrange scaling board, can be to any environment, and left view sheet and right view sheet that random time obtains are processed in real time, have environment self-adaption.
Embodiment
Stereoscopic vision auto color calibration system provided by the invention, for mobile apparatus human stereo vision, mobile robot is provided with two cameras in left and right, for simulating people's eyes.When localization for Mobile Robot jobbie, two of left and right camera is taken this object simultaneously.The camera on the left side obtains left view sheet, and the camera on the right obtains right view sheet.
Stereoscopic vision auto color calibration system provided by the invention, as shown in Figure 1, comprises picture load module, unique point processing module, picture adjustment module, described picture load module is used for inputting left view sheet and right view sheet, described unique point processing module is for extracting many stack features pixel pair from left view sheet and right view sheet, the left view feature pixel of every stack features pixel centering and right view feature pixel represent Same Physical point, be that left view feature pixel refers to this physical points imaging point in left camera, right view feature pixel refers to this physical points imaging point in right camera, as shown in Figure 2, point a, point b is respectively left view feature pixel, point a ', point b ' is respectively right view feature pixel, its mid point a and some a ' are a stack features pixel pair, point b and some b ' are a stack features pixel pair.And according to the extracted left view feature pixel of each stack features pixel centering and the rgb value of right view feature pixel, calculate the RGB triple channel Chromaticity parameters of left view sheet and right view sheet; Described picture adjustment module utilizes RGB triple channel Chromaticity parameters to adjust the rgb value of each pixel in right view sheet, completes the color calibration to left view sheet and right view sheet.
Rgb color pattern is a kind of color standard of industry member, by variation and their stacks each other of red (R), green (G), blue (B) three Color Channels are obtained to color miscellaneous, RGB is the color that represents three passages of red, green, blue.What therefore, in picture, the color of each pixel was determined by the rgb value of this pixel.When want to adjust in picture color time, need to adjust the rgb value of each pixel in picture.
In order to reduce error, unique point processing module can be extracted 100 stack features pixels pair, and to this 100 stack features pixel to processing.Can find out, stereoscopic vision auto color calibration system provided by the invention, RGB triple channel Chromaticity parameters can reflect the rgb value of every stack features pixel centering left view feature pixel and the mapping relations between the rgb value of right view feature pixel.Like this, when adjusting the color of right view sheet, the rgb value of adjusting pixel in front right view sheet of take is standard, utilize RGB triple channel Chromaticity parameters, obtain the rgb value of adjusting this pixel in rear right view sheet, for adjusting the color of right view sheet, left view sheet and right view sheet color are reached unanimity, solved in existing robot stereo vision's system the not good problem of imaging matching effect causing due to the difference of color in left view sheet and right view sheet.In addition, the present invention does not need, according to actual conditions, scaling board is additionally set, unique point processing module acquiescence left view sheet is that scaling board is (when specifically apply, also can take right view sheet as scaling board), when mobile robot is at any environment, when the left view sheet that random time obtains and right view sheet, the present invention can adjust the color of right view sheet rapidly, the optimum matching effect that has guaranteed stereo visual system, has environment self-adaption.
As prioritization scheme of the present invention, described unique point processing module utilizes SIFT conversion to extract left view feature pixel and right view feature pixel.Described unique point processing module is according to the extracted left view feature pixel of each stack features pixel centering and the rgb value of right view feature pixel, set up color map relational expression, utilize least square method, the RGB triple channel Chromaticity parameters that calculates left view sheet and right view sheet, described color map relational expression is:
Wherein, (Rr, Gr, Br) be the rgb value of feature pixel centering right view feature pixel, (Rl, Gl, Bl) is the rgb value of this feature pixel centering left view feature pixel, (KR, BR), (KG, BG), (KB, BB) is respectively RGB triple channel Chromaticity parameters.
Described picture adjustment module utilizes RGB triple channel Chromaticity parameters to adjust the rgb value of each pixel in right view sheet:
Wherein, (rr, gr, br) is the rgb value of adjusting pixel in front right view sheet, (rr ', gr ', br ') for adjusting the rgb value of this pixel in rear right view sheet.
SIFT converts the (abbreviation of Scale-invariant feature transform, be yardstick invariant features conversion) be used for detecting and describe the locality feature in image, it finds extreme point in space scale, and extracts its position, yardstick, rotational invariants.The left view feature pixel and the right view feature pixel that utilize SIFT conversion to obtain are SIFT unique point, SIFT feature pixel has good robustness and stability for the difference of color, rgb value and the mapping relations between the rgb value of right view feature pixel of this category feature pixel centering left view feature pixel are more stable, more accurate to solving the RGB triple channel Chromaticity parameters obtaining according to this category feature pixel, when adjusting the color of right view sheet, make the right view sheet color of acquisition more accurate.As another kind of scheme, in described unique point processing module, left view feature pixel and right view feature pixel are the unique point with shape facility.Shape facility mainly can be divided into based on contour shape and based on region shape two classes, and the shape facility based on contour shape is to extract from profile, and the shape facility based on region shape is to extract from region shape.User can extract according to actual conditions the shape facility of certain type.No matter be to utilize SIFT unique point or Feature Points, the present invention only needs according to a small amount of feature pixel pair, just can calculate RGB triple channel Chromaticity parameters comparatively accurately, calculated amount is little, can adjust in real time online the difference of color in left view sheet and right view sheet, real-time is good, guarantees the optimum matching effect of stereo visual system.
When calculating color map relational expression (formula 1), utilize least square method can solve easily RGB triple channel Chromaticity parameters, error is minimum.In the present embodiment, (KR, BR), (KG, BG), (KB, BB) three groups of Chromaticity parameters have reflected respectively R, G, the three-channel aberration mapping relations of B.During concrete enforcement, from left view sheet and right view sheet, extract somely to feature pixel pair, add up respectively these feature pixel centering right view feature pixels at the value Rr of R passage, the value Gr of G passage, the value Br of B passage; Left view feature pixel is at the value Rl of R passage, the value Gl of G passage, the value Bl of B passage; By several feature pixel centering right view feature pixels at the value Rr of R passage and left view feature pixel at the value Rl of R passage, utilize least square method to solve (KR, BR); In like manner, solve (KG, BG), (KB, BB).Like this, (KR, the BR) of acquisition, (KG, BG), (KB, BB) can stably reflect the three-channel aberration mapping relations of RGB in left view sheet and right view sheet.When adjusting the color of right view sheet, obtain the rgb value (rr, gr, br) of adjusting pixel in front right view sheet, according to formula 2 calculate adjust after in right view sheet this pixel rgb value (rr ', gr ', br '), by (rr ', gr ', br ') adjust the color of this pixel in right view sheet, left view sheet and right view sheet color are reached unanimity, error is minimum.
In sum, stereoscopic vision auto color calibration system provided by the invention, from left view sheet and right view sheet, extract many stack features pixel pair, and utilize these feature pixels to resolving RGB triple channel Chromaticity parameters, finally, utilize RGB triple channel Chromaticity parameters to adjust the rgb value of each pixel in right view sheet.Can adjust the color of right view sheet, left view sheet and right view sheet color are reached unanimity, solve in existing robot stereo vision's system, the not good problem of imaging matching effect causing due to the difference of color in left view sheet and right view sheet.Do not need additionally to arrange scaling board, can be to any environment, left view sheet and right view sheet that random time obtains are processed in real time, have environment self-adaption.
Finally explanation is, above embodiment is only unrestricted in order to technical scheme of the present invention to be described, although the present invention is had been described in detail with reference to preferred embodiment, those of ordinary skill in the art is to be understood that, can modify or be equal to replacement technical scheme of the present invention, and not departing from aim and the scope of technical solution of the present invention, it all should be encompassed in the middle of claim scope of the present invention.