A laser radar calibration method and system
By constructing a data acquisition and error calculation model, combining natural scene plane calibration fitting, and dynamically correcting the lidar parameters, the cumbersome lidar calibration process and low-cost sensor error problems are solved, and efficient and accurate lidar calibration and point cloud quality improvement are achieved.
Patent Information
- Application Number
- CN202510823539.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-08-29
- Estimated Expiration
- 2045-06-19
AI Technical Summary
The existing lidar calibration methods require specific scenarios and are difficult to adapt to dynamic scenarios. The calibration process is cumbersome and the accuracy is affected by human factors. The mechanical deviation and ranging error of low-cost lidar have not been effectively solved.
By constructing a data acquisition model, a three-dimensional coordinate transformation model, a fitting error calculation model and a parameter calibration model, the planes in natural scenes are used to obtain the measurement original data, combined with the calibration fitting plane to calculate the overall error, dynamically correct the lidar parameters, and using a step-by-step search strategy and a singular value decomposition algorithm to optimize parameters.
It realizes efficient and accurate lidar parameter calibration in dynamic scenarios, avoids point cloud feature omissions, improves point cloud quality and measurement performance, and significantly shortens calibration time.
Smart Images

Figure CN120334886B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a laser radar calibration method and system, and belongs to the technical field of laser radar calibration. Background Art
[0002] A Chinese patent application (publication number: CN115144839A) discloses a 3D laser radar comprising a vertical scanning unit and a horizontal rotation device. The vertical scanning unit comprises a laser emitter for emitting laser pulse signals and a non-uniformly rotating reflector. The laser emitter is located on the reflector's axis of rotation. The reflector rotates at a uniform or non-uniform speed to scan the external environment and control the spatial distribution of the scanned point cloud. The invention achieves uniform or non-uniform scanning of the vertical plane by the laser emitter through the uniform or non-uniform rotation of the reflector, and the horizontal rotation device drives the uniform or non-uniform rotation of the vertical scanning unit, thereby controlling the spatial distribution of the scanned point cloud.
[0003] Furthermore, as a core sensor in fields such as autonomous driving and robot navigation, the precise calibration of LiDAR's internal parameters directly affects the point cloud quality and system performance. However, the above scheme does not disclose how to calibrate the LiDAR. If the traditional specific scene calibration method is used for calibration, it is necessary to use calibration targets such as checkerboards and reflective plates. Therefore, the environment of the calibration scene is very demanding and it is difficult to adapt to the calibration of dynamic scenes. As a result, the calibration process is cumbersome, the calibration time is long, and the accuracy is affected by human factors. For example, it is easy to miss features when manually extracting the point cloud information of the calibration plate.
[0004] The information disclosed in this Background Art is only for understanding the background of the present inventive concept and therefore it may include information that does not constitute prior art. Summary of the Invention
[0005] In response to the above problem or one of the above problems, the first purpose of the present invention is to provide a calibration method and system for a laser radar. After continuous exploration and experimentation, the present invention constructs a data acquisition model, a three-dimensional coordinate transformation model, a fitting error calculation model and a parameter calibration model. Therefore, no specific scene is required. The plane in the natural scene (such as a wall) can be used to obtain the original measurement data, and the overall error can be calculated in combination with the calibrated fitting plane, and then the parameters are adjusted according to the overall error to achieve parameter calibration. The calibration process is simple, time-saving, labor-saving and highly accurate, thereby effectively avoiding missing point cloud features, and can be applied to the calibration of dynamic scenes, thereby effectively improving the point cloud quality and measurement performance of the laser radar.
[0006] In response to the above problem or one of the above problems, the second object of the present invention is to provide a laser radar calibration method and system, fully considering the mechanical deviation and ranging error of low-cost laser radar, designing a calibration process suitable for low-cost laser radar, and dynamically correcting the laser radar parameters through the distance scale factor, thereby effectively solving the calibration problem of low-cost sensors.
[0007] To achieve one of the above purposes, the first technical solution of the present invention is:
[0008] A laser radar calibration method comprises the following steps:
[0009] Step 1: Obtain the raw measurement data of a certain laser radar through a pre-built data acquisition model;
[0010] Step 2: Using the pre-built three-dimensional coordinate transformation model, based on the correspondence between the measurement points and the spatial coordinate system, the measurement raw data is transformed into spatial coordinates to obtain the coordinates of several three-dimensional points in the lidar coordinate system;
[0011] Step 3: Using a pre-built fitting error calculation model, calculate the distance between the three-dimensional coordinate point and the calibrated fitting plane, and based on the distance value, determine the overall error value between the three-dimensional coordinate point and the calibrated fitting plane;
[0012] Step 4: Use the pre-built parameter calibration model to adjust one or more parameters of the lidar according to the overall error value to obtain parameter calibration information.
[0013] After continuous exploration and experimentation, the present invention constructs a data acquisition model, a three-dimensional coordinate transformation model, a fitting error calculation model and a parameter calibration model. Without the need for a specific scene, the present invention can use planes in natural scenes (such as walls) to obtain raw measurement data, and calculate the overall error in combination with the calibrated fitting plane, and then adjust the parameters according to the overall error to achieve parameter calibration. The calibration process is simple, time-saving and labor-saving, and has high precision, which can effectively avoid missing point cloud features, and can be applied to the calibration of dynamic scenes, thereby effectively improving the point cloud quality and measurement performance of the lidar.
[0014] Furthermore, the present invention fully considers the mechanical deviation and ranging error of low-cost lidar, designs a calibration process suitable for low-cost lidar, and dynamically corrects the lidar parameters through the distance scale factor, effectively solving the calibration problem of low-cost sensors.
[0015] As preferred technical measures:
[0016] Step 1: Using the pre-built data acquisition model, the method for obtaining the raw measurement data of a certain laser radar is as follows:
[0017] Obtain the coordinate system information of a certain laser radar, which includes at least the positive half axis of the Y axis, the negative half axis of the Y axis, and the positive half axis of the Z axis;
[0018] According to the coordinate system information and the natural scene information, three measurement planes are selected, including a first measurement plane perpendicular to the positive half axis of the Y axis, a second measurement plane perpendicular to the negative half axis of the Y axis, and a third measurement plane perpendicular to the positive half axis of the Z axis;
[0019] The designed parameter values of the laser radar are used as the initial parameter values and input into the hardware of the laser radar to obtain the initially calibrated laser radar;
[0020] Then, the initially calibrated laser radar is used to measure the first measurement plane, the second measurement plane, and the third measurement plane respectively to obtain raw measurement data.
[0021] The measuring plane is a wall surface, a roof surface, a cabinet surface, or other relatively flat surfaces.
[0022] As preferred technical measures:
[0023] Step 2: Using the pre-built 3D coordinate transformation model, based on the correspondence between the measurement points and the spatial coordinate system, the original measurement data is transformed into spatial coordinates to obtain the coordinates of several 3D points in the LiDAR coordinate system. The method is as follows:
[0024] Based on the measurement raw data, one or more measurement space points are obtained;
[0025] Construct a multi-dimensional coordinate system based on the correspondence between the measurement points and the spatial coordinate system;
[0026] Based on the multidimensional coordinate system, the measurement space point is rotated around the Z axis by a first angle to obtain a first coordinate point after rotation;
[0027] The first coordinate point is rotated around the X axis by a second angle to obtain the second coordinate point;
[0028] The second coordinate point is rotated around the Y axis by a third angle to obtain the third coordinate point;
[0029] For the third coordinate point, add the first translation amount to obtain the fourth coordinate point;
[0030] Then the fourth coordinate point is rotated around the Z axis by an angle and the second translation amount is added to obtain the fifth coordinate point;
[0031] The fifth coordinate point is used as the three-dimensional space coordinate point of the laser measurement value;
[0032] Summarize several three-dimensional space coordinate points to obtain several three-dimensional point coordinate points in the lidar coordinate system.
[0033] As preferred technical measures:
[0034] According to the correspondence between the measurement points and the spatial coordinate system, the method of constructing the multidimensional coordinate system is as follows:
[0035] Obtain the structural data of a certain laser radar, including the laser radar lower plate information, laser radar upper plate information, high-speed rotor information, laser transmitting tube information, speed information and degree of freedom information;
[0036] The rotation speed information includes the low-speed rotation information of the lidar upper plate relative to the lidar lower plate and the high-speed rotation information of the high-speed rotor relative to the lidar upper plate. The degree of freedom information is 2 active degrees of freedom.
[0037] Determine the posture transformation information based on the structural data, including the posture transformation information from the lidar lower plate to the lidar upper plate, the posture transformation information from the lidar upper plate to the high-speed rotor, and the posture transformation information from the high-speed rotor to the laser transmitting tube;
[0038] Based on the pose transformation information, the coordinate systems of each part of the lidar are set, including the lidar lower plate coordinate system {L}, the lidar upper plate coordinate system {U}, the high-speed rotor coordinate system {A}, and the laser transmitting tube coordinate system {B}.
[0039] As preferred technical measures:
[0040] The origin of the LiDAR lower plate coordinate system {L} is located at the geometric center of the LiDAR lower plate base mounting plane. The positive half axis of its X-axis is opposite to the direction of the bottom cable outlet, its Z-axis coincides with the low-speed rotation axis, and its Y-axis is obtained from the right-hand coordinate system.
[0041] The upper plate coordinate system {U} of the lidar is obtained by translating and rotating the lower plate coordinate system {L} of the lidar;
[0042] The high-speed rotor coordinate system {A} is obtained by translating and rotating the laser radar upper plate coordinate system {U};
[0043] The laser emitting tube coordinate system {B} is obtained by rotating the high-speed rotor coordinate system {A}; the laser direction of the laser emitting tube is consistent with the positive half-axis direction of the Y axis of the laser emitting tube coordinate system {B}.
[0044] As preferred technical measures:
[0045] The first angle represents the structural error value of the laser emitting tube around the Z axis, and its expected mean value is equal to 0;
[0046] The second angle represents the sum of the rotation angle value of the upper motor and the starting angle deviation value of the upper motor shaft;
[0047] The third angle represents the structural error value of the upper motor shaft around the Y axis, and its expected mean is equal to 0;
[0048] The first translation represents the translation from the laser radar lower plate coordinate system {L} to the laser radar upper plate coordinate system {U};
[0049] The second translation amount represents the translation amount from the laser radar upper plate coordinate system {U} to the laser transmitting tube coordinate system {B};
[0050] The rotation angle indicates the rotation angle of the lower motor, and its value is directly read by the encoder.
[0051] As preferred technical measures:
[0052] Step 3: Use the pre-built fitting error calculation model to calculate the distance between the three-dimensional coordinate point and the calibrated fitting plane. Based on the distance value, determine the overall error value between several three-dimensional coordinate points and the calibrated fitting plane as follows:
[0053] Get the coordinates of several three-dimensional points in the laser radar coordinate system;
[0054] According to the positions of the first measurement plane, the second measurement plane, and the third measurement plane in the three-dimensional space, corresponding calibration fitting planes are respectively constructed, which include a first calibration fitting plane perpendicular to the positive half axis of the Y axis, a second calibration fitting plane perpendicular to the negative half axis of the Y axis, and a third calibration fitting plane perpendicular to the positive half axis of the Z axis;
[0055] Calculate the distance between each 3D point coordinate and each calibration fitting plane to obtain several distance values;
[0056] Classify several distance values and calculate the average distance of all 3D points to each calibration fitting plane to obtain three average distance values;
[0057] The three average distance values are used as the error values of the corresponding calibration fitting plane, and the average is calculated to obtain the overall error value.
[0058] As preferred technical measures:
[0059] According to the position of the first measurement plane in the three-dimensional space, the method for constructing the corresponding calibration fitting plane is as follows:
[0060] Setting a plane normal vector and an intercept based on a position of the first measurement plane in three-dimensional space, and establishing a plane equation for fitting the first measurement plane based on an arbitrary point on the first measurement plane;
[0061] Combine the plane normal vector and the intercept into a four-dimensional vector, rewrite the plane equation, and obtain the initial plane parameters in the form of a four-dimensional vector;
[0062] Based on the initial plane parameters, an initial calibration fitting plane is established;
[0063] For any three-dimensional coordinate point, add a 1 at the end to convert it into a four-dimensional homogeneous coordinate to obtain a four-dimensional coordinate point;
[0064] Calculate the geometric distance between the four-dimensional coordinate point and the initial calibration fitting plane to obtain several geometric distances;
[0065] According to several geometric distances, the optimal plane parameters are solved to minimize the average square distance from all four-dimensional coordinate points to the calibration fitting plane;
[0066] According to the optimal plane parameters, the corresponding calibration fitting plane is constructed.
[0067] As preferred technical measures:
[0068] Step 4: Use the pre-built parameter calibration model to adjust one or more parameters of the lidar based on the overall error value. The method for obtaining parameter calibration information is as follows:
[0069] Step 41, performing dynamic binary search calibration on the calibration parameters according to the overall error value, thereby obtaining new calibration parameters;
[0070] Step 42 , then write the new calibration parameter results into the lidar hardware, cache a new set of lidar measurement values, and use this set of data to calibrate the starting angle deviation of the upper motor to obtain a new starting angle deviation;
[0071] According to the new starting angle deviation, the structural error value of the upper motor is calibrated to obtain a new structural error value of the upper motor;
[0072] Based on the new structural error value of the upper motor, the structural error value of the laser emitting tube is calibrated to obtain a new structural error value of the laser emitting tube;
[0073] According to the new structural error value of the laser emitting tube, the ranging deviation is calibrated to obtain a new ranging deviation;
[0074] Step 43: Summarize the new starting angle deviation, the structural error value of the upper motor, the structural error value of the laser transmitting tube, and the ranging deviation to obtain new calibration parameters, and calculate a new overall error value based on the new calibration parameters;
[0075] In step 44, the new overall error value is judged. When the new overall error value is less than the given calibration threshold, the calibration is deemed to be successfully completed, and the new calibration parameters are used as the final parameter calibration information; otherwise, steps 41 to 44 are executed.
[0076] This method drives parameter search through plane fitting errors, eliminating the need for manual intervention or specific calibration objects. Utilizing vertical planes in natural scenes (such as walls) as constraints, parameter calibration is achieved through multi-plane joint optimization. Furthermore, the method decouples key parameters into independent optimization modules and employs a step-by-step search strategy. By setting initial Gaussian distribution values and using a dynamic bisection method, the search range can be narrowed, inter-parameter coupling interference can be avoided, and convergence speed can be improved. The calibration speed is significantly superior to traditional calibration methods.
[0077] To achieve one of the above purposes, the second technical solution of the present invention is:
[0078] A laser radar calibration system, comprising:
[0079] one or more processors;
[0080] a storage device for storing one or more programs;
[0081] When the one or more programs are executed by the one or more processors, the one or more processors implement the above-mentioned laser radar calibration method.
[0082] Compared with the existing technical solutions, the present invention has the following beneficial effects:
[0083] After continuous exploration and experimentation, the present invention constructs a data acquisition model, a three-dimensional coordinate transformation model, a fitting error calculation model and a parameter calibration model. Without the need for a specific scene, the present invention can use planes in natural scenes (such as walls) to obtain raw measurement data, and calculate the overall error in combination with the calibrated fitting plane, and then adjust the parameters according to the overall error to achieve parameter calibration. The calibration process is simple, time-saving and labor-saving, and has high precision, which can effectively avoid missing point cloud features, and can be applied to the calibration of dynamic scenes, thereby effectively improving the point cloud quality and measurement performance of the lidar.
[0084] Furthermore, the present invention fully considers the mechanical deviation and ranging error of low-cost lidar, designs a calibration process suitable for low-cost lidar, and dynamically corrects the lidar parameters through the distance scale factor, effectively solving the calibration problem of low-cost sensors. BRIEF DESCRIPTION OF THE DRAWINGS
[0085] Figure 1 A schematic flow chart of a laser radar calibration method according to the present invention;
[0086] Figure 2 A schematic diagram of a process for calibrating a laser radar according to the present invention;
[0087] Figure 3 A schematic diagram of a coordinate system constructed for a laser radar according to the present invention;
[0088] Figure 4 A schematic diagram of constructing a calibration fitting plane for the present invention;
[0089] Figure 5 This is the first schematic diagram of the point cloud effect before calibration of a certain laser radar;
[0090] Figure 6 This is the second schematic diagram of the point cloud effect before calibration of a certain laser radar;
[0091] Figure 7 This is the third schematic diagram of the point cloud effect before calibration of a certain laser radar;
[0092] Figure 8 This is the first schematic diagram of the point cloud effect after a certain laser radar calibration;
[0093] Figure 9 This is the second schematic diagram of the point cloud effect after a certain laser radar calibration;
[0094] Figure 10 This is the third schematic diagram of the point cloud effect after a certain laser radar calibration.
[0095] Description of reference numerals:
[0096] 1. Low-speed shaft; 2. High-speed rotor; 3. High-speed shaft; 4. LiDAR upper plate; 5. LiDAR lower plate; 6. Laser transmitting tube. DETAILED DESCRIPTION
[0097] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0098] Rather, the present invention encompasses any alternatives, modifications, equivalents, and solutions that fall within the spirit and scope of the present invention as defined by the claims. Furthermore, to facilitate a better understanding of the present invention, certain specific details are described in detail below in the detailed description of the present invention. Those skilled in the art will be able to fully understand the present invention without these details.
[0099] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one skilled in the art to which this invention pertains. The terms used herein are for the purpose of describing specific embodiments only and are not intended to limit the present invention. As used herein, the term "or / and" includes any and all combinations of one or more of the associated listed items.
[0100] like Figure 1As shown, a specific embodiment of the laser radar calibration method of the present invention is as follows:
[0101] A laser radar calibration method comprises the following steps:
[0102] Step 1: Obtain the raw measurement data of a certain laser radar through a pre-built data acquisition model;
[0103] Step 2: Using the pre-built three-dimensional coordinate transformation model, based on the correspondence between the measurement points and the spatial coordinate system, the measurement raw data is transformed into spatial coordinates to obtain the coordinates of several three-dimensional points in the lidar coordinate system;
[0104] Step 3: Using a pre-built fitting error calculation model, calculate the distance between the three-dimensional coordinate point and the calibrated fitting plane, and based on the distance value, determine the overall error value between the three-dimensional coordinate point and the calibrated fitting plane;
[0105] Step 4: Use the pre-built parameter calibration model to adjust one or more parameters of the lidar according to the overall error value to obtain parameter calibration information.
[0106] like Figure 2 As shown, a specific embodiment of applying the present invention to calibrate a dual-rotation axis laser radar:
[0107] The calibration method of the present invention is used to calibrate a dual-rotation axis laser radar, and the method is as follows:
[0108] Step 1: Set the four coordinate systems of the dual-rotation-axis lidar;
[0109] Step 2: Filter calibration parameters based on four coordinate systems;
[0110] Step 3: Obtain laser measurement values and perform coordinate transformation on the laser measurement values according to calibration parameters to obtain three-dimensional space coordinate points;
[0111] Step 4: Perform plane fitting and error calculation based on the three-dimensional space coordinate points to obtain error information;
[0112] Step 5: Based on the error information, perform dynamic binary search calibration on the calibration parameters to obtain new calibration parameters. Then, write the new calibration parameter results into the lidar hardware, and then execute steps 3 and 4 to obtain new error information.
[0113] Step 6: Determine the new calibration parameters based on the new error information. If the new calibration parameters do not meet the requirements, execute step 5. If the new calibration parameters meet the requirements, determine the final calibration parameters.
[0114] The present invention can quickly calibrate the internal parameters of a dual-rotation-axis laser radar. Compared with traditional manual calibration methods, the present invention has the advantages of fast calibration speed, high point cloud accuracy, and good consistency.
[0115] like Figure 3 As shown, in this embodiment, step 1, the method for setting the four coordinate systems of the dual-rotation axis laser radar is as follows:
[0116] The dual-rotation axis laser radar is a 3D laser radar with the announcement number CN115144839A; the 3D laser radar is composed of, from bottom to top: a laser radar lower plate 5, a laser radar upper plate 4, a high-speed rotor 2, and a laser transmitting tube 6, wherein the laser radar upper plate 4 rotates at a low speed relative to the laser radar lower plate 5, and the high-speed rotor 2 rotates at a high speed relative to the laser radar upper plate 4. The entire mechanical structure contains two active degrees of freedom.
[0117] Assuming that during the rotation of the laser radar, each rotating part is a rigid body and the rotation axis remains fixed and unchanged. To convert the laser ranging value emitted by the laser transmitter into three-dimensional spatial point coordinates in the lower plate coordinate system, the present invention requires calibration of the pose transformation parameters including the pose transformation from the lower plate to the upper plate, the pose transformation from the upper plate to the high-speed rotor, and the pose transformation from the high-speed rotor to the laser transmitter.
[0118] To facilitate calibration, the present invention defines the coordinate system of each part of the laser radar as follows, which satisfies the definition of the right-hand coordinate system, specifically including the following:
[0119] First, define the laser radar lower plate coordinate system {L}. Its origin is located at the geometric center of the laser radar lower plate base installation plane. Its X-axis is opposite to the bottom cable outlet direction, its Z-axis coincides with the low-speed shaft 1, and its Y-axis is obtained from the right-hand coordinate system.
[0120] Then, define the upper plate coordinate system {U} of the laser radar, which is translated upward along the Z axis by the lower plate coordinate system {L} of the laser radar , and then rotate around the Z axis Get, where the parameters is a fixed value determined by the hardware structure, angle is the rotation angle around the low-speed shaft 1.
[0121] Secondly, define the high-speed rotor coordinate system {A}, which is the distance translated along the X axis by the laser radar upper plate coordinate system {U} , and then rotate a small angle around the Y axis , and finally rotate around the x-axis by Get, where the parameters is a fixed value determined by the hardware structure, angle is the slight structural error value, angle is the rotation angle around the high-speed rotation axis 3.
[0122] Furthermore, the laser tube coordinate system {B} is defined, which is rotated by the high-speed rotor coordinate system {A} along its Z axis. The laser direction of the laser tube is consistent with the Y-axis direction of the laser tube coordinate system {B}, and the angle It is a small structural error value.
[0123] Finally, considering that the encoder installation positions of the upper and lower motors will not be strictly located at the zero angle position due to the installation position deviation, the present invention additionally provides the rotation angle of the lower motor. Add a deviation value , is the rotation angle of the upper motor Add a deviation value .
[0124] At the same time, the present invention constructs a posture transformation expression to express the posture transformation from coordinate system 1 to coordinate system 2, which is as follows:
[0125]
[0126] in, are the translation amounts, are the rotation Euler angles respectively.
[0127] The present invention can thus obtain:
[0128] Pose transformation from the lidar lower plate coordinate system {L} to the lidar upper plate coordinate system {U} for:
[0129]
[0130] Pose transformation from the lidar upper plate coordinate system {U} to the high-speed rotor coordinate system {A} for:
[0131]
[0132] Pose transformation from high-speed rotor coordinate system {A} to laser tube coordinate system {B} for:
[0133]
[0134] In this embodiment, in step 2, the method for screening calibration parameters based on the four coordinate systems is as follows:
[0135] In the above pose transformation, the parameters that do not need to be calibrated are as follows:
[0136] and These are the rotation angle values of the lower motor and the upper motor, which are directly read by the encoder and do not require calibration.
[0137] and It can be directly obtained from the design parameters of the mechanical structure, and its slight deviation has a negligible effect on the coordinate calculation of the laser point, so no calibration is required.
[0138] is the initial deviation angle of the encoder of the lower motor. It has no effect on the overall point cloud quality, so no calibration is required here.
[0139] The parameters that need to be calibrated are as follows:
[0140] is the starting angle deviation of the upper motor shaft, and its expected mean is equal to 0.
[0141] is the structural angle deviation of the upper motor shaft around the Y-axis, and its expected mean is equal to 0.
[0142] is the structural angle deviation of the laser emitting tube around the Z axis, and its expected mean is equal to 0.
[0143] In addition, considering the error of laser ranging itself, the original value of laser measurement is , the measured distance value is , the ranging error is , the distance scale factor is , then the distance measurement formula is as follows:
[0144]
[0145] Among them, the parameters that need to be calibrated include ranging deviation and distance scale factor Ranging deviation The mean of is equal to 0; the distance scale factor The mean of is equal to 1.
[0146] Furthermore, the present invention records all parameters that need to be calibrated as a vector, which is expressed as follows:
[0147]
[0148] In this embodiment, the method for obtaining laser measurement values and performing coordinate transformation on the laser measurement values according to calibration parameters to obtain three-dimensional space coordinate points is as follows:
[0149] The design value of the laser radar structure is used as the initial value and input into the laser radar hardware to obtain a measured distance in the laser transmitting tube coordinate system {B} For a measurement distance in the laser tube coordinate system {B} , let its corresponding space point be P, and its corresponding coordinates be . Let the coordinates of this point in the laser radar lower plate coordinate system {L} be , then the pose transformation relationship is calculated as follows:
[0150]
[0151] in, is the rotation matrix for a certain angle around the corresponding axis, 、 、 are the characteristic elements in the rotation matrix, From the coordinate system To coordinate system The amount of translation, From the coordinate system To coordinate system The amount of translation.
[0152] The step-by-step calculation of the above pose transformation is as follows:
[0153] Rotate point P around the Z axis by angle , get the first coordinate point after rotation, its coordinates are expressed as follows:
[0154]
[0155] Where c is the trigonometric function cosine, and s is the trigonometric function sin.
[0156] The first coordinate point is rotated around the X axis by an angle , get the second coordinate point, its coordinate expression is as follows:
[0157]
[0158] Rotate the second coordinate point around the Y axis. , get the third coordinate point, its coordinate expression is as follows:
[0159]
[0160] For the third coordinate point, increase the translation , get the fourth coordinate point, its coordinates are expressed as follows:
[0161]
[0162] Then, the variables in the coordinate formula are simplified to obtain the following expression:
[0163]
[0164] Finally, the fourth coordinate point is rotated around the Z axis by , and increase the translation , and get the fifth coordinate point, whose coordinates are expressed as follows:
[0165]
[0166] Finally, the fifth coordinate point is used as the three-dimensional space coordinate point of the laser measurement value , which is expressed as follows:
[0167]
[0168] In this embodiment, in step 4, plane fitting and error calculation are performed based on the three-dimensional space coordinate points to obtain error information as follows:
[0169] like Figure 4 As shown, the present invention uses three calibration fitting planes to calibrate the laser radar. The three planes are perpendicular to the positive half axis of the Y axis, the negative half axis of the Y axis and the positive half axis of the Z axis of the laser radar coordinate system, respectively called P1, P2 and P3.
[0170] According to the known current calibration parameters The present invention caches the raw LiDAR data for a period of time, and then uses the above-mentioned spatial coordinate conversion method and the current calibration parameters to convert these raw data into three-dimensional point coordinates in the LiDAR coordinate system, which is recorded as the set , the set contains a total of n points, namely:
[0171]
[0172] For a plane in three-dimensional space, let the plane normal vector be , the intercept is , any point on the plane is , then the plane equation is:
[0173]
[0174] Combining the plane normal vector and the intercept into a four-dimensional vector gives the plane parameters in the form of a four-dimensional vector: , which is expressed as follows:
[0175]
[0176] For a three-dimensional space point coordinate, adding a 1 at the end can change it to a four-dimensional homogeneous coordinate, and then the three-dimensional space point The expression is as follows:
[0177]
[0178] For a three-dimensional point in the point set X , the geometric distance from the point to the above plane for:
[0179]
[0180] In order to obtain the optimal plane parameters by fitting all points in the point set X, the plane parameters that minimize the average square distance from all points to the fitting plane can be solved. Therefore, the present invention only needs to solve the linear least squares solution of the following form :
[0181]
[0182] In order to facilitate the use of matrix solutions, all points in the point set X can be written in the same matrix. The expression is as follows:
[0183]
[0184] Then rewrite the least squares formula in the above summation form into the least squares formula in matrix form, which is expressed as follows:
[0185]
[0186] Perform singular value decomposition on the above matrix, and the calculation formula is as follows:
[0187]
[0188] in, is a singular value matrix, which is a diagonal matrix with diagonal elements arranged from large to small. U and V are both orthogonal matrices. The present invention takes the last column of matrix V This is the solution to the least squares formula, which is expressed as follows:
[0189]
[0190] Finally, the present invention calculates the average distance between all points in the statistical point set X and the fitting plane as the error value of the plane, which is expressed as follows:
[0191]
[0192] In order to ensure the consistency of all directions, the present invention counts the errors of three planes, including the error in the positive semi-axis direction of the Y axis of the laser radar coordinate system, the error in the negative semi-axis direction of the Y axis, and the error in the positive semi-axis direction of the Z axis. The present invention records the errors of these three planes as 、 and , and then take the average value as the overall error, which is calculated as follows:
[0193]
[0194] In this embodiment, in step 5, a dynamic binary search calibration is performed on the calibration parameters based on the error information to obtain new calibration parameters. The new calibration parameter results are then written to the lidar hardware, and steps 3 and 4 are then executed to obtain new error information. The method is as follows:
[0195] First, initialize all parameters to their initial values
[0196] Then, a set of raw radar data packets, including the LiDAR range values, motor angle values, and other measurement values, are cached and used for a round of calibration. In a round of calibration, the present invention decouples the parameters and performs dynamic binary search calibration in sequence. This simplifies the calibration process and avoids coupling between parameters. The calibration sequence is as follows:
[0197] The first step is to calibrate the starting angle deviation of the upper motor ;
[0198] The second step is to calibrate the pitch angle of the upper motor ;
[0199] The third step is to calibrate the angle deviation of the laser transmitter. ;
[0200] Step 4: Calibrate the ranging deviation ;
[0201] Step 5: Calibrate the measurement distance scale ;
[0202] Step 6: Check whether the current round of calibration is successful. If the calibration is successful or the maximum number of calibration rounds is exceeded, the calibration is terminated.
[0203] Finally, the calibration parameter results are written to the lidar hardware.
[0204] In this embodiment, the method of single-parameter dynamic binary search calibration is as follows:
[0205] Given a parameter to be calibrated, obtain the approximate mean and variance of its distribution. The mean is the theoretical value of the structural design, and the variance is the variance value caused by actual processing. Compared with the search range of calibration, the variance can be small enough to be ignored. Here, the starting angle deviation is used. As an example, the calibration satisfies the Gaussian distribution, and its expression is as follows:
[0206]
[0207] in, is the starting angle deviation The mean of is the Gaussian distribution function, is the starting angle deviation The variance of .
[0208] Standard deviation Mainly determined by the accuracy of processing and assembly, the present invention sets a sufficiently large boundary for it As the range of subsequent calibration search, in this embodiment, the maximum boundary The value of , and satisfy:
[0209]
[0210] For the starting angle deviation , the present invention will be As the initial value of its calibration, As its calibration search range.
[0211] Divide the search range into N equal parts, here we take , then the search step size for:
[0212]
[0213] During the search, the parameter is traversed from front to back in the current search range according to the step size to obtain the new calibration parameter; then the new calibration parameter result is written to the lidar hardware, and steps 3 and 4 are executed again to obtain the new error information, and then the optimal value is found. , which is calculated as follows:
[0214]
[0215] Adoption and calibration parameters Same method for the remaining parameters 、 and Perform automatic search to find the optimal value, that is, the parameter value with the smallest comprehensive error.
[0216] Finally, the distance scale parameters are calibrated, and the parameters of the two planes are fitted using the selected point sets of plane 1 and plane 2, respectively, and are set as and . Then calculate the distance between the two planes , which is calculated as follows:
[0217]
[0218] in, 、 is the parameter (intercept) of the plane equation.
[0219] The actual distance between plane 1 and plane 2 is known to be , then calculate the distance scale The relevant formula is as follows:
[0220]
[0221] In this embodiment, in step 6, the new calibration parameters are judged based on the new error information. If the requirements are not met, step 5 is executed. If the requirements are met, the method for determining the final calibration parameters is as follows:
[0222] At this point, all parameters have been updated, and the present invention will calculate the average error E of the three plane fittings. If the overall error is less than the given calibration threshold, the calibration is considered successful and the calibration is completed; otherwise, the next round of data collection and search calibration is carried out. The threshold set here is as follows:
[0223]
[0224]
[0225] In the next round of calibration, the present invention uses the optimal value of each parameter obtained in the previous round of calibration as the new mean value, and narrows the search range of the parameter by two, to obtain a new search mean value and range, which are expressed as follows:
[0226]
[0227] in, for The optimal value obtained after the previous round of calibration.
[0228] The same is true for other parameters. Here, the initial values and search ranges of all parameters are listed as follows:
[0229]
[0230] in, is the starting angle deviation The mean of the starting angle deviation The initial value of is the starting angle deviation The maximum value limit; The structural angle deviation of the upper motor shaft around the Y axis The mean of the structural angle deviation The initial value of Structural angle deviation The maximum value limit; The structural angle deviation of the laser emitting tube around the Z axis The mean value is also the structural angle deviation of the laser emitting tube around the Z axis The initial value of The structural angle deviation of the laser emitting tube around the Z axis The maximum value limit; The ranging deviation The mean of the distance measurement deviation The initial value of The ranging deviation The maximum value limit; is the distance scale factor The mean of The initial value of is the distance scale factor The maximum value limit.
[0231] In this embodiment, the data processing method is as follows:
[0232] The initial values of all parameters are set as follows: Among them, the search ranges of the first three parameters are , the search range of the fourth parameter rb is .
[0233] Divide the search range of the first parameter into 50 equal parts. Traverse the parameters, calculate the error value for each, and find the parameter value that minimizes the overall error. This value is used as the search result for this round.
[0234] The same method can be used to obtain the search results for the second, third, and fourth parameters. For example, the results for the first four parameters are .
[0235] The fifth parameter does not need to be searched and can be directly obtained by the distance scale parameter calibration method.
[0236] Finally, calculate the comprehensive error to determine whether the calibration can be terminated. If not, proceed to the next round of calibration.
[0237] For a comparison of the point cloud effects of a certain laser radar before and after calibration, please refer to Figure 5-10 ,in Figure 5 、 Figure 6 、 Figure 7 This is the effect picture before calibration. Figure 8 、 Figure 9 、 Figure 10 This is the effect picture after calibration. It can be seen that before calibration, the point cloud on the plane is uneven with bulges and stratification; after calibration, the plane point cloud becomes flat and the stratification disappears.
[0238] Therefore, the present invention drives parameter search through plane fitting errors, eliminating the need for manual intervention or specific calibration objects. Parameter calibration is achieved through multi-plane joint optimization, using vertical planes in natural scenes (such as walls) as constraints. Furthermore, the present invention decouples key parameters into independent optimization modules, employs a step-by-step search strategy, and narrows the search range by setting initial Gaussian distribution values and using dynamic bisection. This avoids inter-parameter coupling interference, improves convergence speed, and significantly outperforms traditional manual calibration.
[0239] Furthermore, the present invention designs a special calibration process to address the mechanical deviation and ranging error of low-cost lidar, and solves the nonlinear response problem of low-cost sensors through dynamic correction of the distance scale factor.
[0240] At the same time, this method uses the average plane fitting error E as the optimization target and combines it with the singular value decomposition (SVD) algorithm to achieve high-precision point cloud registration. By reducing the parameter search step size through multiple rounds of iteration, the final error can be controlled within 0.02m.
[0241] Experiments show that the single calibration success rate of the present invention is >95%, and the single calibration time is shortened by more than 70% compared with the traditional manual method.
[0242] An embodiment of a device applying the method of the present invention:
[0243] An electronic device comprising:
[0244] one or more processors;
[0245] a storage device for storing one or more programs;
[0246] When the one or more programs are executed by the one or more processors, the one or more processors implement the above-mentioned laser radar calibration method and system.
[0247] A computer medium embodiment of the method of the present invention:
[0248] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the above-mentioned laser radar calibration method and system.
[0249] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present application may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, optical storage, etc.) containing computer-usable program code.
[0250] The present application is described in terms of flowcharts or / and block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process or / and block in the flowchart or / and block diagram, as well as the combination of processes or / and blocks in the flowchart or / and block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0251] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0252] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0253] The model in this application is an object that objectively describes the morphological structure with the help of physical or virtual representation. The object is not equal to the physical body and is not limited to physical and virtual. It can be a data processing function, software program, processing mode, usage method, operation method, workflow, application process, electronic hardware, circuit module, processing system, system imitation or simulation object.
[0254] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the field can still modify or replace the specific implementation methods of the present invention. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be included in the scope of protection of the claims of the present invention.
Claims
1. A laser radar calibration method, characterized by: The following steps are involved: Step 1: Obtain the raw measurement data of a certain laser radar through a pre-built data acquisition model; Step 2: Using the pre-built three-dimensional coordinate transformation model, based on the correspondence between the measurement points and the spatial coordinate system, the measurement raw data is transformed into spatial coordinates to obtain the coordinates of several three-dimensional points in the lidar coordinate system; The method is as follows: Based on the measurement raw data, one or more measurement space points are obtained; Construct a multi-dimensional coordinate system based on the correspondence between the measurement points and the spatial coordinate system; Based on the multidimensional coordinate system, the measurement space point is rotated around the Z axis by a first angle to obtain a first coordinate point after rotation; The first coordinate point is rotated around the X axis by a second angle to obtain the second coordinate point; The second coordinate point is rotated around the Y axis by a third angle to obtain the third coordinate point; For the third coordinate point, add the first translation amount to obtain the fourth coordinate point; Then the fourth coordinate point is rotated around the Z axis by an angle and the second translation amount is added to obtain the fifth coordinate point; The fifth coordinate point is used as the three-dimensional space coordinate point of the laser measurement value; Summarize several three-dimensional space coordinate points to obtain several three-dimensional point coordinate points in the laser radar coordinate system; According to the correspondence between the measurement points and the spatial coordinate system, the method of constructing the multidimensional coordinate system is as follows: Obtain the structural data of a certain laser radar, including the laser radar lower plate information, laser radar upper plate information, high-speed rotor information, laser transmitting tube information, speed information and degree of freedom information; The rotation speed information includes the low-speed rotation information of the lidar upper plate relative to the lidar lower plate and the high-speed rotation information of the high-speed rotor relative to the lidar upper plate. The degree of freedom information is 2 active degrees of freedom. Determine the posture transformation information based on the structural data, including the posture transformation information from the lidar lower plate to the lidar upper plate, the posture transformation information from the lidar upper plate to the high-speed rotor, and the posture transformation information from the high-speed rotor to the laser transmitting tube; Based on the pose transformation information, the coordinate systems of various parts of the laser radar are set, including the laser radar lower plate coordinate system {L}, the laser radar upper plate coordinate system {U}, the high-speed rotor coordinate system {A} and the laser transmitting tube coordinate system {B}; Step 3: Using a pre-built fitting error calculation model, calculate the distance between the three-dimensional coordinate point and the calibrated fitting plane, and based on the distance value, determine the overall error value between the three-dimensional coordinate point and the calibrated fitting plane; Step 4: Use the pre-built parameter calibration model to adjust one or more parameters of the lidar according to the overall error value to obtain parameter calibration information.
2. The laser radar calibration method according to claim 1, wherein: Step 1: Using the pre-built data acquisition model, the method for obtaining the raw measurement data of a certain laser radar is as follows: Obtain the coordinate system information of a certain laser radar, which includes at least the positive half axis of the Y axis, the negative half axis of the Y axis, and the positive half axis of the Z axis; According to the coordinate system information and the natural scene information, three measurement planes are selected, including a first measurement plane perpendicular to the positive half axis of the Y axis, a second measurement plane perpendicular to the negative half axis of the Y axis, and a third measurement plane perpendicular to the positive half axis of the Z axis; The designed parameter values of the laser radar are used as the initial parameter values and input into the hardware of the laser radar to obtain the initially calibrated laser radar; Then, the initially calibrated laser radar is used to measure the first measurement plane, the second measurement plane, and the third measurement plane respectively to obtain raw measurement data.
3. The laser radar calibration method according to claim 1, wherein: The origin of the LiDAR lower plate coordinate system {L} is located at the geometric center of the LiDAR lower plate base mounting plane. The positive half axis of its X-axis is opposite to the direction of the bottom cable outlet, its Z-axis coincides with the low-speed rotation axis, and its Y-axis is obtained from the right-hand coordinate system. The upper plate coordinate system {U} of the lidar is obtained by translating and rotating the lower plate coordinate system {L} of the lidar; The high-speed rotor coordinate system {A} is obtained by translating and rotating the laser radar upper plate coordinate system {U}; The laser emitting tube coordinate system {B} is obtained by rotating the high-speed rotor coordinate system {A}; the laser direction of the laser emitting tube is consistent with the positive half-axis direction of the Y axis of the laser emitting tube coordinate system {B}.
4. The laser radar calibration method according to claim 3, wherein: The first angle represents the structural error value of the laser emitting tube around the Z axis, and its expected mean value is equal to 0; The second angle represents the sum of the rotation angle value of the upper motor and the starting angle deviation value of the upper motor shaft; The third angle represents the structural error value of the upper motor shaft around the Y axis, and its expected mean is equal to 0; The first translation represents the translation from the laser radar lower plate coordinate system {L} to the laser radar upper plate coordinate system {U}; The second translation amount represents the translation amount from the laser radar upper plate coordinate system {U} to the laser transmitting tube coordinate system {B}; The rotation angle indicates the rotation angle of the lower motor, which is directly read by the encoder.
5. The laser radar calibration method according to claim 1, wherein: Step 3: Use the pre-built fitting error calculation model to calculate the distance between the three-dimensional coordinate point and the calibrated fitting plane. Based on the distance value, determine the overall error value between several three-dimensional coordinate points and the calibrated fitting plane as follows: Get the coordinates of several three-dimensional points in the laser radar coordinate system; According to the positions of the first measurement plane, the second measurement plane, and the third measurement plane in the three-dimensional space, corresponding calibration fitting planes are respectively constructed, which include a first calibration fitting plane perpendicular to the positive half axis of the Y axis, a second calibration fitting plane perpendicular to the negative half axis of the Y axis, and a third calibration fitting plane perpendicular to the positive half axis of the Z axis; Calculate the distance between each 3D point coordinate and each calibration fitting plane to obtain several distance values; Classify several distance values and calculate the average distance of all 3D points to each calibration fitting plane to obtain three average distance values; The three average distance values are used as the error values of the corresponding calibration fitting plane, and the average is calculated to obtain the overall error value.
6. The laser radar calibration method according to claim 5, wherein: According to the position of the first measurement plane in the three-dimensional space, the method for constructing the corresponding calibration fitting plane is as follows: Setting a plane normal vector and an intercept based on a position of the first measurement plane in three-dimensional space, and establishing a plane equation for fitting the first measurement plane based on an arbitrary point on the first measurement plane; Combine the plane normal vector and the intercept into a four-dimensional vector, rewrite the plane equation, and obtain the initial plane parameters in the form of a four-dimensional vector; Based on the initial plane parameters, an initial calibration fitting plane is established; For any three-dimensional coordinate point, add a 1 at the end to convert it into a four-dimensional homogeneous coordinate to obtain a four-dimensional coordinate point; Calculate the geometric distance between the four-dimensional coordinate point and the initial calibration fitting plane to obtain several geometric distances; According to several geometric distances, the optimal plane parameters are solved to minimize the average square distance from all four-dimensional coordinate points to the calibration fitting plane; According to the optimal plane parameters, the corresponding calibration fitting plane is constructed.
7. The laser radar calibration method according to claim 1, wherein: Step 4: Use the pre-built parameter calibration model to adjust one or more parameters of the lidar based on the overall error value. The method for obtaining parameter calibration information is as follows: Step 41, performing dynamic binary search calibration on the calibration parameters according to the overall error value, thereby obtaining new calibration parameters; Step 42 , then write the new calibration parameter results into the lidar hardware, cache a new set of lidar measurement values, and use this set of data to calibrate the starting angle deviation of the upper motor to obtain a new starting angle deviation; According to the new starting angle deviation, the structural error value of the upper motor is calibrated to obtain a new structural error value of the upper motor; Based on the new structural error value of the upper motor, the structural error value of the laser emitting tube is calibrated to obtain a new structural error value of the laser emitting tube; According to the new structural error value of the laser emitting tube, the ranging deviation is calibrated to obtain a new ranging deviation; Step 43: Summarize the new starting angle deviation, the structural error value of the upper motor, the structural error value of the laser transmitting tube, and the ranging deviation to obtain new calibration parameters, and calculate a new overall error value based on the new calibration parameters; Step 44: judge the new overall error value. When the new overall error value is less than a given calibration threshold, the calibration is deemed to be successful and the new calibration parameters are used as the final parameter calibration information. Otherwise, execute steps 41 to 44.
8. A laser radar calibration system, characterized by: It includes: one or more processors; a storage device for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement a laser radar calibration method as described in any one of claims 1 to 7.
Citation Information
Patent Citations
3D laser radar and foot type robot and cleaning robot applying 3D laser radar
CN115144839A
Laser radar parameter calibration method and device
CN113466834A