Embodiment
The below describes specific embodiments of the present invention in conjunction with the accompanying drawings and embodiments in detail.But the present invention is not subjected to the restriction of embodiment described here, provides these examples just for more abundant and full disclosure invention, and scope of the present invention is informed those skilled in the art.
Fig. 1 is the process flow diagram of the bearing calibration of inner bore of part azimuthal error in the axis hole assembling, and each step that it has provided inventive method marks with S1-S5 respectively, and has provided the front and back logical relation that each step is carried out.The below will be described in detail the enforcement of each step.
Fig. 2 is that the critical component of shaft parts and inner bore of part rigging error dressing plate is explained as follows with the error correction platform synoptic diagram of six shaft mechanical arm shaft parts of camera and inner bore of part assembling: six shaft mechanical arms 1 contain the 6th axle 11, the 6th shaft end 111, the 6th axis in axis line 112, camera 2, camera axis 21, camera as on plane 22, the part 3, inner bore of part 31, inner bore of part with endoporus along 311, under the inner bore of part along 312, the paw 5 of the platform 4 of retaining element 3, shaft parts 33, gripping shaft parts 33.Inner bore of part 31 is circular hole, square hole or delthyrium; Camera is monocular cam.
Camera 2 is fixed on the 6th shaft end 111 of six shaft mechanical arms 1, and camera axis 21 is parallel with the 6th axis in axis line 112 of six shaft mechanical arms 1.Camera 2 moves and is moved with six shaft mechanical arms the 6th shaft end 111.Camera 2 move to inner bore of part 31 directly over certain altitude place (certain height value between the optional 10cm-20cm), guarantee the imaging of inner bore of part 31 in camera image account for regional percentage between 50%-80%.To guarantee simultaneously the picture plane 22 of camera and the platform 4 parallel (when part 3 is gripped exactly, parallel with the platform of retaining element 3 along the plane, place on the inner bore of part 31) of retaining element 3.On the basis of these mounting plate 4 synoptic diagram, below further analyze inner bore of part 31 and in camera 2, become Characteristic of Image.
Fig. 3 is that camera 2 is when being positioned at inner bore of part 31 top, the image-forming principle synoptic diagram of inner bore of part 31 in camera, wherein critical piece comprises: camera 2, the picture plane 22 of camera, part 3 with holes, inner bore of part 31, on the inner bore of part along 311, under the inner bore of part along 312, the upper surface 32 of part 3, under the perfect condition, part 3 during by accurate clamping on the inner bore of part along plane, 311 place 6, camera focus 23, the annular region 221 that inner bore of part 31 forms in as plane 22 at camera, camera is as the outward flange 222 of annular region in the plane 22, as the inward flange 223 of annular region in the plane.
(a) camera 2 is moved to directly over the inner bore of part 31 among Fig. 3, the picture plane 22 of camera in the ideal situation, part 3 is error free fixedly the time, and plane, place 6, inner bore of part 31 upper edge is parallel; And in fact since part 3 exist angle and offset error inner bore of part 31 upper edges 311 place part upper surfaces 32 not with part 3 error free fixedly the time plane, place, inner bore of part 31 upper edge 6 overlap with parallel.(b) is inner bore of part 31 forms image in the picture plane 22 of camera principle among Fig. 3, what inner bore of part 31 projected camera in the focus 33 by camera 2 as can be known is an annular region 221 as the image in the plane 22, wherein on the inner bore of part along 311 outward flanges 222 that in camera image, form annular region, under the inner bore of part along 312 outward flanges 223 that in camera image, form annular region.
Below in conjunction with Fig. 3, to camera 2 move to part 3 error free fixedly the time on the inner bore of part behind parallel position, plane, 311 place 6, inner bore of part 311 forms the phenomenon of annular region and carries out analytical explanation in camera image.
Suppose that camera 2 stably is fixed on the six shaft mechanical arms 1, the repetitive positioning accuracy of six shaft mechanical arms 1 is 0.05mm, and the positioning error of camera 2 that is fixed on the 6th shaft end 111 of six shaft mechanical arms 1 is limited in the 0.2mm;
OXYZ is the world coordinate system of the inner bore of part under the perfect condition, it is defined as follows: OXY be part 3 error free fixedly the time on the inner bore of part along plane, 311 place 6, camera 2 is moved to directly over the inner bore of part 21, and parallel with OXY, OZ is the central shaft of the accurately rear inner bore of part 21 of part 3 clampings under the perfect condition;
O ' X ' Y ' Z ' is the world coordinates of actual inner bore of part, and it is defined as: O ' is the upper along 311 geometric center of inner bore of part, O ' X ' Y ' be on the inner bore of part along plane, 311 place 32, O ' Z ' is the central shaft of inner bore of part 31;
Oxyz is the camera coordinate system, and it is defined as: o is camera main shaft 21 and the intersection point of camera as plane 22, and oxy represents camera as plane 22, and oz is outside as plane 22 perpendicular to camera.
To OXYZ, O ' X ' Y ' Z ', oxyz, carry out following analysis based on above:
Make (x
c, y
c, z
c) any point the three-dimensional coordinate among camera coordinate system oxyzs of expression on the object, (u, v) expression this point through the image transformation shown in Fig. 3 (b) after, camera as plane 22 on the coordinate of corresponding point.According to the projection imaging model, put as can be known and be expressed as the corresponding relation in plane and the camera coordinate system:
Wherein, (u
0, v
0) be camera central shaft 21 and the coordinate of camera as plane 22 intersection points, f is the camera focal length, and Δ x, Δ y are the distance between camera level and the vertical direction sensitivity speck, and λ is scale factor.
Can draw from formula (1)
λ=1/z
c (2)
From (3), (4) formula can find out camera as the position of the picture point (u, v) the plane 22 in the camera parameter f, Δ x is in the known situation of Δ y, only with the coordinate (x of actual object in the camera coordinate system
c, y
c, z
c) relevant, and u only with x
c, z
cRelevant, v only with y
c, z
cRelevant.At x
c, y
cIn the fixing situation, z
cLarger, u, v is less, thereby the figure that forms in camera image is less, form the phenomenon of annular region 221 in camera image such as the inner bore of part 31 among Fig. 3 (b): lower edge 312 correspondences of inner bore of part annular region inward flange 223, annular region outward flange 222 along 312 correspondences on the inner bore of part.
Can draw to draw a conclusion: in shaft parts and inner bore of part assembling, camera be positioned at treat inner bore of part 31 directly over, and when camera central shaft 21 is parallel with inner bore of part central shaft (O ' Z '), the annular region outward flange 222 and the inward flange 222 that extract in the image that camera obtains are concentricity, that is:
Annular region outward flange center is relevant with the inner bore of part shape with outer peripheral distance to inward flange.In the fittage of reality, the shape of inner bore of part 31 may be circular, square or triangle, and the assembling of the inner bore of part 31 of circular shaft parts 33 and circle is the most general assembling mode, below we mainly take circular hole as example, the annular region inward flange that explanation inner bore of part 31 forms in camera image, the distance relation between the outward flange are further according to this relation design rigging error Correction Strategies.
Fig. 4 is that camera 2 is positioned at circular inner bore of part 31 tops, and part 3 is when existing the skew of different position and angle rotation error, the annular region synoptic diagram that inner bore of part 31 forms in camera 2, wherein, critical piece comprises: camera 2, part 3, inner bore of part 31, on the inner bore of part along 311, under the inner bore of part along 312, part outer edge 32, the annular region 221 that inner bore of part 31 forms in camera image, the outward flange 222 of the annular region that inner bore of part 31 forms, the outward flange 223 of the annular region that inner bore of part 31 forms, the edge 224 that the part outer edge forms in camera image.
(a) is that part 3 is by accurately clamping among Fig. 4, when camera 2 is positioned at directly over the circular inner bore of part 31, the synoptic diagram of the edge image that part 3 forms, (b) is that part 3 is by accurately clamping among Fig. 4, when camera 2 is positioned at directly over the circular inner bore of part 31, the synoptic diagram of the edge image that inner bore of part 31 forms, (c) is that part 3 exists when slightly taking back site error among Fig. 4, camera 2 is positioned at inner bore of part 31 tops, the synoptic diagram of edge image that inner bore of part 31 becomes, (d) is that part 3 exists when taking back more greatly site error among Fig. 4, the position that takes over, the top that camera 2 is positioned at circular inner bore of part 31, the synoptic diagram (dotted line represents to be covered part by inner bore of part 31 inwalls) of edge image that inner bore of part 31 becomes, when (e) is the less dextrorotation error of part 3 existence among Fig. 4, camera 2 is positioned at directly over the circular inner bore of part 31, the synoptic diagram of the edge image that inner bore of part is 31 one-tenth, (f) is that part 3 is when existing dextrorotation and position to move to left double error among Fig. 4, camera 2 is positioned at the top of circular inner bore of part 31, the synoptic diagram of circular edge image that inner bore of part 31 becomes, (g) is that part 3 is when existing dextrorotation and position to move to right double error among Fig. 4, camera 2 is positioned at the top of circular inner bore of part 31, the synoptic diagram of circular edge image that inner bore of part 31 becomes, when (h) is the larger dextrorotation error of part 3 existence among Fig. 4, camera 2 is positioned at the top of circular inner bore of part 31, the synoptic diagram of circular edge image that inner bore of part 31 becomes.
Provided among Fig. 4 when part 3 locations and angular error, on the inner bore of part along 311, under the inner bore of part along the morphological feature at 312 several edges that in camera image, may form, these features are the images that obtain by to camera 2, adopt image processing algorithm to extract the edge of annular region from the image of camera, the concrete steps of image processing algorithm are as follows:
Step 2a: the image of inner bore of part 31 is converted into gray level image, and adopts Gaussian filter that gray level image is carried out smoothing processing;
Step 2b: Buddhist nun (Canny) algorithm extraction gray-scale Image Edge is born in employing according to gray level image, obtains the Single pixel edge image of binaryzation;
Step 2c: adopt corrosion and expansion algorithm, remove the shorter and smaller noise edge in the Single pixel edge image background, the curve that has breakpoint on the Single pixel edge image is connected to become long continuous curve, the image that obtains having longer edges;
Step 2d: adopt the method for Hough transformation, from the image with longer edges, extract the curve similar to known inner bore of part edge geometric configuration, be: from the image with longer edges, extract circle, ellipse and long camber line;
Step 2e: according to the camera imaging principle, obtain following three features: be to be positioned at outward flange inside fully and inward flange is parallel with the outward flange part along corresponding inward flange under the curve, inner bore of part of complete known form along corresponding outward flange on the inner bore of part, according to outward flange curve and the inward flange curve of described three feature extraction inner bore of parts formation annular region in the image that comprises with inner bore of part edge geometric configuration similar curves.
Step 2e: according to the camera imaging principle, obtain following three features: be to be positioned at outward flange inside fully and inward flange is parallel with the outward flange part along corresponding inward flange under the curve, inner bore of part of complete known form along corresponding outward flange on the inner bore of part; For the inner bore of part 31 of circle, above-mentioned three are characterized as: be that to be positioned at outward flange inside fully along the inward flange of 312 correspondences under complete circle or ellipse, the circular inner bore of part parallel with the outward flange part with inward flange along the outward flange of 311 correspondences on the circular inner bore of part; In the image that comprises with inner bore of part edge geometric configuration similar curves, form outward flange curve and the inward flange curve of annular region according to described three feature extraction inner bore of parts, that is: extract outward flange (oval or circle) and inward flange (oval, the round or one section arc) curve of the annular region that circular inner bore of part 31 forms in comprising circle, oval and image than spiral.
When inner bore of part is shaped as square or during triangle, need to step 2d and the step 2e of above-mentioned image processing algorithm be made amendment, so that the inner bore of part that image processing algorithm can square shaped and annular region outward flange and the inward flange that leg-of-mutton inner bore of part forms in camera image extract.
For square (perhaps leg-of-mutton) inner bore of part, the step 2d of above-mentioned image processing algorithm and step 2e are revised as:
Step 2d: adopt the method for Hough transformation, extract the straight line of segmentation from the image with longer edges, the position relationship that exists between the straight line of follow-up segmentation extracts square (the perhaps triangle) that have in the longer edges image;
Step 2e: according to the camera imaging principle, obtain following three features: the outward flange along 311 correspondences on the inner bore of part of square (perhaps triangle) is the square or rectangular (perhaps triangle) similar to the inner bore of part shape, inward flange along 312 correspondences under square (perhaps triangular form) inner bore of part is positioned at inner parallel with outward flange with inward flange or the coincidence of outward flange fully, outward flange and the inward flange curve of the annular region that forms in the image that comprises square (perhaps triangle) according to three square (perhaps leg-of-mutton) inner bore of parts 31 of feature extraction.
Fig. 5 is that part 2 is when existing different deviation, the different annular regions that inner bore of part 31 forms in camera image, by the spatial alternation of polar coordinates to rectangular coordinate, the different two-dimensional curve figure that forms, wherein, critical piece comprises: the annular region outward flange 222 that inner bore of part 31 forms in camera image, the annular region outward flange 223 that inner bore of part 31 forms in camera image.
Figure 5 (a) to Fig 4 (c) in the hole part 311 and the part along the lower edge of the hole 312 formed in the outer edge and an inner annular edge area of polar coordinates to Cartesian coordinates by the transformation of the outer edge of the radius of the curve is formed from the inner edge and the outer edge of the radius of the curves in Figure 5 (b) in Fig 4 (d) in the hole part 311 and the part along the lower edge of the hole 312 formed in the outer annular edge and an inner edge region by polar coordinates to rectangular forming an outer edge of the transformation of the coordinates and the radius of the curve from the inner edge and the outer edge of the radius of the curves in Figure 5 (c) in Fig 4 (e) in the hole part 311 and the part along the lower edge of the hole 312 formed in the outer annular region edge and the inner edge of the polar coordinates to Cartesian coordinates by the transformation of the outer edge of the radius of the curve is formed and the inner edge and the outer edge distance radius curves in Figure 5 (d) in Fig 4 (f) in the upper edge of the hole part 311 and the inner part hole 312 is formed along the outer edge of the annular region and the inner edge of the polar coordinates to Cartesian coordinates by the transformation of forming an outer edge and the inner edge of the curve radius of the outer edge distance radius curves in Figure 5 (e) in Fig 4 (g) of the the upper edge of the hole part 311 and the hole part 312 along the outer edge of the annular region and the inner edge by polar coordinates to rectangular coordinates, forming an outer edge of the transformation curve and the inner radius of the outer edge of the edge distance radius curves in Figure 5 (f ) Fig 4 (h) in the hole part 311 and the part along the lower edge of the hole 312 formed in the outer edge and an inner annular edge area of polar coordinates to Cartesian coordinates by the transformation of the outer edge of the radius of the curve is formed and the inner edge and the outer edge distance radius curves .
According to Fig. 5, with inner bore of part 31 in camera image the annular region outward flange and inward flange by polar coordinates to the spatial alternation algorithm of rectangular coordinates transformation, the step that forms outward flange radius curve and inward flange and outward flange distance radius curve provides as follows:
Step 3a: the outer peripheral geometric center of annular region that forms in camera image take inner bore of part is as initial point, sets up the polar coordinate system on the edge image plane at annular region place; For the inner bore of part 31 of circle, this step should be: form greatest circle in annular region inward flange and the outward flange image (perhaps oval) according to the inner bore of part with circle in camera image, calculate its geometric center o; Take o as initial point, the polar coordinate system that an optional direction is set up as the x direction of polar coordinate system on the edge image plane at annular region place, if inner bore of part is shaped as square or triangle, then the calculating of annular region geometric center o should be the outer peripheral geometric center of annular region, i.e. maximum square or leg-of-mutton geometric center in the image at annular region place;
Step 3b: take polar x axle as axis of reference, intersect from the vector of polar coordinate system initial point and annular region, and should vector and annular region inward flange and outward flange meet at 2 points; For the inner bore of part 31 of circle, this step should be: take polar x axle as axis of reference, intersect from the vectorial ow of polar coordinate system initial point o and annular region, and vectorial ow and annular region inward flange and outward flange meet at 2 points, focus is respectively A, B.Order
d=|AB|,r=|oB|;
Step 3c: represent the anglec of rotation from ox to ow can make up following funtcional relationship with θ:
d=f(θ),r=g(θ) (5)
Wherein, r is for being the outward flange radius curve, its physical meaning is the distance of polar coordinates initial point o and vectorial ow and outward flange intersection point, and d is inward flange and outward flange distance radius curve, and its physical meaning is the distance of polar coordinates initial point o and vectorial ow and inward flange and outward flange intersection point;
Step 3d: be that the vector of starting point and polar coordinates x axle angle theta are since 0 with initial point in the polar coordinate system, take step-length as 0.01, be increased to 2 π, according to above-mentioned funtcional relationship, calculate corresponding d (θ) and r (θ), construct outward flange radius curve r (θ) and inward flange and the outward flange distance radius curve d (θ) of discrete type, be the curve among Fig. 5.
When inner bore of part is shaped as square or during triangle, still can use above-mentioned polar coordinates to the spatial alternation algorithm of rectangular coordinates transformation with annular region outward flange and inward flange that inner bore of part 31 forms in camera image, be for conversion into outward flange radius curve and inward flange and outward flange distance radius curve.By using polar coordinates to the spatial alternation algorithm of rectangular coordinate to annular region outward flange and inward flange, the specificity analysis problem that becomes outward flange radius curve r (θ) and inward flange and outward flange distance radius curve d (θ) is simplified in the inward flange and the problem analysis of outward flange offsets that inner bore of part 31 are formed annular region in camera image.
The below is according to outward flange radius curve r (θ) and inward flange and outward flange distance radius curve d (θ), by the geometric transformation algorithm based on projective theorem, carry out the calculating of actual parts interior hole site skew and angular deflection error, the aligning adjustment of carrying out camera and inner bore of part according to position offset error and the angular deflection error of the inner bore of part that calculates, to proofread and correct inner bore of part 31 offset errors, estimation of error and aligning set-up procedure are as follows:
Step 4a: the pattern curve of r (θ) is made comparisons during with the true form curve of r (θ) and non-angular deviation, have on the pattern curve of r (θ) when obtaining the true form curve of r (θ) and bias free equal value the some correspondence be θ, it is outer peripheral without deformation direction to be in the inner bore of part image annular region, again according to the true form curve of r (θ) perpendicular to annular region outer peripheral without the direction of deformation direction on the deformation extent of the pattern curve of r (θ) during with respect to the non-angular deviation, calculate the deformation ratio of annular region outer edge; For the inner bore of part 31 of circle, this step should be: according on the same ellipse any 5 can this ellipse of reconstruct (because the equation of arbitrary ellipse is on the plane:
Contain a, b, x
0, y
0, these 5 parameters of θ), on this curve of r (θ), the school select equably 25 points (such as
K=0,1,2 ..., 25 points are got at 24 places), then 5 ellipses of reconstruct make up a more accurately elliptic curve to these 5 ellipses by average mode, calculate elliptical center position O, transverse a and ellipse short shaft b;
Step 4b: according to the geometric projection relation of camera imaging, utilize annular region outer peripheral without deformation direction angle θ, calculate the angular deviation direction of inner bore of part
Utilize the outer peripheral deformation ratio of annular region, calculate the angular deflection error alpha of inner bore of part; For the inner bore of
part 31 of circle, this step should be: according to the ratio of transverse a and ellipse short shaft b, estimate the angle [alpha] (according to a=max r, b=maxrcos α) of inner bore of
part 31 deflections.According to the deflection of ellipse in camera image, can estimate the angular deviation direction of inner bore of
part 31
That is: the outward flange of the
annular region 221 that forms in camera image of inner bore of
part 31 exists
The angular error that has α on the direction;
Step 4c: obtain the central point O of outward flange and inward flange and the position of O ' according to r (θ) and r (θ)-d (θ), and according to the position of central point O and inner bore of part in the angular deviation direction
On when having the angular error of α, calculate the rotation error that only there is the α angle in inner bore of part not during the offset error of location, the position O of little elliptical center in the inner bore of part image "; Inner bore of
part 31 for circle, this step should be: adopt identical method among the step a according to r (θ)-d (θ), obtain the annular region inward flange, be complete little ellipse or the little elliptic arc of part, determine the position O ' of center in camera image of little ellipse; Exist according to O point position and inner bore of
part 31
When having the angular error of α on the direction, when calculating inner bore of
part 31 only exists rotation error not have translation error, annular region inward flange (inner bore of part is) the position O of center in camera image ";
Step 4d: according to O ' and O " relative position relation and distance poor, determine the offset direction, position of inner bore of
part 31
With
Position offset error Δ D on the direction;
Step 4e: according to the offset direction, position
With
Position offset error Δ D on the direction, angular deviation direction
With
Have α on the direction, with six shaft mechanical arms the
6th shaft end 111, first to-
Direction translation Δ D, again edge
The direction rotation angle [alpha];
So far, the first-order error trimming process is finished.Afterwards, continue repeating step S2 to the process of step S4, until the Δ D that calculates and α be within the error allowed band, that is: Δ D<ε
1, α<ε
2(ε
1, ε
2Require the error criterion of formulation according to different assembly precisions).
When inner bore of part is shaped as square or during triangle, need to step 4a, step 4b and the step 4c of above-mentioned geometric transformation algorithm based on projective theorem be made amendment, calculate inner bore of part position offset error and angular deflection error to get outward flange radius curve r (θ) that the geometric transformation algorithm can form according to square inner bore of part and leg-of-mutton inner bore of part and inward flange and outward flange distance radius curve d (θ) based on the photography theorem.
For square (perhaps leg-of-mutton) inner bore of part, the step 4a of above-mentioned image processing algorithm, step 4b and step 4c are revised as:
Step 4a: the pattern curve (being obtained by the spatial alternation algorithm of polar coordinate system to rectangular coordinate system by the square or triangle similar to the inner bore of part shape) of r (θ) is made comparisons during with the non-angular deviation with the true form curve of r (θ), have on the pattern curve of r (θ) when obtaining the true form curve of r (θ) and bias free equal value the some correspondence be θ, it is outer peripheral without deformation direction to be in the inner bore of part image annular region, again according to the true form curve of r (θ) perpendicular to annular region outer peripheral without the direction of deformation direction on the deformation extent of the pattern curve of r (θ) during with respect to the non-angular deviation, calculate the outer peripheral deformation ratio of annular region in the camera image;
Step 4b: according to the geometric projection relation of camera imaging, utilize annular region outer peripheral without deformation direction angle θ, calculate the angular deviation direction of inner bore of part
Utilize the outer peripheral deformation ratio of annular region, calculate the angular deflection error alpha of inner bore of part;
Step 4c: obtain annular region outward flange and the central point O of inward flange and the position of O ' square or that the triangle inner bore of part forms according to r (θ) and r (θ)-d (θ) in camera image, and according to the position of central point O and inner bore of part in angular deviation
When having the angular error of α on the direction, calculate the rotation error that only there is the α angle in inner bore of part not during the offset error of location, the position O of little elliptical center in the inner bore of part image ".
The above; only be the embodiment among the present invention; but protection scope of the present invention is not limited to this; anyly be familiar with the people of this technology in the disclosed technical scope of the present invention; can understand conversion or the replacement expected; all should be encompassed in of the present invention comprising within the scope, therefore, protection scope of the present invention should be as the criterion with the protection domain of claims.