CN105160673A - Object positioning method - Google Patents
Object positioning method Download PDFInfo
- Publication number
- CN105160673A CN105160673A CN201510542302.6A CN201510542302A CN105160673A CN 105160673 A CN105160673 A CN 105160673A CN 201510542302 A CN201510542302 A CN 201510542302A CN 105160673 A CN105160673 A CN 105160673A
- Authority
- CN
- China
- Prior art keywords
- theta
- represent
- parameter
- sampling
- profile
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Landscapes
- Image Analysis (AREA)
Abstract
The invention provides an object positioning method and relates to the field of positioning. The method comprises: obtaining a color map of an object and a three-dimensional model of the object; using an image segmentation method to extract a first contour of the object in the color map; obtaining a specified position and attitude parameter as a current position and attitude parameter; according to the three-dimensional model of the object and the current position and attitude parameter, generating a second contour of the object; step 5, according to the first contour and the second contour, generating a similarity measurement function; according to the current position and attitude parameter, generating a current function value of the similarity measurement function; judging whether the current function value of the similarity measurement function is equal to 1 or not; and when the current function value of the similarity measurement function is equal to 1, outputting the current position and attitude parameter as an optimal position and attitude parameter. According to the object positioning method, the positioning precision can be improved.
Description
Technical field
The present invention relates to image processing field, particularly a kind of localization method of object.
Background technology
The space orientation of three-dimensional body is a major issue in computer vision always.The location of object is the relative space relation will determining itself and camera, comprises the parameter estimation of position and attitude.When object rest, the location of object is equivalent to the demarcation of camera external parameter, thus also may be used for camera calibration.Therefore, it has important application in various fields such as augmented reality, robot navigation, motion tracking and operations medically.
For many years, the orientation problem of researchist to object conducts in-depth research.Under the prerequisite of the three-dimensional model of known object, its main difficulty is the correspondence problem of object module three-dimensional point and its imaging point, and especially, when the three-dimensional model disappearance texture information of target, the coupling of point hardly may.The method of current object localization problem is mainly divided three classes: a class is the corresponding point pair of known some models and its imaging; Equations of The Second Kind is known some models and the corresponding line segment of its imaging; Last class is the unknown algorithm of correspondence.
At present, existing research method mainly concentrates in first kind method.If known 3-5 is to not coplanar corresponding point, the closed solution of Position and orientation parameters can be obtained by solving Polynomial equations.For 3 perspective projection problems (p3p) and 4 perspective projection problems (p4p), Fischler etc. propose and use geometrical perspective method to solve Polynomial equations.If known 6 to or more corresponding point pair, method that is linear or None-linear approximation can be adopted to solve parameter.
The robustness to Point matching method such as Hao Yingming is analyzed.Equations of The Second Kind method, mainly utilizes the restriction relation that model line produces with corresponding projection line, more complicated than first kind theoretical method a lot.Minimum needs three line segments solve Attitude estimation problem, and three line segments can set up three nonlinear equations, and Attitude estimation problem can be converted into the solution solving Nonlinear System of Equations afterwards.
Method for simplifying the analysis, Dhome etc. and Chen etc. establish a specific model coordinate systems and a specific eye coordinate, utilize three line segments to set up the polynomial equation of one 8 dimension to determine the closed solution of attitude parameter.In 3rd class methods, problem to solve difficulty larger, research method main at present has: based on the method for training set, based on the method for test of hypothesis, the method for energy function Optimization Solution.
All there is different problems in above three kinds of methods: first kind method needs the matching relationship of known corresponding point, but, when the texture disappearance of three-dimensional model, be difficult to obtain match point, cause the inefficacy of algorithm.Equations of The Second Kind method requires that three-dimensional model is the object of comparison rule, thus easily extracts feature.For irregularly shaped object, be difficult to the model line and the projection line that find coupling, these class methods easily lost efficacy.The energy function nonlinearity of the 3rd class methods causes numerical optimization routines to be easily absorbed in the local minimum of mistake; Because do not have significant correspondence relation, the estimation of parameter places one's entire reliance upon the numerical optimization of energy function, and cause algorithm complex too high, efficiency is low.
Summary of the invention
The technical problem to be solved in the present invention is, provides a kind of localization method of object, can improve the precision of positioning result.
For solving the problems of the technologies described above, embodiments of the invention provide a kind of localization method of object, comprising:
Step one, obtains the cromogram of an object and the three-dimensional model of described object;
Step 2, uses image segmentation, extracts the first profile of the described object in described cromogram;
Step 3, obtains a Position and orientation parameters of specifying, as current Position and orientation parameters;
Step 4, according to three-dimensional model and the described current Position and orientation parameters of described object, generates the second profile of described object;
Step 5, according to described first profile and described second profile, generates similarity measurements flow function S (Θ);
Step 6, according to described current Position and orientation parameters, generates the current function value of described similarity measurements flow function;
Step 7, judges whether the current function value of described similarity measurements flow function equals 1;
Step 8, when the current function value of described similarity measurements flow function equals 1, using the optimal parameter of described current Position and orientation parameters as Position and orientation parameters, and exports.
Described step 4 comprises:
According to described current location parameter and attitude parameter, coordinate transform is carried out to described three-dimensional model, generate the three-dimensional model after conversion;
Described three-dimensional model after conversion is projected to two dimensional surface, obtains the computer graphic CG image that described object is corresponding;
Extract the second profile of object described in described computer graphic image.
Described step 5 comprises:
Calculate the area of the overlapping region between described first profile and described second profile;
Calculate the first ratio between the area of described overlapping region and the area of described first profile institute enclosing region;
Calculate the second ratio between the area of described overlapping region and the area of described second profile institute enclosing region;
Using the product between described first ratio and described second ratio as similarity measurements flow function.
Described method also comprises:
Step 9, when the current function value of described similarity measurements flow function is less than 1, according to current location parameter and attitude parameter, chooses abundant little increment, samples at parameter space, obtains the Position and orientation parameters after at least two group samplings;
Step 10, by the often group Position and orientation parameters after described sampling, as current Position and orientation parameters, performs described step 4 to described step 6, obtains the similarity measurement functional value that the Position and orientation parameters after the sampling of different group is corresponding;
Step 11, from the similarity measurement functional value that the Position and orientation parameters after the sampling of difference group is corresponding, selects maximal value;
Step 12, judges whether described maximal value equals 1;
Step 13, when described maximal value equals 1, using the optimal parameter of Position and orientation parameters corresponding for described maximal value as Position and orientation parameters, and exports.
Described method also comprises:
Step 14, when described maximal value is less than 1, using Position and orientation parameters corresponding for described maximal value as current Position and orientation parameters, jumps to described step 4.
Described similarity measurements flow function S (Θ) is:
Wherein, A (C
Λ (M (Θ))) be the area of described first profile institute enclosing region; A (C
d) be the area of described second profile institute enclosing region; A
0(Θ) be the area of the overlapping region between described first profile and described second profile.
The described step choosing abundant little increment is carried out according to following formula:
△Θ=-(J
TJ+λI)
-1J
T(S(Θ+△Θ)-S(Θ)),
Wherein, J is Jacobi matrix,
λ is the step-length of iterative computation; I is unit matrix; T represents inversion;
represent and partial derivative is asked to α;
represent and partial derivative is asked to θ;
represent and partial derivative is asked to ω;
represent t
1ask partial derivative;
represent t
2ask partial derivative;
represent t
3ask partial derivative;
T
1, t
2, t
3be respectively location parameter, α, θ, ω are respectively angular pose parameter;
The similarity measurement functional value calculated after spatial sampling is carried out in S (Θ+△ Θ) expression.
Vector root in described Jacobi matrix descends formulae discovery according to this:
represent in alpha parameter spatial sampling;
represent and sample at θ parameter space;
represent and sample at ω parameter space;
represent at t
1parameter space is sampled;
represent at t
2parameter space is sampled;
represent at t
3parameter space is sampled;
D
αrepresent the numerical value in alpha parameter spatial sampling;
D
ωrepresent the numerical value in the sampling of ω parameter space;
D
θrepresent the numerical value in the sampling of θ parameter space;
represent at t
1the numerical value of parameter space sampling;
represent at t
2the numerical value of parameter space sampling;
represent at t
3the numerical value of parameter space sampling;
represent the similarity measurement functional value calculated after alpha parameter spatial sampling;
represent the similarity measurement functional value calculated after the sampling of θ parameter space;
represent the similarity measurement functional value calculated after the sampling of ω parameter space;
represent at t
1the similarity measurement functional value calculated after parameter space sampling;
represent at t
2the similarity measurement functional value calculated after parameter space sampling;
represent at t
3the similarity measurement functional value calculated after parameter space sampling.
Parameter value in described formula is according to following formulae discovery:
The beneficial effect of technique scheme of the present invention is as follows:
The present invention is according to the matching degree of contour of object in three-dimensional model rendering image and input picture, set up the matching measurement that comprises position and attitude parameter, and in this, as objective function, the orientation problem of object is converted into the optimization problem of objective function, finally obtains that there is high-precision positioning result.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet of the localization method of a kind of object shown in the embodiment of the present invention;
Fig. 2 is the principle schematic of the localization method of a kind of object shown in the embodiment of the present invention.
Embodiment
For making the technical problem to be solved in the present invention, technical scheme and advantage clearly, be described in detail below in conjunction with the accompanying drawings and the specific embodiments.
As described in Figure 1, be the localization method of a kind of object shown in the embodiment of the present invention, comprise:
Step 11, obtains the cromogram of an object and the three-dimensional model of described object;
Step 12, uses image segmentation, extracts the first profile of the described object in described cromogram; This first profile i.e. body outline.
Specifically, for the image of any width input, first, use the method for Iamge Segmentation by target object and background separation, then, for the target object after segmentation, the method extracted by outline line, extracts the outline line of target object in image.
Step 13, obtains a Position and orientation parameters of specifying, as current Position and orientation parameters.
Specifically, any given one group of initial position and attitude parameter Θ=(α, θ, ω, t
1, t
2, t
3), wherein, (t
1, t
2, t
3) be location parameter, α, θ, ω are angular pose parameter.
Step 14, according to three-dimensional model and the described current Position and orientation parameters of described object, generates the second profile of described object; This second profile i.e. rendering image outline line.
Step 15, according to described first profile and described second profile, generates similarity measurements flow function S (Θ);
Step 16, according to described current Position and orientation parameters, generates the current function value of described similarity measurements flow function;
Step 17, judges whether the current function value of described similarity measurements flow function equals 1;
Step 18, when the current function value of described similarity measurements flow function equals 1, using the optimal parameter of described current Position and orientation parameters as Position and orientation parameters, and exports.
Described step 14 comprises:
Step 141, according to described current location parameter and attitude parameter, carries out coordinate transform to described three-dimensional model, generates the three-dimensional model after conversion; Specifically, by the parameter provided, given target three-dimensional is carried out coordinate transform.
Step 142, projects to two dimensional surface by the described three-dimensional model after conversion, obtains the computer graphic CG image that described object is corresponding;
Specifically, projective transformation is carried out to the model after conversion, obtains the projected image on two dimensional surface, be called CG image.
Step 143, extracts the second profile of object described in described computer graphic image.
Specifically, for the target object in CG image, extract its outline line.
Described step 15 comprises:
Step 151, calculates the area of the overlapping region between described first profile and described second profile;
Step 152, calculates the first ratio between the area of described overlapping region and the area of described first profile institute enclosing region;
Step 153, calculates the second ratio between the area of described overlapping region and the area of described second profile institute enclosing region;
Step 154, using the product between described first ratio and described second ratio as similarity measurements flow function.
Described method also comprises:
Step 19, when the current function value of described similarity measurements flow function is less than 1, according to current location parameter and attitude parameter, chooses abundant little increment, samples at parameter space, obtains the Position and orientation parameters after at least two group samplings;
Step 110, by the often group Position and orientation parameters after described sampling, as current Position and orientation parameters, performs described step 14 to described step 16, obtains the similarity measurement functional value that the Position and orientation parameters after the sampling of different group is corresponding;
Step 110, from the similarity measurement functional value that the Position and orientation parameters after the sampling of difference group is corresponding, selects maximal value;
Step 112, judges whether described maximal value equals 1;
Step 113, when described maximal value equals 1, using the optimal parameter of Position and orientation parameters corresponding for described maximal value as Position and orientation parameters, and exports.
Described method also comprises:
Step 114, when described maximal value is less than 1, using Position and orientation parameters corresponding for described maximal value as current Position and orientation parameters, jumps to described step 4.
Described similarity measurements flow function is:
Wherein, A (C
Λ (M (Θ))) be the area of described first profile institute enclosing region; A (C
d) be the area of described second profile institute enclosing region; A
0(Θ) be the area of the overlapping region between described first profile and described second profile.
The described step choosing abundant little increment S (Θ) is carried out according to following formula:
△Θ=-(J
TJ+λI)
-1J
T(S(Θ+△Θ)-S(Θ)),
Wherein, J is Jacobi matrix,
λ is the step-length of iterative computation; I is unit matrix; T represents inversion;
represent and partial derivative is asked to α;
represent and partial derivative is asked to θ;
represent and partial derivative is asked to ω;
represent t
1ask partial derivative;
represent t
2ask partial derivative;
represent t
3ask partial derivative;
T
1, t
2, t
3be respectively location parameter, α, θ, ω are respectively angular pose parameter;
The similarity measurement functional value calculated after spatial sampling is carried out in S (Θ+△ Θ) expression.
Vector root in described Jacobi matrix descends formulae discovery according to this:
represent the variable quantity in alpha parameter spatial sampling;
represent the variable quantity in the sampling of θ parameter space;
represent the variable quantity in the sampling of ω parameter space;
represent at t
1the variable quantity of parameter space sampling;
represent at t
2the variable quantity of parameter space sampling;
represent at t
3the variable quantity of parameter space sampling;
Sampling increases under current parameter value or reduces certain numerical value, thus obtain new parameter value, and parameter here represents the numerical value increasing or reduce, because all will sample at 6 parameter spaces, has 6 formula.
D
αrepresent the concrete numerical value in alpha parameter spatial sampling;
D
ωrepresent the concrete numerical value in the sampling of ω parameter space;
D
θrepresent the concrete numerical value in the sampling of θ parameter space;
represent at t
1the concrete numerical value of parameter space sampling;
represent at t
2the concrete numerical value of parameter space sampling;
represent at t
3the concrete numerical value of parameter space sampling;
Concrete sample magnitude can optionally determine, in practical operation, can be defined as 1 or-1.
represent the similarity measurement functional value calculated after alpha parameter spatial sampling;
represent the similarity measurement functional value calculated after the sampling of θ parameter space;
represent the similarity measurement functional value calculated after the sampling of ω parameter space;
represent at t
1the similarity measurement functional value calculated after parameter space sampling;
represent at t
2the similarity measurement functional value calculated after parameter space sampling;
represent at t
3the similarity measurement functional value calculated after parameter space sampling.
Parameter value in described formula is according to following formulae discovery:
Application scenarios of the present invention is below described.
In order to make the present invention clearly, the definition of camera model is first described.
Adopt pinhole camera model, any one three-dimensional point X=[x, y, z, 1] in space
t, the subpoint on imaging plane is u=[u, v, 1]
t, T is the inversion of matrix, then have:
u=K[R|t]X,
Wherein, K is camera Intrinsic Matrix, the transformation matrix of coordinates that [R|t] is camera coordinates system and object coordinates system, i.e. rotation matrix R and translation vector t.
Inner parameter matrix K adopts following form:
Wherein (c
x, c
y) be reference point, f is focal length.Herein in algorithm, (c
x, c
y) elect the central point of image as.[R|t] and f are the parameter needing to determine.In algorithm, camera was calibrated, i.e. known f.
For translation vector t, (t can be used
1, t
2, t
3) represent.
The method for expressing that rotation matrix R is conventional has Eulerian angle representation and hypercomplex number representation.The method adopted herein is Eulerian angle representation, then the required parameter Θ separated can represent by six parameters, namely
Θ=(α,θ,ω,t
1,t
2,t
3),
Wherein, α, θ, ω are respectively the angle rotated around x, y, z tri-axles, (t
1, t
2, t
3) in parameter be position in three dimensions.
The concrete steps of the method for the invention are below described.
The localization method of a kind of single-view irregularly shaped object based on three-dimensional model of the present invention, according to the matching degree of contour of object in three-dimensional model rendering image and input picture, set up the matching measurement that comprises position and attitude parameter, and in this, as objective function, the orientation problem of object is converted into the optimization problem of objective function.Concrete steps comprise:
Step 1, arbitrarily input cromogram in kind, use image partition method to extract the contour of object of cromogram in kind;
Specifically, for the image of any width input, first, use the method for Iamge Segmentation by target object and background separation, then, for the target object after segmentation, the method extracted by outline line, extracts the outline line of target object in image.
Step 2, any given one group of initial position and attitude parameter;
Specifically, any given one group of initial position and attitude parameter Θ=(α, θ, ω, t
1, t
2, t
3), wherein, (t
1, t
2, t
3) be location parameter, α, θ, ω are angular pose parameter.
Step 3, for one group of Position and orientation parameters, carries out coordinate transform to model;
Specifically, by the parameter provided in step 2, given target three-dimensional is carried out coordinate transform.
Step 4, by the model projection after conversion to two dimensional surface, obtains corresponding CG image;
Specifically, projective transformation is carried out to the model after conversion, obtains the projected image on two dimensional surface, be called CG image.
Step 5, extracts the profile of CG objects in images;
Specifically, for the target object in CG image, extract its outline line.
In the present invention, adopt target wheel profile as shape facility, judged the coupling of two width images by the coupling of outline line.For cromogram in kind, due to the impact by illumination and background, be difficult to carry out contours extract with traditional edge detection method, the method based on Iamge Segmentation that the present invention adopts Zhong etc. to propose extracts profile, obtains the region of target object on image and Extracting contour.For three-dimensional model, by setting the parameter of different cameral, utilize OpenGL (open graphic library, OpenGraphicsLibrary) its CG image is played up, by CG image threshold, store profile information by chain code following afterwards, finally obtain the contour images with Single pixel edge.
Step 6, calculates the overlapping region area by step 1 and step 5 gained profile;
Specifically, to extract in input picture in target wheel profile and CG image after target wheel profile respectively, calculate the area of two outline line overlapping regions.
Step 7, calculates the ratio that contour convergence region accounts for two profiles, it can be used as similarity measurements flow function;
Specifically, the ratio that outline line overlapping region accounts for two profiles is respectively calculated, using its product as similarity measurements flow function
wherein, A
0(Θ) be two outline line enclosing region intersection areas, A (C
Λ (M (Θ))) and A (C
d) be respectively corresponding profile institute enclosing region area.
The following specifically describes the definition of outline line similarity measurements flow function.
Target of the present invention to find best camera parameter, makes the contour convergence of three-dimensional model profile on a projection plane and target object on image, so need the similarity function of definition profile.After obtaining the contour images corresponding to input picture and CG image respectively by contours extract, judge the matching degree of three-dimensional model herein according to the coincidence degree of outline line enclosing region.
Definition M (Θ) represents the three-dimensional model under certain attitude parameter, then the projection CG image of three-dimensional model in two dimensional image plane is Λ (M (Θ)), and the contour images that CG image outline extracts gained is C
Λ (M (Θ)).For input picture D, the contour images of contours extract gained is C
d.Herein by C
Λ (M (Θ))middle profile enclosing region and C
dcoincidence degree definition similarity function S (Θ) of middle profile enclosing region:
Wherein, A
0(Θ) be two outline line C
Λ (M (Θ))with C
denclosing region intersection area, A (C
Λ (M (Θ))) and A (C
d) be respectively corresponding profile institute enclosing region area.0≤S≤1, S is larger, and two regions are more similar, during and if only if two area coincidence, S=1.
Step 8, judges whether similarity measurement functional value equals 1.If equal 1, then algorithm terminates, output parameter, otherwise, continue to perform (9);
Specifically, for current given Position and orientation parameters, judge whether similarity measurement functional value equals 1.If equal 1, then algorithm terminates, output parameter, otherwise, continue to perform (9)
Step 9, for current location and attitude parameter, chooses abundant little increment, samples at parameter space.
In the present invention, based on the definition of contour similarity, be the optimization problem of function by position and Attitude estimation problem arises.Namely optimum parameter is found
make similarity function maximum, namely
Because similarity function depends on choosing of parameter Θ, and the three-dimensional model contour projection of correspondence, therefore function S (Θ) is not analytical function.But to any given parameter Θ, the CG image of its correspondence can be rendered, thus calculate similarity function.
In order to ensure efficiency of algorithm again on the basis ensureing arithmetic accuracy, LM (Levenberg-Marquardt) algorithm idea is adopted to solve.LM algorithm is the local characteristics of the improved form of Gauss-Newton method, existing Gauss-Newton method, has again the global property of gradient method.Owing to make use of approximate second derivative information, algorithm is more faster than gradient method, is applicable to solving nonlinear problem.
Specifically, for current Position and orientation parameters, choose little increment at six parameter spaces respectively, sample at parameter space.
Given position and attitude parameter Θ and similarity measurement function S (Θ), need to find △ Θ, and S (Θ+△ Θ) is progressively increased, until S (Θ ') is maximum, then Θ ' is the optimized parameter of required solution.
In LM algorithm, △ Θ is
△Θ=-(J
TJ+λI)
-1J
T(S(Θ+△Θ)-S(Θ)),
Wherein J is Jacobi matrix, namely
because S is single-valued function, Jacobi matrix deteriorates to vector, namely in the directional derivative of each parametric direction:
Because similarity function is not analytical function, non-differentiability, its Jacobi matrix J cannot directly by asking local derviation to obtain.Therefore, in solution procedure, the method for sampling is adopted to approach the value of Jacobi matrix J herein.Choose abundant little increment:
Sampling calculates S (Θ) and S (Θ+△
ivalue Θ), i=1,2 ... 6, its directional derivative can be approached with following formula:
Step 10, to each sampling parameters obtained, performs step 3 to step 7, obtains the similarity measurement functional value of different sampling;
Specifically, to each sampling parameters obtained, the initial position calculated as next time and attitude parameter (being equal to above-mentioned parameter current), perform step 3 to step 7, obtain the similarity measurement functional value that each sampling parameter calculates;
Step 11, compares similarity measurement functional value, chooses wherein maximal value, and judges whether it equals 1.If equal 1, then algorithm terminates, and exports corresponding parameter value; Otherwise, continue to perform step 12;
Specifically, for the similarity measurement functional value that the difference sampling obtained in step 10 calculates, choose wherein maximal value, and judge whether it equals 1.If equal 1, then algorithm terminates, and exports the sampling parameter value of its correspondence, otherwise, continue to perform step 12.
Step 12, using the initial parameter value that the parameter in step 11 corresponding to maximal value calculated as next time, forwards step 3 to.
The invention provides a kind of single-view irregularly shaped object localization method based on three-dimensional model, relate to single image object localization.The present invention is based on the three-dimensional model of object, determine position and the attitude information of object in single image.According to the matching degree of contour of object in three-dimensional model rendering image and input picture, set up the matching measurement that comprises position and attitude parameter, and in this, as objective function, the orientation problem of object is converted into the optimization problem of objective function.First, Extracting contour from cromogram in kind.Then, any given one group of initial attitude parameter, carries out coordinate transform according to parameter to model, and is projected on imaging plane, obtains corresponding CG image.For projection gained CG image, extract contour of object, obtain corresponding outline line and region.Calculate two profile similarity measurement functions, judge the matching degree of profile thus.If two profiles mate completely, then be final solve parameter to parameter, algorithm terminates.If two profile Incomplete matchings, then carry out parameter space sampling to parameter current, obtain different sampling parameters.For each sampling parameter, calculate similarity measurements flow function respectively, choose the parameter making it maximum.For this parameter, judge outline situation, if profile mates completely, then it solves parameter for optimum; Otherwise using the initial parameter that this parameter calculated as next time, resampling calculates, until profile mates completely.
The invention discloses a kind of localization method of the single-view irregularly shaped object based on three-dimensional model.The space orientation of three-dimensional body is a major issue in computer vision always.The location of object is the relative space relation will determining itself and camera, comprises the parameter estimation of position and attitude.Under the prerequisite of the three-dimensional model of known object, existing method main difficulty is: the correspondence problem of object module three-dimensional point and its imaging point, and especially, when the three-dimensional model disappearance texture information of target, the coupling of point hardly may.The present invention is based on three-dimensional model to object localization in single image, a kind of method based on outline is proposed, body outline in input picture is mated with the outline line of renders three-dimensional model under given position and attitude parameter, matching error is expressed as the function of position and attitude parameter, derivative and target function value is calculated by discrete sampling, use LM (Levenberg-Marquardt) method to solve, finally obtain that there is high-precision positioning result.Acquired results can be used as input market demand in more senior computer vision, augmented reality task.
The present invention is according to the matching degree of contour of object in three-dimensional model rendering image and input picture, set up the matching measurement that comprises position and attitude parameter, and in this, as objective function, the orientation problem of object is converted into the optimization problem of objective function.By gained positioning result of the present invention, there is very high precision, and efficiency of algorithm is very high.Found by the comparison of different pieces of information collection, positioning result of the present invention, translation error controls substantially in 0.1 centimetre, and angular error controls substantially within 0.5 degree, and averaging time is 45 milliseconds.
The above is the preferred embodiment of the present invention; it should be pointed out that for those skilled in the art, under the prerequisite not departing from principle of the present invention; can also make some improvements and modifications, these improvements and modifications also should be considered as protection scope of the present invention.
Claims (9)
1. a localization method for object, is characterized in that, comprising:
Step one, obtains the cromogram of an object and the three-dimensional model of described object;
Step 2, uses image segmentation, extracts the first profile of the described object in described cromogram;
Step 3, obtains a Position and orientation parameters of specifying, as current Position and orientation parameters;
Step 4, according to three-dimensional model and the described current Position and orientation parameters of described object, generates the second profile of described object;
Step 5, according to described first profile and described second profile, generates similarity measurements flow function S (Θ);
Step 6, according to described current Position and orientation parameters, generates the current function value of described similarity measurements flow function;
Step 7, judges whether the current function value of described similarity measurements flow function equals 1;
Step 8, when the current function value of described similarity measurements flow function equals 1, using the optimal parameter of described current Position and orientation parameters as Position and orientation parameters, and exports.
2. method according to claim 1, is characterized in that, described step 4 comprises:
According to described current location parameter and attitude parameter, coordinate transform is carried out to described three-dimensional model, generate the three-dimensional model after conversion;
Described three-dimensional model after conversion is projected to two dimensional surface, obtains the computer graphic CG image that described object is corresponding;
Extract the second profile of object described in described computer graphic image.
3. method according to claim 1, is characterized in that, described step 5 comprises:
Calculate the area of the overlapping region between described first profile and described second profile;
Calculate the first ratio between the area of described overlapping region and the area of described first profile institute enclosing region;
Calculate the second ratio between the area of described overlapping region and the area of described second profile institute enclosing region;
Using the product between described first ratio and described second ratio as similarity measurements flow function.
4. method according to claim 1, is characterized in that, described method also comprises:
Step 9, when the current function value of described similarity measurements flow function is less than 1, according to current location parameter and attitude parameter, chooses abundant little increment, samples at parameter space, obtains the Position and orientation parameters after at least two group samplings;
Step 10, by the often group Position and orientation parameters after described sampling, as current Position and orientation parameters, performs described step 4 to described step 6, obtains the similarity measurement functional value that the Position and orientation parameters after the sampling of different group is corresponding;
Step 11, from the similarity measurement functional value that the Position and orientation parameters after the sampling of difference group is corresponding, selects maximal value;
Step 12, judges whether described maximal value equals 1;
Step 13, when described maximal value equals 1, using the optimal parameter of Position and orientation parameters corresponding for described maximal value as Position and orientation parameters, and exports.
5. method according to claim 4, is characterized in that, described method also comprises:
Step 14, when described maximal value is less than 1, using Position and orientation parameters corresponding for described maximal value as current Position and orientation parameters, jumps to described step 4.
6. method according to claim 4, is characterized in that, described similarity measurements flow function S (Θ) is:
Wherein, A (C
Λ (M (Θ))) be the area of described first profile institute enclosing region; A (C
d) be the area of described second profile institute enclosing region; A
0(Θ) be the area of the overlapping region between described first profile and described second profile.
7. method according to claim 4, is characterized in that, described in choose abundant little increment △ Θ step carry out according to following formula:
△Θ=-(J
TJ+λI)
-1J
T(S(Θ+△Θ)-S(Θ)),
Wherein, J is Jacobi matrix,
λ is the step-length of iterative computation; I is unit matrix; T represents inversion;
represent and partial derivative is asked to α;
represent and partial derivative is asked to θ;
represent and partial derivative is asked to ω;
represent t
1ask partial derivative;
represent t
2ask partial derivative;
represent t
3ask partial derivative;
T
1, t
2, t
3be respectively location parameter, α, θ, ω are respectively angular pose parameter;
S(Θ+△Θ)
Represent the similarity measurement functional value calculated after carrying out spatial sampling.
8. method according to claim 7, is characterized in that, the vector root in described Jacobi matrix descends formulae discovery according to this:
represent the variable quantity in alpha parameter spatial sampling;
represent the variable quantity in the sampling of θ parameter space;
represent the variable quantity in the sampling of ω parameter space;
represent at t
1the variable quantity of parameter space sampling;
represent at t
2the variable quantity of parameter space sampling;
represent at t
3the variable quantity of parameter space sampling;
D
αrepresent the concrete numerical value in alpha parameter spatial sampling;
D
ωrepresent the numerical value in the sampling of ω parameter space;
D
θrepresent the concrete numerical value in the sampling of θ parameter space;
represent at t
1the concrete numerical value of parameter space sampling;
represent at t
2the concrete numerical value of parameter space sampling;
represent at t
3the concrete numerical value of parameter space sampling;
represent the similarity measurement functional value calculated after alpha parameter spatial sampling;
represent the similarity measurement functional value calculated after the sampling of θ parameter space;
represent the similarity measurement functional value calculated after the sampling of ω parameter space;
represent at t
1the similarity measurement functional value calculated after parameter space sampling;
represent at t
2the similarity measurement functional value calculated after parameter space sampling;
represent at t
3the similarity measurement functional value calculated after parameter space sampling.
9. method according to claim 8, is characterized in that, the parameter value in described formula is according to following formulae discovery:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510542302.6A CN105160673A (en) | 2015-08-28 | 2015-08-28 | Object positioning method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510542302.6A CN105160673A (en) | 2015-08-28 | 2015-08-28 | Object positioning method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN105160673A true CN105160673A (en) | 2015-12-16 |
Family
ID=54801515
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510542302.6A Pending CN105160673A (en) | 2015-08-28 | 2015-08-28 | Object positioning method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105160673A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111353941A (en) * | 2018-12-21 | 2020-06-30 | 广州幻境科技有限公司 | Space coordinate conversion method |
CN111598954A (en) * | 2020-04-21 | 2020-08-28 | 哈尔滨拓博科技有限公司 | Rapid high-precision camera parameter calculation method |
CN113554616A (en) * | 2021-07-21 | 2021-10-26 | 深圳市蓝蓝科技有限公司 | Online measurement guiding method and system based on numerical control machine tool |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1747559A (en) * | 2005-07-29 | 2006-03-15 | 北京大学 | Three-dimensional geometric mode building system and method |
CN103914874A (en) * | 2014-04-08 | 2014-07-09 | 中山大学 | Compact SFM three-dimensional reconstruction method without feature extraction |
CN104154877A (en) * | 2014-09-03 | 2014-11-19 | 中国人民解放军国防科学技术大学 | Three-dimensional reconstruction and size measurement method of complex convex-surface object |
-
2015
- 2015-08-28 CN CN201510542302.6A patent/CN105160673A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1747559A (en) * | 2005-07-29 | 2006-03-15 | 北京大学 | Three-dimensional geometric mode building system and method |
CN103914874A (en) * | 2014-04-08 | 2014-07-09 | 中山大学 | Compact SFM three-dimensional reconstruction method without feature extraction |
CN104154877A (en) * | 2014-09-03 | 2014-11-19 | 中国人民解放军国防科学技术大学 | Three-dimensional reconstruction and size measurement method of complex convex-surface object |
Non-Patent Citations (2)
Title |
---|
JEFFREY S. BEIS 等: "Indexing without invariants in 3D object recognition", 《IEEE TRANSACTIONS ON PATTERN ANALYSIS AND MACHINE INTELLIGENCE》 * |
李成龙 等: "基于3维模型的单视图不规则物体定位", 《计算机辅助设计与图形学学报》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111353941A (en) * | 2018-12-21 | 2020-06-30 | 广州幻境科技有限公司 | Space coordinate conversion method |
CN111598954A (en) * | 2020-04-21 | 2020-08-28 | 哈尔滨拓博科技有限公司 | Rapid high-precision camera parameter calculation method |
CN113554616A (en) * | 2021-07-21 | 2021-10-26 | 深圳市蓝蓝科技有限公司 | Online measurement guiding method and system based on numerical control machine tool |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP2751777B1 (en) | Method for estimating a camera motion and for determining a three-dimensional model of a real environment | |
Bazin et al. | Motion estimation by decoupling rotation and translation in catadioptric vision | |
US10288425B2 (en) | Generation of map data | |
CN104408732A (en) | Large-view-field depth measuring system and method based on omni-directional structured light | |
KR20110080097A (en) | Feature registration apparatus for image based localization and method the same | |
Zhao et al. | Reconstruction of textured urban 3D model by fusing ground-based laser range and CCD images | |
Dawood et al. | Harris, SIFT and SURF features comparison for vehicle localization based on virtual 3D model and camera | |
Khoshelham et al. | Generation and weighting of 3D point correspondences for improved registration of RGB-D data | |
Perez-Yus et al. | Extrinsic calibration of multiple RGB-D cameras from line observations | |
CN105160673A (en) | Object positioning method | |
Das et al. | Extrinsic calibration and verification of multiple non-overlapping field of view lidar sensors | |
Fang et al. | Ground-texture-based localization for intelligent vehicles | |
CN105339981A (en) | Method for registering data using set of primitives | |
CN101718548A (en) | Position and posture processing method based on plane marker | |
Ding et al. | Generalized sum of Gaussians for real-time human pose tracking from a single depth sensor | |
CN105550667A (en) | Stereo camera based framework information action feature extraction method | |
Sabatta et al. | Vision-based path following using the 1D trifocal tensor | |
Lee et al. | Visual odometry for absolute position estimation using template matching on known environment | |
Villanueva-Escudero et al. | Monocular visual odometry based navigation for a differential mobile robot with android OS | |
Zhi et al. | Key technology of mine underground mobile positioning based on LiDAR and coded sequence pattern | |
Kang et al. | 3D urban reconstruction from wide area aerial surveillance video | |
Fan et al. | Simple but effective scale estimation for monocular visual odometry in road driving scenarios | |
Li et al. | Open-structure: a structural benchmark dataset for slam algorithms | |
Wei et al. | SLC-VIO: a stereo visual-inertial odometry based on structural lines and points belonging to lines | |
Ren | An improved binocular LSD_SLAM method for object localization |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20151216 |