Robot sensor calibration method, robot and computer readable storage medium
By using point cloud data of feature planes and calibrators on the robot, calculating and compensating sensor deviations, the high cost and inefficiency problems in the lack of calibration spaces for robot sensor calibration is solved, and more efficient and accurate sensor correction is achieved.
Patent Information
- Application Number
- CN202210342734.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-31
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-03-31
AI Technical Summary
In the prior art, the correction of robot sensors needs to be carried out in the calibration space, resulting in high cost and low efficiency in use scenarios where calibration space is lacking.
By controlling the robot to a position with a feature plane, point cloud data is obtained using the feature plane and a calibrator with preset features, the deviation value of the sensor and the standard position is calculated, and compensation is performed to complete the correction of the sensor.
This method can improve the accuracy of the sensor, reduce correction costs, simplify the calibration process, and improve calibration efficiency without returning to the factory calibration.
Smart Images

Figure CN114663532B_ABST
Abstract
Description
Technical Field
[0001] The present invention generally relates to the technical field of intelligent devices, and in particular to a sensor calibration method, a robot and a computer-readable storage medium. Background Art
[0002] A robot is a machine device with an intelligent control system that can automatically perform tasks. The robot can undertake some of the manual labor in traditional industries, such as handling and distribution, mechanical processing, environmental disinfection, publicity and guidance, and many other aspects. In order to ensure the normal movement and accurate positioning of the robot, sensors such as visual sensors and laser radars need to be installed on the robot to scan the robot's surrounding environment and identify positioning information. They are important components of the robot. The sensor is fixedly installed on the robot and its relative position relationship with the robot is fixed. However, due to the limitations of the processing technology and installation technology, the sensor cannot be accurately installed in the standard position, resulting in deviations in the position relationship between the robot and the surrounding environment or positioning marks, affecting the normal operation of the robot. Therefore, the sensor installed on the robot needs to be calibrated and corrected. The existing calibration and correction method requires the robot to be fixed inside the calibration space and calibrated based on the specific environment in the calibration space. However, there is usually no calibration space in the robot's usage scenario. When calibration and correction are required, the robot needs to be returned to the factory for calibration, which is costly, inefficient, and inconvenient to use.
[0003] The contents of the background technology section are merely the technologies known to the inventors and do not necessarily represent the prior art in the field. Summary of the invention
[0004] In view of one or more deficiencies in the prior art, the present invention provides a robot sensor calibration method, comprising:
[0005] Control the robot to move to a position with a characteristic plane, in which a calibration object with preset characteristics is fixed, control the sensor to scan the characteristic plane and the calibration object, and obtain point cloud data of the characteristic plane and the calibration object;
[0006] Arbitrarily selecting at least two positions of the feature plane that are independent of each other and not on the preset straight line as reference positions, and obtaining point cloud data of the reference positions from the point cloud corresponding to the feature plane;
[0007] Calculate the deviation value of the sensor from the standard position according to the reference position and the point cloud data of the calibration object, wherein the deviation value includes the distance deviation of the sensor in the plane parallel to the characteristic plane;
[0008] According to the deviation value between the sensor and the standard position, the scanning error caused by the sensor deviating from the standard position is compensated to complete the calibration of the sensor. The standard position is the theoretical installation position of the sensor on the robot.
[0009] According to one aspect of the present invention, the characteristic plane is a horizontal plane, or any physical plane whose distance and direction to the standard position of the sensor are known, the calibration object is fixedly arranged in the characteristic plane, and the relative position of the calibration object and the robot is known; the deviation value also includes the distance deviation of the sensor in the direction perpendicular to the characteristic plane, the pitch angle deviation in the direction perpendicular to the characteristic plane, and the roll angle deviation in the direction parallel to the characteristic plane.
[0010] According to one aspect of the present invention, the robot also has a depth sensor, the scanning range of the depth sensor completely or partially overlaps with the scanning range of the sensor, the calibration object is located within the scanning range of the depth sensor and the sensor, and the depth sensor is used to obtain point cloud data of the calibration object.
[0011] According to one aspect of the present invention, the robot sensor calibration method also includes determining whether the point cloud data of the calibration object acquired by the sensor and the depth sensor conforms to the preset characteristics of the calibration object. If the scanning result does not conform to the preset characteristics of the calibration object, controlling the robot to issue an alarm.
[0012] According to one aspect of the present invention, the robot sensor calibration method also includes converting the point cloud data of the reference position and the calibration object into coordinate values in a three-dimensional rectangular coordinate system; the three-dimensional rectangular coordinate system takes the foot of the perpendicular of the standard position of the sensor in the feature plane as the origin, the perpendicular line between the standard position of the sensor and the feature plane as the Z axis, the projection of the midline of the sensor's field of view in the feature plane as the X axis, and the perpendicular direction of the X axis in the feature plane as the Y axis; wherein the preset straight lines are the X axis and its parallel line and the Y axis and its parallel line.
[0013] According to one aspect of the present invention, the robot sensor calibration method further includes:
[0014] Controlling the depth sensor to scan the calibration object and obtaining the coordinates of the calibration object in the XY plane;
[0015] Calculating the distance deviation between the sensor and the standard position in the plane parallel to the feature surface according to the coordinates of the calibration object acquired by the depth sensor and the coordinates of the calibration object in the XY plane acquired by the sensor;
[0016] Compensate for the distance deviation between the sensor and the standard position in a plane parallel to the feature surface.
[0017] According to one aspect of the present invention, the step of calculating the deviation value of the sensor from the standard position comprises:
[0018] Calculate the deviation of the sensor from the standard position in a direction perpendicular to the characteristic plane according to the Z coordinate of the reference position;
[0019] Calculating the pitch angle deviation of the sensor from the standard position according to two reference positions with different X coordinates;
[0020] The roll angle deviation of the sensor from the standard position is calculated according to two reference positions with different Y coordinates.
[0021] According to one aspect of the present invention, the present invention also includes a robot, comprising:
[0022] main body;
[0023] A sensor is disposed on the main body and configured to scan the surrounding environment of the robot to obtain point cloud data; and
[0024] A control system is disposed on the main body and communicates with the sensor, and the control system is configured to execute the robot sensor calibration method as described above.
[0025] According to one aspect of the present invention, the robot further comprises a depth sensor, wherein the depth sensor is disposed on the main body, and a scanning range of the depth sensor completely or partially overlaps with a scanning range of the sensor.
[0026] According to one aspect of the present invention, the present invention also includes a computer-readable storage medium, including computer executable commands stored thereon, and when the executable commands are executed by a processor, the robot sensor calibration method as described above is implemented.
[0027] Compared with the prior art, the embodiment of the present invention provides a robot sensor calibration method, which uses a characteristic plane and a calibration object with preset characteristics to calibrate the sensor, and calibrates the distance deviation of the sensor in the direction perpendicular to the characteristic plane, the pitch angle deviation in the direction perpendicular to the characteristic plane, the roll angle deviation in the direction parallel to the characteristic plane, and the distance deviation of the sensor in the plane parallel to the characteristic plane. After calibration, the accuracy of the sensor can be improved, and according to the robot sensor calibration method in the embodiment of the present invention, the calibration conditions of the sensor can be reduced, the calibration process can be simplified, and the calibration efficiency can be improved. In a specific application scenario, the user can calibrate the sensor instantly without paying additional costs. The embodiment of the present invention also includes a robot capable of executing the aforementioned robot sensor calibration method, and a computer-readable storage medium capable of executing the aforementioned robot sensor calibration method. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings:
[0029] Figure 1 is a schematic flow chart of a robot sensor calibration method in one embodiment of the present invention;
[0030] Figure 2 is a flow chart of a robot sensor calibration method including a step of determining a calibration object feature in one embodiment of the present invention;
[0031] Figure 3 is a schematic flow chart of a robot sensor calibration method including a coordinate conversion process in one embodiment of the present invention;
[0032] Figure 4 is a flow chart of a robot sensor calibration method including a process of compensating for a distance deviation of a sensor in a plane parallel to a characteristic plane in one embodiment of the present invention;
[0033] Figure 5 is a schematic flow chart of a robot sensor calibration method including a characteristic plane determination process in one embodiment of the present invention;
[0034] Figure 6 is a flow chart of a robot sensor calibration method including a process of determining the number of times of reselecting a reference position in one embodiment of the present invention;
[0035] Figure 7 is a schematic flow chart of a robot sensor calibration method including a deviation calculation process in one embodiment of the present invention;
[0036] Figure 8 is a schematic diagram of a reference position and a calibration object in a characteristic plane in one embodiment of the present invention;
[0037] Fig. 9 1 is a block diagram of a robot in one embodiment of the present invention. DETAILED DESCRIPTION
[0038] In the following, only some exemplary embodiments are briefly described. As those skilled in the art will appreciate, the described embodiments may be modified in various ways without departing from the spirit or scope of the present invention. Therefore, the drawings and descriptions are considered to be exemplary and non-restrictive in nature.
[0039] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise" and the like indicate positions or positional relationships based on the positions or positional relationships shown in the accompanying drawings, which are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first" and "second" are only used for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "multiple" is two or more, unless otherwise clearly and specifically defined.
[0040] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection, an electrical connection, or can communicate with each other; it can be directly connected, or indirectly connected through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0041] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may include that the first and second features are in direct contact, or may include that the first and second features are not in direct contact but are in contact through another feature between them. Moreover, a first feature being "above", "above" and "above" a second feature includes that the first feature is directly above and obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" and "below" a second feature includes that the first feature is directly above and obliquely above the second feature, or simply means that the first feature is lower in level than the second feature.
[0042] The disclosure below provides many different embodiments or examples to realize different structures of the present invention. In order to simplify the disclosure of the present invention, the parts and settings of specific examples are described below. Of course, they are only examples, and the purpose is not to limit the present invention. In addition, the present invention can repeat reference numbers and / or reference letters in different examples, and this repetition is for the purpose of simplicity and clarity, which itself does not indicate the relationship between the various embodiments and / or settings discussed. In addition, the present invention provides various specific examples of processes and materials, but those of ordinary skill in the art can be aware of the application of other processes and / or the use of other materials.
[0043] The preferred embodiments of the present invention are described below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0044] Figure 1 The specific process of the robot sensor calibration method 100 according to a preferred embodiment of the invention is shown below. Figure 1 Detailed description.
[0045] The robot sensor calibration method 100 in this embodiment is used to inspect and calibrate the sensors installed on the robot. The sensors are used to obtain point cloud information of the robot's surrounding environment, such as visual sensors, distance sensors, laser radars, etc. Under normal circumstances, due to limited processing accuracy and installation accuracy, it is difficult for the sensor to be completely located in the standard position, that is, the theoretical installation position of the sensor on the robot. In addition, during the normal operation of the robot, the sensor may deviate from the standard position due to factors such as mechanical collisions, and the environmental information obtained by the sensor deviates from the actual situation, causing the robot to be positioned incorrectly or even to collide. Therefore, the sensor needs to be calibrated before leaving the factory and after a period of use. The robot can be calibrated in the factory's calibration workshop before leaving the factory, but there is no calibration space that meets the requirements in the usage scenario, and the time cost and economic cost of a calibration are high.
[0046] According to the robot sensor calibration method in this embodiment, Figure 1As shown, in step S101, the robot is controlled to move to a position with a characteristic plane, in which a calibration object with preset characteristics is fixed, the sensor is controlled to scan the characteristic plane and the calibration object, and the point cloud data of the characteristic plane and the calibration object are obtained. According to a preferred embodiment of the present invention, the characteristic plane can be a horizontal plane, or any physical plane whose distance and direction to the standard position of the sensor are known, and is within the scanning range of the sensor. Specifically, it can be selected according to the position of the sensor, such as the ground, ceiling, upright wall, etc., preferably the ground within the robot's activity range. The standard position of the sensor and the structural size of the robot are known. The angle and distance between the standard position of the sensor and the ground can be obtained by the height at which the sensor is installed on the robot. The ground within the robot's activity range is usually relatively flat, and there are not too many restrictions. When the sensor needs to be calibrated and corrected, the robot can be controlled to execute the robot sensor calibration method 100 in this embodiment. If the ground is not within the scanning range of the sensor, or the ground is obviously non-planar, such as when the sensor is set on the side or top of the robot, or when the ground has a flexible cushion, other physical planes can be selected as feature planes. For example, when the distance is known, the wall parallel to the upright direction of the robot can be selected as the feature plane, or when the floor height is known, the ceiling can be selected as the feature plane. In special scenarios, a physical plane with a certain slope can also be used as a feature plane. The calibration object is fixedly set in the feature plane and has preset features, such as a special shape or a special structure that can be reflected in the point cloud data, so as to distinguish other obstacles within the scanning range of the sensor, so that the sensor can accurately identify the calibration object. Specifically, taking the ground as the feature plane, the calibration object can be a cylindrical object placed in the ground and located within the scanning range of the sensor. According to a preferred embodiment of the present invention, the relative position of the calibration object and the robot is known, and there is only one calibration object that meets the preset characteristics within the scanning range of the sensor. If the sensor scans and obtains multiple objects with similar characteristics, it indicates that there are obstacles within the scanning range of the sensor. The specific method of obtaining the relative position of the calibration object and the robot can be input in advance. For example, the calibration object is set at a preset position on the feature plane, and the relative position relationship between the calibration object and the robot is determined by other measurement methods. The relative position relationship between the calibration object and the robot can also be obtained by other sensors. The specific method is described in detail in the subsequent embodiments.
[0047] In step S102, at least two independent positions of the feature plane that are not on the preset straight line are arbitrarily selected as reference positions, and the point cloud data of the reference positions are obtained from the point cloud corresponding to the feature plane. The reference position is located in the feature plane. When the sensor scans the feature plane, the point cloud of the feature plane within the scanning range is obtained, and a reference position that meets the requirements is selected therefrom. Due to scanning errors or the physical plane not meeting the requirements of the feature plane, the reference position is not necessarily located in the physical plane during actual operation. In this embodiment, independent of each other means that the ranges between the reference positions do not overlap, and not on the preset straight line means that there is an angle between the line connecting the two reference positions and the preset straight line, rather than an angle between the line connecting any two reference positions and the preset straight line. The preset straight line is combined with the preset straight line in subsequent embodiments. Figure 8 Detailed description.
[0048] At least two reference positions are selected, preferably multiple. For example, according to a preferred embodiment of the present invention, four reference positions are selected in the point cloud data of the feature plane, and there is an angle between the connecting line of two reference positions among the four reference positions and the preset straight line. According to a preferred embodiment of the present invention, the spacing between adjacent reference positions in the feature plane is not less than a second preset distance, such as 20 cm. The larger the spacing between the reference positions, the more it can represent the deviation value of the sensor from the standard position.
[0049] In step S103, according to the point cloud data of the reference position and the calibration object, the deviation value of the sensor from the standard position is calculated, wherein the deviation value of the sensor from the standard position includes the distance deviation of the sensor in the parallel plane of the feature plane. According to the preferred embodiment of the present invention, the deviation of the sensor from the standard position also includes the distance deviation of the sensor in the vertical direction of the feature plane, the pitch angle deviation of the sensor in the vertical direction of the feature plane and the roll angle deviation of the sensor in the parallel line direction of the feature plane. The specific deviation value decomposition and correction are described in detail in the subsequent embodiments. In step S104, according to the deviation value of the sensor from the standard position, the scanning error caused by the deviation of the sensor from the standard position is compensated to complete the correction of the sensor. For example, after the sensor obtains the point cloud data within the scanning range, the compensation amount of the deviation is added to the point cloud data, and the measured data is corrected to obtain more accurate data. This embodiment uses the scene of the conventional movement of the robot to establish an environment that can be used to calibrate the sensor. When the sensor needs to be calibrated, it does not need to be returned to the factory or to a specific calibration space. The calibration correction can be performed only in an environment with a characteristic plane that meets the requirements, which simplifies the sensor calibration process and greatly reduces the time cost and economic cost of sensor calibration. In a preferred embodiment of the present invention, the robot can be controlled to perform sensor calibration by manually inputting preset calibration instructions, or a program can be preset so that the robot automatically executes the robot sensor calibration method after a period of time. The robot can complete the sensor calibration while working normally or when there is no work task, thereby greatly improving the stability of the robot operation.
[0050] Figure 2 The specific process of the robot sensor calibration method 200 in the preferred embodiment of the present invention is shown, which includes the judgment of the preset features of the calibration object. The robot in this embodiment also has a depth sensor, which can also obtain point cloud data of the target object, for example, the depth sensor is a laser radar. Specifically, in this embodiment, the depth sensor is located at the standard position of the depth sensor (theoretical installation position), or the depth sensor has been calibrated and qualified, and the scanning range of the depth sensor completely overlaps or partially overlaps with the scanning range of the sensor that needs to be calibrated in this embodiment, and the calibration object is located within the scanning range of the depth sensor and the sensor, that is, the point cloud data of the calibration object can also be obtained through the depth sensor.
[0051] In the robot sensor calibration method 200 in this embodiment, steps S201, S204, S205 and S206 are substantially the same as steps S101, S102, S103 and S104 in the robot sensor calibration method 100, and are not described in detail here. In step S202, the depth sensor on the robot is controlled to scan the calibration object and obtain point cloud data. In different embodiments, the depth sensor can scan the calibration object at the same time as the sensor to be calibrated, or can scan the calibration object in any order, and finally obtain two sets of point cloud data respectively. The calibration object in this step is not a physical calibration object, but may be an obstacle existing in the feature plane, so it is necessary to make a judgment in step S203. In step S203, it is judged whether the point cloud data of the calibration object obtained by the sensor and the depth sensor meets the preset characteristics of the calibration object. As mentioned above, the calibration object has a preset shape, such as a cylinder, a prism or a pyramid. The point cloud data obtained by scanning may not match the preset characteristics, so it is necessary to judge the scanning result.
[0052] For example, if the calibration object is cylindrical, the preset feature information of the calibration object may include shape and size. Specifically, if the point cloud data obtained by the sensor to be calibrated and the depth sensor do not correspond to the preset features of the calibration object, or the point cloud data obtained by the depth sensor does not correspond to the preset features of the calibration object, it indicates that the scanned object (or the scanned object of the depth sensor) is not the calibration object, and the point cloud data of the calibration object cannot be obtained, and the control robot issues an alarm. If the point cloud data obtained by the depth sensor meets the preset features of the calibration object, and the point cloud data obtained by the sensor to be calibrated does not meet the preset features of the calibration object, it is considered that the scanning result of the sensor to be calibrated has a large error, which exceeds the adjustment range of the robot sensor calibration method 200 in this embodiment, and the control robot issues an alarm.
[0053] In a specific embodiment, the sensor is a visual sensor, the feature plane is the ground, and the projection of the sensor's scanning range on the feature plane is a 1.5*1.5 meter square. Within the sensor's scanning range, there is only one calibration object cluster, and it meets the preset characteristics of the calibration object. For example, the calibration object is set 30-50 cm in front of the robot. Within this range, accurate calibration object point cloud data can be obtained through the depth sensor, and the point cloud data of the calibration object can be used to calibrate and correct the sensor.
[0054] Figure 3 The specific process of the robot sensor calibration method 300 according to the preferred embodiment of the present invention is shown, which includes the coordinate conversion process. Figure 3 Detailed description.
[0055] like Figure 3As shown, steps S301, S302, S304 and S305 in the robot sensor calibration method 300 in this embodiment are substantially the same as steps S101, S102, S103 and S104 in the robot sensor calibration method 100 in the aforementioned embodiment, and are not described in detail.
[0056] In step S303, the point cloud data of the reference position and the calibration object are converted into coordinate values in a three-dimensional rectangular coordinate system. The three-dimensional rectangular coordinate system in this embodiment is established according to the standard position of the sensor and the feature plane, with the foot of the perpendicular of the standard position of the sensor in the feature plane as the origin, the perpendicular line between the standard position of the sensor and the feature plane as the Z axis, the projection of the midline of the sensor's field of view in the feature plane as the X axis, and the vertical direction of the X axis in the feature plane as the Y axis, as shown in FIG. Figure 8 As shown, the rectangular shaded part is the projection of the scanning range on the feature plane when the sensor is located at the standard position, the midline position is the X-axis, the XY plane is the feature plane, and the Z-axis is the perpendicular line of the feature plane. Further, the preset straight line described in step S302 is the X-axis and its parallel line, and the Y-axis and its parallel line, that is, the X coordinates of two or more reference positions are not completely the same, and the Y coordinates are not completely the same. Relying on the (X, Y, Z) coordinates of the reference position, the distance deviation of the sensor in the perpendicular direction of the feature plane, the pitch angle deviation in the vertical direction of the feature plane, and the roll angle deviation in the parallel direction of the feature plane can be calculated. At the same time, the relative position relationship between the calibration object and the robot is known, so the theoretical coordinate data of the calibration object in the feature plane can also be obtained (that is, the data of the calibration object obtained by scanning when the sensor is located at the standard position). The point cloud data obtained by the actual scanning can be used to calculate the distance deviation between the sensor and the standard position in the parallel plane of the feature plane, and compensate for it to complete the calibration of the sensor.
[0057] Figure 4 The specific process of the robot sensor calibration method 400 according to the preferred embodiment of the present invention is shown, which includes the process of specifically calculating the distance deviation of the sensor in the parallel plane of the characteristic plane. Figure 4 Detailed description.
[0058] Steps S401, S402, S403, S404, S408 and S409 in the robot sensor calibration method 400 are respectively substantially the same as steps S201, S202, S203, S204, S206 and S207 in the robot sensor calibration method 200 in the aforementioned embodiment. Step S405 in this embodiment is substantially the same as step S303 in the robot sensor calibration method 300 in the aforementioned embodiment and will not be repeated herein.
[0059] In step S406, the point cloud data of the calibration object acquired by the depth sensor is converted into coordinates in a three-dimensional rectangular coordinate system, and further converted into coordinates (X1, Y1) in the XY plane. The calibration object itself has thickness, but the values of the Z coordinates at different positions in the feature plane are affected by the deviation of the sensor in other directions, which is not conducive to decomposing and compensating the deviation values. Therefore, only the coordinate data in the XY plane is used in this embodiment. In step S407, according to the coordinates (X2, Y2) of the calibration object acquired and calculated by the sensor in the XY plane, and the coordinates (X1, Y1) of the calibration object acquired and calculated by the depth sensor in the XY plane, the distance deviation value between the sensor and the standard position in the plane parallel to the feature plane can be calculated, which can be compensated in step S408 to complete the calibration of the sensor.
[0060] Figure 5 The specific process of the robot sensor calibration method 500 according to the preferred embodiment of the present invention is shown, which includes the process of determining the characteristic plane. Figure 5 Detailed description.
[0061] Steps S501, S502, S503, S504, S507, S508, S509, S510 and S511 in the robot sensor calibration method 500 are substantially the same as steps S401, S402, S403, S404, S405, S406, S407, S408 and S409 in the robot sensor calibration method 400, respectively.
[0062] In step S505, after obtaining the point cloud data of the reference position, the point cloud data of the reference position is fitted to obtain a fitting plane and fitting parameters. In this embodiment, the point cloud data of the reference position is a part of the point cloud data of the feature plane, such as a point cloud within a certain area centered on a certain point. The point cloud data of the feature plane is obtained by controlling the sensor to scan the physical plane. In this step, the point cloud data of the reference position is fitted to obtain a fitting plane. In theory, the fitting plane should correspond to the physical plane scanned by the sensor, but since the physical plane may have defects, such as potholes, bumps, or slope changes, they will affect the scanning results, and even multiple reference positions may not be coplanar. Therefore, in the robot sensor calibration method 500, step S506 determines whether the fitting parameters meet the feature plane, relies on the point cloud data of the reference position to fit the plane, and determines whether it meets the characteristics of the feature plane after obtaining the fitting plane. In this embodiment, it is used to determine whether the physical plane scanned by the sensor can be used as a feature plane for sensor calibration. If the fitting parameters meet the feature plane, the subsequent steps S507-S510 are performed to calibrate and compensate the sensor.
[0063] If the fitting parameters do not conform to the characteristic plane, in step S512, the reference position is deleted, and the reference position is reselected in the scanning result of the characteristic plane until at least two reference positions that are independent of each other and not on the preset straight line are obtained. The physical plane in the application scenario of the robot is used as the characteristic plane, and the sensor is calibrated based on the characteristic plane, but the physical plane often cannot meet the requirements of the sensor's specific calibration space. Therefore, the fitting plane of the point cloud data of the arbitrarily selected reference position often causes the reference position to be not in the same plane due to the defects of the physical plane. At this time, relying on the reference position to calibrate the sensor will affect the calibration result. In this embodiment, the reference position is deleted, and the reference position is reselected in the characteristic plane, and the plane fitting is re-performed until the reference position that meets the requirements is obtained. Specifically, according to a preferred embodiment of the present invention, all the selected reference positions can be deleted and reselected, or one of the reference positions can be deleted, or some of the reference positions can be reselected until the reference position that meets the requirements is obtained. Further, according to a preferred embodiment of the present invention, when the reference position is reselected, the distance between the reselected reference position and the deleted reference position is not less than the first preset distance, such as 10 cm. The undulation of the physical plane is the main reason why the fitting plane does not conform to the feature plane. In order to avoid the reselected reference position from not meeting the requirements, this embodiment limits the distance between the reselected reference position and the deleted reference position to avoid the same defect in the physical plane from affecting the reference position.
[0064] Figure 6 The specific steps of the robot sensor calibration method 600 according to the preferred embodiment of the present invention are shown, which further limits the selection of the reference position and improves the accuracy of the calibration result. Steps S601, S602, S603, S604, S605, S608, S609, S610, S611, S612 and S613 in the robot sensor calibration method 600 are respectively the same as steps S501, S603, S604, S605, S608, S609, S610, S611, S612 and S613 in the robot sensor calibration method 500. S502, S503, S504, S505, S507, S508, S509, S510, S511 and S512 are substantially the same, wherein in this embodiment, in S605, the point cloud data of the reference position is fitted to obtain a fitting plane, and after obtaining the fitting parameters, in step S606, the external points in the point cloud data of the reference position are counted, and the proportion of the external points is calculated. In this embodiment, the reference position is the point cloud range in the feature plane point cloud data. According to the accuracy of the sensor, the reference position includes multiple groups of point cloud data. The external points described in this step are error points, which are points that are not in the fitting plane. They may be caused by defects in the physical plane or by sensor scanning errors. The proportion of external points indicates the proportion of the number of external points to the point cloud data in the reference position.
[0065] In step S607, it is determined whether the ratio of the external points conforms to the characteristic plane. If the ratio of the external points is small and conforms to the characteristic plane, then steps S608-S611 are performed to calibrate the sensor using the selected reference position and calibration object. If the ratio of the external points is too large, it means that there are large fluctuations in the reference position, or there are large errors in the sensor measurement data, which do not conform to the characteristic plane. Therefore, in step S613, it is necessary to delete the reference position and reselect the reference position. Furthermore, the distance between the reselected reference position and the deleted reference position is not less than the first preset distance.
[0066] In step S614, it is determined whether the number of times the reference position is reselected is greater than a first threshold, for example, 5 times. If the number of times the reference position is reselected is not greater than the first threshold, step S605 is repeated to perform plane fitting according to the newly selected reference position to obtain fitting parameters. If the number of times the reference position is reselected is greater, it means that there are more positions in the physical plane scanned by the sensor that do not conform to the characteristic plane. If the number of times the reference position is reselected is greater than the first threshold, that is, the physical plane cannot be used as a characteristic plane, the sensor is calibrated, for example, the flatness of the physical plane is poor, or there are other obstacles in the physical plane, in step S615, an alarm is issued, or the robot is controlled to move to another position to re-determine the characteristic plane. In this embodiment, the characteristic plane is only a physical plane that meets the requirements. For example, the ground is selected as the characteristic plane. When the ground scanned by the sensor at a position does not conform to the characteristic plane, the robot can be controlled to move to another position, rescan the ground, and use the above method to judge the scanning result. If the reference position is reselected too much at this time, it may also be that the sensor has a large deviation and cannot be adjusted by calibration compensation. The robot is controlled to issue an alarm, indicating that the adjustment range is exceeded.
[0067] Figure 7 The specific steps of the robot sensor calibration method 700 according to the preferred embodiment of the present invention are shown. Figure 8 A schematic diagram of a characteristic plane, a reference position and a calibration object according to a preferred embodiment of the present invention is shown below. Figure 7 and Figure 8 Detailed description.
[0068] In the robot sensor calibration method 700, steps S701, S702, S703, S704, S705, S706, S707, S708, S712, S713, S714, S715, S716, S717 and S718 are basically the same as steps S601, S602, S603, S604, S605, S606, S607, S608, S609, S610, S611, S612, S613, S614 and S615 in the robot sensor calibration method 600, and are not further described here. In this embodiment, the deviation of the sensor is decomposed into the vertical deviation on the Z axis, the roll angle deviation in the ZY plane, and the pitch angle deviation in the ZX plane. In step S709, the deviation between the sensor and the standard position in the direction perpendicular to the feature plane is calculated based on the Z coordinate of the reference position, that is, the vertical deviation on the Z axis. For example, taking the ground as the feature plane, the distance between the standard position of the sensor and the ground can be calculated based on the height of the robot. In theory, the Z coordinate of the reference position should be 0. The distance deviation of the sensor on the Z axis can be obtained based on the average value of the measured data of a group of reference positions, or the vertical deviation of the sensor on the Z axis can be obtained based on the average value of multiple reference positions. In step S710, the pitch angle error between the sensor and the standard position is calculated based on two reference positions with different X coordinates, for example Figure 8 In the reference position A1 and the reference position A3 or the reference position A4, when the sensor is at the standard position, the angle between the midline of the sensor scanning range and the characteristic plane is a known fixed value. According to the change of the X coordinates of the two reference positions with different X coordinates, the pitch angle deviation of the sensor from the standard position can be calculated. In step S711, according to the two reference positions with different Y coordinates, the roll angle deviation of the sensor from the standard position is calculated. For example, Figure 8 The reference position A1 and the reference position A2 or the reference position A3 in the reference position, according to the change of the Y coordinate of the reference position, when the sensor is located at the standard position, the angle between the center line of the sensor scanning range and the characteristic plane is a known fixed value, and according to the change of the Y coordinate in the two reference positions with different Y coordinates, the roll angle deviation of the sensor from the standard position can be calculated. Of course, in different embodiments of the present invention, the distance deviation on the Z axis, the roll angle deviation and the pitch angle deviation can be calculated as Figure 7 The three deviation values can be calculated in sequence, or simultaneously, or in any sequence. After the three deviation values are calculated, the measurement data of the sensor is compensated to complete the calibration of the sensor.
[0069] The present invention also includes an embodiment of a robot, such as Fig. 9As shown, the robot 1 includes a main body, a sensor 10 and a control system 20. The main body is the external frame of the robot 1, which is used to support and install the components inside it. The sensor 10 is installed on the main body and can scan the environment around the robot 1 to obtain point cloud data of the surrounding environment, such as a visual sensor, a laser radar, etc. The control system 20 is arranged on the main body and communicates with the sensor 10. It can execute the aforementioned sensor calibration method, calibrate the position of the sensor, and improve the accuracy of the sensor measurement data. In a preferred embodiment of the present invention, the robot 1 also includes a depth sensor 30, which is arranged on the main body, and the scanning range of the depth sensor 30 overlaps with the scanning range of the sensor 10 in whole or in part. The depth sensor 30 is used to obtain point cloud data of the calibration object. In a preferred embodiment of the present invention, the robot 1 also includes a motion device 40, which communicates with the control system 20 and can be controlled to drive the robot to move. The control system 20 can execute the aforementioned sensor calibration method after receiving a preset instruction or after a certain preset time interval, for example, the operator manually inputs the sensor calibration instruction, or automatically executes the sensor calibration method after moving for a period of time, controls the motion device 40, and moves the robot to a position with a characteristic plane.
[0070] The present invention also includes an embodiment of a computer-readable storage medium, including computer executable instructions stored thereon, and when the executable instructions are executed by a processor, the sensor calibration method as described above is implemented.
[0071] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or replace some of the technical features therein by equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A robot sensor calibration method, comprising: The robot is controlled to move to a position having a characteristic plane, in which a calibration object having preset characteristics is fixed, and the sensor is controlled to scan the characteristic plane and the calibration object, and obtain point cloud data of the characteristic plane and the calibration object; the characteristic plane is a horizontal plane, or any physical plane whose distance and direction from the standard position of the sensor are known; At least two positions of the feature plane that are independent of each other and not on the preset straight line are arbitrarily selected as reference positions, and point cloud data of the reference positions are obtained from the point cloud corresponding to the feature plane; Calculate the deviation value of the sensor from the standard position according to the reference position and the point cloud data of the calibration object, wherein the deviation value includes the distance deviation of the sensor in the plane parallel to the characteristic plane; According to the deviation value between the sensor and the standard position, the scanning error caused by the sensor deviating from the standard position is compensated to complete the calibration of the sensor. The standard position is the theoretical installation position of the sensor on the robot.
2. The robot sensor calibration method according to claim 1, wherein the calibration object is fixedly arranged in the feature plane, and the relative position of the calibration object and the robot is known; the deviation value also includes the distance deviation of the sensor in the direction perpendicular to the feature plane, the pitch angle deviation in the direction perpendicular to the feature plane, and the roll angle deviation in the direction parallel to the feature plane.
3. The robot sensor calibration method according to claim 1 or 2, wherein the robot also has a depth sensor, the scanning range of the depth sensor overlaps with the scanning range of the sensor in whole or in part, the calibration object is located within the scanning range of the depth sensor and the sensor, and the depth sensor is used to obtain point cloud data of the calibration object.
4. The robot sensor calibration method according to claim 3 further includes determining whether the point cloud data of the calibration object acquired by the sensor and the depth sensor conforms to the preset characteristics of the calibration object; if the scanning result does not conform to the preset characteristics of the calibration object, controlling the robot to issue an alarm.
5. The robot sensor calibration method according to claim 3 further includes converting the point cloud data of the reference position and the calibration object into coordinate values in a three-dimensional rectangular coordinate system; the three-dimensional rectangular coordinate system takes the foot of the perpendicular of the standard position of the sensor in the feature plane as the origin, the perpendicular line between the standard position of the sensor and the feature plane as the Z axis, the projection of the midline of the field of view of the sensor in the feature plane as the X axis, and the perpendicular direction of the X axis in the feature plane as the Y axis; wherein the preset straight lines are the X axis and its parallel line and the Y axis and its parallel line.
6. The robot sensor calibration method according to claim 5, further comprising: Controlling the depth sensor to scan the calibration object and obtaining the coordinates of the calibration object in the XY plane; Calculate the distance deviation between the sensor and the standard position in a plane parallel to the feature plane according to the coordinates of the calibration object acquired by the depth sensor and the coordinates of the calibration object in the XY plane acquired by the sensor; Compensate for a distance deviation between the sensor and the standard position in a plane parallel to the characteristic plane.
7. The robot sensor calibration method according to claim 5 or 6, wherein the step of calculating the deviation value between the sensor and the standard position comprises: Calculate the deviation of the sensor from the standard position in a direction perpendicular to the characteristic plane according to the Z coordinate of the reference position; Calculating the pitch angle deviation of the sensor from the standard position according to two reference positions with different X coordinates; The roll angle deviation of the sensor from the standard position is calculated according to two reference positions with different Y coordinates.
8. A robot comprising: main body; A sensor, the sensor is disposed on the main body and configured to scan the surrounding environment of the robot to obtain point cloud data; and A control system, wherein the control system is disposed on the main body and communicates with the sensor, and the control system is configured to execute the robot sensor calibration method according to any one of claims 1 to 7.
9. The robot according to claim 8, further comprising a depth sensor, wherein the depth sensor is disposed on the main body, and a scanning range of the depth sensor completely or partially overlaps with a scanning range of the sensor.
10. A computer-readable storage medium, comprising computer executable commands stored thereon, wherein the executable commands, when executed by a processor, implement the robot sensor calibration method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Three-dimension laser sensor and two-dimension laser sensor combined calibration method
CN103257342A
Laser contour sensor calibration system and method based on cross point
CN110470239A