A binocular distance measurement method with non-parallel optical axes

Through the combination of the non-parallel optical axis binocular ranging method and the IMU module monitoring the tilt angle, the problems of limited field of view and low ranging accuracy in the traditional binocular ranging method are solved, and accurate distance measurement and correction of mobile robots are achieved. , significantly improving the ranging accuracy.

CN113848964BActive Publication Date: 2024-08-27JINHUA ZHEJIANG UNIV OF TECH INNOVATION JOINT RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111051340.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-08
Publication Date
2024-08-27
Estimated Expiration
2041-09-08

AI Technical Summary

Technical Problem

In practical applications, the traditional binocular ranging method cannot effectively measure the distance of a mobile robot due to the difficulty in meeting the conditions of parallel optical axes, resulting in limited field of view, low ranging accuracy, and vulnerability to body shaking.

Method used

The non-parallel optical axis binocular ranging method is used to build a binocular system model, and the IMU module is used to monitor the tilt angle of the robot. The accuracy of the ranging results is ensured by calculating the initial ranging results and correcting them when the preset angle threshold is exceeded.

Benefits of technology

It realizes real-time ranging of the mobile robot and corrects it according to the tilt state, significantly improves the ranging accuracy and solves the problem of inaccurate ranging caused by body shaking.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113848964B
    Figure CN113848964B
Patent Text Reader

Abstract

The present invention discloses a non-parallel optical axis binocular ranging method, comprising: S1, building a binocular system model, the binocular system model comprises a binocular ranging module and an IMU module, the binocular ranging module comprises a left camera and a right camera, and the IMU module is used to monitor the tilt angle; S2, obtaining the current target first image, the target second image and the tilt angle; S3, respectively calculating the target position in the target image; S4, obtaining the initial ranging result, and judging whether the current tilt angle is lower than the preset angle threshold, if so, driving the mobile robot to move toward the target according to the initial ranging result, otherwise, correcting the initial measurement result, taking the distance from the target to the mobile robot in the upright state as the corrected ranging result, and driving the mobile robot to move toward the target according to the corrected ranging result. The method can collect images in real time for ranging and monitor the tilt state of the robot to correct the ranging result, greatly improving the ranging accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of machine vision, and in particular relates to a non-parallel optical axis binocular distance measurement method. Background Art

[0002] The binocular ranging principle calculates the distance between the corresponding actual object and the camera based on the image information collected by the left and right cameras. According to the position and posture of the left and right cameras, combined with the camera imaging principle, the corresponding distance from the measured target object to the camera is derived.

[0003] However, traditional binocular distance measurement is based on the ideal conditions that the image planes of the two cameras are located on the same plane, the optical axes are parallel to each other, and the focal lengths are the same. In actual situations, the field of view formed by parallel optical axes is relatively small, the field of view is limited, and the two cameras are difficult to keep in the same plane due to assembly errors and other reasons, resulting in the optical axes being non-parallel. In addition, the body of the two-wheeled robot will shake greatly when moving, resulting in the inability to measure the distance or the measurement results jumping, with large errors, and cannot be used as valid measurement results. Therefore, it is difficult to ensure the accuracy of distance measurement using traditional binocular distance measurement algorithms, and it is not conducive to expanding the field of view. The present application proposes a binocular distance measurement method based on non-parallel optical axes. Summary of the invention

[0004] The purpose of the present invention is to propose a non-parallel optical axis binocular ranging method to address the above problems. The method can collect images in real time to calculate the distance from the target to the mobile robot, and correct the measurement results that exceed the tilt range by monitoring the tilt state of the mobile robot. This solves the problem of inaccurate ranging due to the shaking of the mobile robot when it is moving, and can significantly improve the ranging accuracy.

[0005] To achieve the above object, the technical solution adopted by the present invention is:

[0006] The present invention proposes a non-parallel optical axis binocular ranging method, which is applied to a mobile robot and includes:

[0007] S1. Build a binocular system model on the mobile robot. The binocular system model includes a binocular ranging module and an IMU module. The binocular ranging module includes a left camera and a right camera. The IMU module is used to monitor the tilt angle of the mobile robot relative to the ground.

[0008] S2, obtaining a first target image captured by the current left camera, a second target image captured by the right camera, and a tilt angle monitored by the IMU module;

[0009] S3, respectively calculating the target position in the first target image and the second target image;

[0010] S4. Obtain the initial distance measurement result from the target to the mobile robot, and determine whether the current tilt angle is lower than the preset angle threshold. If so, drive the mobile robot to move toward the target according to the initial distance measurement result. Otherwise, correct the initial measurement result, use the distance from the target to the mobile robot in the upright state as the corrected distance measurement result, and drive the mobile robot to move toward the target according to the corrected distance measurement result.

[0011] Preferably, in step S4, the initial ranging result is calculated as follows:

[0012] 1) Calculate FK, the formula is as follows:

[0013]

[0014]

[0015]

[0016] ∠FKJ=180°-∠JFK-∠FJD

[0017] 2) Calculate MG using the following formula:

[0018]

[0019]

[0020]

[0021] ∠GML=180°-∠GLE-∠LGM

[0022] 3) Calculate the initial distance measurement result CN, the formula is as follows:

[0023] PD=EQ=FDsinθ

[0024] PQ=PD+DE+EQ

[0025] KM=PQ-FK-MG

[0026]

[0027] Wherein, C is the target position, D is the optical center of the left camera, E is the optical center of the right camera, F is the center of the first image of the target, G is the center of the second image of the target, the perpendicular line DE through point G intersects at Q, the perpendicular line DE through point F intersects at P, J is the point of the target position C in the first image of the target, L is the point of the target position C in the second image of the target, K is the intersection of CD and FG, M is the intersection of CE and FG, the perpendicular line DE through point C intersects KM at O ​​and intersects DE at N respectively, and θ is the angle between the optical axis of the left camera or the optical axis of the right camera and the perpendicular line of DE.

[0028] Preferably, the angle θ is 18°.

[0029] Preferably, in step S4, the corrected ranging result is calculated as follows:

[0030] ∠NRY=arctan(NY / RY)

[0031] VU=RZ=RScos∠SRZ

[0032] SZ=SRsin∠SRZ

[0033] SU=SZ+ZU=SZ+RV

[0034]

[0035] When the mobile robot is in the forward tilt state:

[0036] ∠SRZ=∠NRY-∠SRN

[0037] UT=UV-TV

[0038] CT=CU+UT

[0039] When the mobile robot is in a backward tilt state:

[0040] ∠SRZ=∠NRY+∠SRN

[0041] TU=TV-UV

[0042] CT=CU-TU

[0043] Corrected ranging results meet

[0044] Wherein, R is the rotation center of the driving wheel of the mobile robot, V is the contact point between the driving wheel of the mobile robot and the ground, C is the target position, the perpendicular line of the camera optical center through point C in the upright state of the mobile robot intersects at N, the perpendicular line of the camera optical center through point C in the forward or backward state of the mobile robot intersects at S, the CV perpendicular line through point N intersects at T, the CV perpendicular line through point S intersects at U, the NT perpendicular line through point R intersects at Y, the SU perpendicular line through point R intersects at Z, and ∠SRN is the tilt angle of the mobile robot relative to the ground.

[0045] Preferably, the preset angle threshold is 3°.

[0046] Compared with the prior art, the beneficial effects of the present invention are: the method can collect images in real time to calculate the distance from the target to the mobile robot and monitor the tilt state of the mobile robot, control the movement of the mobile robot according to different tilt states, and correct the initial ranging result when the preset angle threshold is exceeded, thereby solving the problem of inaccurate ranging due to the shaking of the mobile robot when the mobile robot is moving, and can significantly improve the ranging accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 It is a flow chart of the non-parallel optical axis binocular distance measurement method of the present invention;

[0048] Figure 2 This is a schematic diagram of the distance measurement principle of the mobile robot of the present invention;

[0049] Figure 3 This is a schematic diagram of the mobile robot of the present invention working in an upright state;

[0050] Figure 4 This is a schematic diagram of the mobile robot of the present invention in a forward-leaning state;

[0051] Figure 5 It is a combined schematic diagram of the upright state and the forward leaning state of the mobile robot of the present invention;

[0052] Figure 6 It is a schematic diagram of the ranging principle of the correction model of the mobile robot of the present invention when it is in a forward leaning state;

[0053] Figure 7 This is a schematic diagram of the mobile robot of the present invention in a backward state;

[0054] Figure 8 It is a combined schematic diagram of the mobile robot of the present invention in an upright state and a reclining state;

[0055] Fig. 9 This is a schematic diagram of the ranging principle of the correction model of the mobile robot of the present invention when it is in a backward state. DETAILED DESCRIPTION

[0056] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0057] It should be noted that, unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application.

[0058] like Figure 1-9 As shown, a non-parallel optical axis binocular ranging method is applied to a mobile robot, comprising:

[0059] S1. Build a binocular system model on the mobile robot. The binocular system model includes a binocular ranging module and an IMU module. The binocular ranging module includes a left camera and a right camera. The IMU module is used to monitor the tilt angle of the mobile robot relative to the ground.

[0060] Among them, the type of robot can be adjusted according to actual needs. In this embodiment, the mobile robot adopts a firefighting robot, and is a two-wheeled self-balancing robot. The target is the fire source. The binocular ranging module is two thermal imaging cameras, such as Xmodule T3-317-68 non-cooled temperature measurement thermal imaging module camera or Xmodule S0-212-68 non-cooled temperature measurement thermal imaging module camera, etc., which are used to collect fire source images. The IMU module is used to monitor the tilt angle of the mobile robot relative to the ground. When the mobile robot is in an upright state, the optical axes of the two thermal imaging cameras are not parallel. If they are tilted outward at the same time on the horizontal plane, the field of view of the thermal imaging camera can be increased. The angle of the camera optical axis can be adjusted according to actual needs, which can not only increase the field of view, but also ensure that the left and right thermal imaging cameras can still see the front, and there is no blind spot in the middle, further expanding the safety monitoring range.

[0061] S2, obtaining a first target image captured by the current left camera, a second target image captured by the right camera, and a tilt angle monitored by the IMU module;

[0062] S3, respectively calculating the target position in the first target image and the second target image;

[0063] S4. Obtain the initial distance measurement result from the target to the mobile robot, and determine whether the current tilt angle is lower than the preset angle threshold. If so, drive the mobile robot to move toward the target according to the initial distance measurement result. Otherwise, correct the initial measurement result, use the distance from the target to the mobile robot in the upright state as the corrected distance measurement result, and drive the mobile robot to move toward the target according to the corrected distance measurement result.

[0064] When a fire source is detected, such as a fire scene, an image of the fire source and the tilt angle of the mobile robot relative to the ground are obtained, wherein the position of the fire source in the target first image and the target second image can be directly obtained by using the existing technology to obtain the target pixel coordinates. After determining the fire source, the thermal imaging camera measures the distance of the fire source to obtain an initial distance measurement result. A triangle is formed based on the fire source and the optical center of the two thermal imaging cameras. The distance from the fire source to the mobile robot is obtained by using the principle of similar triangles as the initial distance measurement result. Since the mobile robot adopts a two-wheel self-balancing mechanism, the body shakes greatly during movement, which will cause the distance measurement result to jump. If the current tilt angle of the mobile robot is not lower than the preset angle threshold, it is judged that the initial distance measurement result has jumped and cannot be used as a valid measurement result. Correction is performed and the corrected distance measurement result is used as a valid measurement result. If it is lower than the preset angle threshold, the initial distance measurement result is judged to be a valid measurement result. Furthermore, in order to avoid jumps before and after a single measurement result and improve the accuracy and effectiveness of the ranging result, when within the preset angle threshold range, n groups of data can be averaged according to actual conditions as the initial ranging result, and n can be determined according to actual needs, such as n=10 in this embodiment.

[0065] In one embodiment, in step S4, the initial ranging result is calculated as follows:

[0066] 1) Calculate FK, the formula is as follows:

[0067]

[0068]

[0069]

[0070] ∠FKJ=180°-∠JFK-∠FJD

[0071] 2) Calculate MG using the following formula:

[0072]

[0073]

[0074]

[0075] ∠GML=180°-∠GLE-∠LGM

[0076] 3) Calculate the initial distance measurement result CN, the formula is as follows:

[0077] PD=EQ=FDsinθ

[0078] PQ=PD+DE+EQ

[0079] KM=PQ-FK-MG

[0080]

[0081] Wherein, C is the target position, D is the optical center of the left camera, E is the optical center of the right camera, F is the center of the first image of the target, G is the center of the second image of the target, the perpendicular line DE through point G intersects at Q, the perpendicular line DE through point F intersects at P, J is the point of the target position C in the first image of the target, L is the point of the target position C in the second image of the target, K is the intersection of CD and FG, M is the intersection of CE and FG, the perpendicular line DE through point C intersects KM at O ​​and intersects DE at N respectively, and θ is the angle between the optical axis of the left camera or the optical axis of the right camera and the perpendicular line of DE.

[0082] Among them, Figure 2 As shown, DE is the distance between the left camera and the right camera, AB is the horizontal projection of the first image of the target, HI is the horizontal projection of the second image of the target, DF is the focal length of the left camera, and GE is the focal length of the right camera. DE, AB, HI, DF, GE, θ, J, and L are all known. According to the principle of imaging, the target position C, the optical center D of the left camera, and the optical center E of the right camera form a triangle. Since the triangle CDE is similar to the triangle CKM, the principle of similar triangles is used to calculate CN, which is the distance from the fire source to the mobile robot.

[0083] In one embodiment, the angle θ is 18°. To increase the field of view of the thermal imaging camera, the angle θ in this embodiment is 18°, ensuring that the left and right thermal imaging cameras can still see straight ahead without a blind spot in the middle, further expanding the safety monitoring range.

[0084] In one embodiment, in step S4, the corrected ranging result is calculated as follows:

[0085] ∠NRY=arctan(NY / RY)

[0086] VU=RZ=RScos∠SRZ

[0087] SZ=SRsin∠SRZ

[0088] SU=SZ+ZU=SZ+RV

[0089]

[0090] When the mobile robot is in the forward tilt state:

[0091] ∠SRZ=∠NRY-∠SRN

[0092] UT=UV-TV

[0093] CT=CU+UT

[0094] When the mobile robot is in a backward tilt state:

[0095] ∠SRZ=∠NRY+∠SRN

[0096] TU=TV-UV

[0097] CT=CU-TU

[0098] Corrected ranging results meet

[0099] Wherein, R is the rotation center of the driving wheel of the mobile robot, V is the contact point between the driving wheel of the mobile robot and the ground, C is the target position, the perpendicular line of the camera optical center through point C in the upright state of the mobile robot intersects at N, the perpendicular line of the camera optical center through point C in the forward or backward state of the mobile robot intersects at S, the CV perpendicular line through point N intersects at T, the CV perpendicular line through point S intersects at U, the NT perpendicular line through point R intersects at Y, the SU perpendicular line through point R intersects at Z, and ∠SRN is the tilt angle of the mobile robot relative to the ground.

[0100] Among them, whether the mobile robot is in a forward leaning state or a backward leaning state can be judged by the tilt angle fed back by the IMU module. For example, when the tilt angle is a negative value, it is judged to be in a backward leaning state, and when the tilt angle is a positive value, it is judged to be in a forward leaning state. Figure 4-6 As shown, the mobile robot is in a forward leaning state. Figure 6 for Figure 5 The image after removing the outline of the mobile robot. Figure 7-9 As shown, the mobile robot is in the backward state. Fig. 9 for Figure 8 The figure after removing the outline of the mobile robot. CS is the initial distance measurement result, and the corrected distance measurement result CN can be obtained from the initial distance measurement result CS. When the mobile robot moves, it will shake, causing the measurement result to jump. Correction processing is performed on the measurement result with large errors, that is, the jump measurement result is corrected to the measurement result when it is upright, which can reduce the measurement error. Specifically, RV is perpendicular to CV, RV is the driving wheel radius of the mobile robot, and NT is perpendicular to CV. Among them, RV, RN, and NT are known, RS=RN, and ∠SRN is the tilt angle of the mobile robot relative to the ground, which can be obtained through the IMU module. Draw a perpendicular line NT through point R and intersect at Y, and draw a perpendicular line SU through point R and intersect at Z. NR and TV are known, RY=TV, and ∠NRY=arctan(NY / RY) is obtained, which can be substituted into the formula to obtain the corrected distance measurement result CN under the corresponding tilt state. Replacing the initial distance measurement result CS with the corrected distance measurement result CN can obtain a more accurate distance measurement result.

[0101] In one embodiment, the preset angle threshold is 3°.

[0102] In this embodiment, when the tilt angle is less than 3°, the initial ranging result is judged to be valid, and the mobile robot is driven to move toward the target according to the initial ranging result. When the tilt angle is above 3°, the initial ranging result is corrected, and the mobile robot is driven to move toward the target according to the returned corrected ranging result. For example, when the mobile robot moves to the fire extinguishing range, the fire-fighting equipment it carries can be controlled to work, such as spraying water or fire extinguishing agent to extinguish the fire, and the fire extinguishing range is set to 4 to 5 meters. This helps to ensure the accuracy of ranging while improving work efficiency. It should be noted that the value of the preset angle threshold can be adjusted according to actual needs.

[0103] This method can collect images in real time to calculate the distance from the target to the mobile robot and monitor the tilt state of the mobile robot. It can control the movement of the mobile robot according to different tilt states and correct the initial distance measurement result when the preset angle threshold is exceeded. This solves the problem of inaccurate distance measurement caused by the shaking of the mobile robot when it is moving, and can significantly improve the accuracy of distance measurement.

[0104] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0105] The above-described embodiments only express the more specific and detailed embodiments described in this application, but they cannot be understood as limiting the scope of the patent application. It should be pointed out that for ordinary technicians in this field, several modifications and improvements can be made without departing from the concept of this application, which all belong to the protection scope of this application. Therefore, the protection scope of the patent application shall be based on the attached claims.

Claims

1. A non-parallel optical axis binocular ranging method, applied to mobile robots, Features: The non-parallel optical axis binocular distance measurement method comprises: S1. Building a binocular system model on the mobile robot, wherein the binocular system model includes a binocular ranging module and an IMU module, wherein the binocular ranging module includes a left camera and a right camera, and the IMU module is used to monitor the inclination angle of the mobile robot relative to the ground; S2, obtaining a first target image currently captured by the left camera, a second target image currently captured by the right camera, and an inclination angle monitored by the IMU module; S3, respectively calculating the target position in the first target image and the second target image; S4, obtaining an initial distance measurement result from the target to the mobile robot, and determining whether the current tilt angle is lower than a preset angle threshold; if so, driving the mobile robot to move toward the target according to the initial distance measurement result; otherwise, correcting the initial measurement result, taking the distance from the target to the mobile robot in an upright state as a corrected distance measurement result, and driving the mobile robot to move toward the target according to the corrected distance measurement result; The initial ranging result is calculated as follows: 1) Calculate FK, the formula is as follows: ∠FKJ=180°-∠JFK-∠FJD 2) Calculate MG using the following formula: ∠GML=180°-∠GLE-∠LGM 3) Calculate the initial distance measurement result CN, the formula is as follows: PD=EQ=FDsinθ PQ=PD+DE+EQ KM=PQ-FK-MG Among them, C is the target position, D is the optical center of the left camera, E is the optical center of the right camera, F is the center of the first image of the target, G is the center of the second image of the target, the perpendicular line DE through point G intersects at Q, the perpendicular line DE through point F intersects at P, J is the point of the target position C in the first image of the target, L is the point of the target position C in the second image of the target, K is the intersection of CD and FG, M is the intersection of CE and FG, the perpendicular line DE through point C intersects KM at O ​​and intersects DE at N respectively, and θ is the angle between the optical axis of the left camera or the optical axis of the right camera and the perpendicular line of DE.

2. The non-parallel optical axis binocular distance measurement method as claimed in claim 1, Features: The angle θ is 18°.

3. The non-parallel optical axis binocular distance measurement method as claimed in claim 1, Features: In step S4, the corrected ranging result is calculated as follows: ∠NRY=arctan(NY / RY) VU=RZ=RScos∠SRZ SZ=SR sin∠SRZ SU=SZ+ZU=SZ+RV When the mobile robot is in a forward leaning state: ∠SRZ=∠NRY-∠SRN UT=UV-TV CT=CU+UT When the mobile robot is in a backward tilt state: ∠SRZ=∠NRY+∠SRN TU=TV-UV CT=CU-TU The corrected ranging result satisfies Wherein, R is the rotation center of the driving wheel of the mobile robot, V is the contact point between the driving wheel of the mobile robot and the ground, C is the target position, when the mobile robot is in an upright state, a perpendicular line connecting the optical centers of the cameras through point C intersects at N, when the mobile robot is in a forward or backward tilted state, a perpendicular line connecting the optical centers of the cameras through point C intersects at S, a CV perpendicular line through point N intersects at T, a CV perpendicular line through point S intersects at U, a NT perpendicular line through point R intersects at Y, a SU perpendicular line through point R intersects at Z, and ∠SRN is the inclination angle of the mobile robot relative to the ground.

4. The non-parallel optical axis binocular distance measurement method as claimed in claim 1, Features: The preset angle threshold is 3°.