CN-121998851-A - Line structure optical filtering method, robot obstacle avoidance method and robot
Abstract
The invention provides a line structure optical filtering method, a robot obstacle avoidance method and a robot, which can filter interference in a strong light environment and during rapid movement, and improve the accuracy of point cloud reconstruction. The line structure optical filtering method comprises the steps of respectively obtaining images acquired by a line structure optical camera when laser is started or closed so as to correspondingly obtain a target image and a background image, respectively extracting the light spot centers in the target image and the background image so as to correspondingly obtain a candidate point set and a corrosion point set, and carrying out neighborhood filtering on each candidate point of the candidate point set based on the corrosion point of the corrosion point set so as to obtain the filtered light spot point set.
Inventors
- GAO BO
- ZHANG XINYUAN
- WANG JIE
- RUAN JIANGFENG
Assignees
- 浙江舜宇智能光学技术有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20241101
Claims (13)
- 1. The line structure optical filtering method is characterized by comprising the following steps: respectively acquiring images acquired by a line structured light camera when laser is turned on or turned off so as to correspondingly acquire a target image and a background image; extracting spot centers in the target image and the background image respectively to obtain a candidate point set and a corrosion point set, respectively, and And carrying out neighborhood filtering on each candidate point of the candidate point set based on the corrosion points of the corrosion point set to obtain a filtered spot point set.
- 2. The method of claim 1, wherein the step of neighborhood filtering each candidate point of the candidate point set based on the corrosion point of the corrosion point set to obtain a filtered spot point set comprises the steps of: determining a neighborhood filtering range for each candidate point in the set of candidate points, and Judging whether each candidate point of the candidate point set is similar to the corrosion point of the corrosion point set in the corresponding neighborhood filtering range, if so, filtering the candidate point, and if not, reserving the candidate point.
- 3. The line structured light filtering method as recited in claim 2, wherein said step of determining a neighborhood filtering range for each candidate point in the set of candidate points comprises the steps of: Dynamically calculating a lateral filtering range of each candidate point in the candidate point set by a lateral filtering partial derivative model based on the angular velocity information input in real time, and And dynamically calculating the longitudinal filtering range of each candidate point in the candidate point set through a longitudinal filtering partial derivative model based on the linear speed information input in real time.
- 4. A line structured light filtering method as claimed in claim 3 wherein said lateral filter bias model is: the method comprises the steps of (1) taking du as a transverse offset variable quantity of an interference light source, fx as a transverse equivalent focal length of the line structure light camera, R as a rotation radius of the line structure light camera, Z as a preset depth, θx as a transverse offset angle of the interference light source, ω as an angular speed of a robot body, and dt as an interframe time difference of the line structure light camera.
- 5. A line structured light filtering method as claimed in claim 3 wherein said longitudinal filter bias model is: The method comprises the steps of dv is a longitudinal offset variable quantity of an interference light source, fy is a longitudinal equivalent focal length of the line structure light camera, z c is a z-direction coordinate under a camera coordinate system, a is an included angle between the camera coordinate system and a body coordinate system, θy is a longitudinal offset angle of the interference light source, v s is a linear speed of the robot body moving forwards, and dt is an interframe time difference of the line structure light camera.
- 6. The line structured light filtering method according to claim 2, wherein in the step of determining a neighborhood filtering range of each candidate point in the candidate point set, the neighborhood filtering range is obtained by calculating a pixel-level motion amount from images of adjacent frames by an optical flow method, or the neighborhood filtering range is a range of preset filtering according to a design speed.
- 7. The line structured light filtering method according to any one of claims 2 to 6, wherein the step of determining whether each candidate point of the candidate point set is similar to an etch point of the etch point set within a corresponding neighborhood filtering range comprises the steps of: And judging the similarity between the candidate point and the corrosion point according to the flare brightness and width information of the candidate point and the corrosion point.
- 8. The line structured light filtering method according to claim 7, wherein the step of judging the similarity between the candidate point and the etched point based on the flare brightness and width information of the candidate point and the etched point comprises the steps of: Calculating the maximum brightness and width of the light spots of the candidate point and the corrosion point respectively; respectively calculating brightness difference values and width difference values between the candidate points and corresponding corrosion points; Judging whether the brightness difference value and the width difference value are respectively and correspondingly larger than a brightness threshold value and a width threshold value; Determining that the candidate point is not similar to the corresponding corrosion point in response to the luminance difference being greater than the luminance threshold and/or the width difference being greater than the width threshold, and And in response to the brightness difference being less than or equal to the brightness threshold and the width difference being less than or equal to the width threshold, determining that the candidate point is similar to the corresponding corrosion point.
- 9. The line structured light filtering method according to any one of claims 2 to 6, wherein the step of determining whether each candidate point of the candidate point set is similar to an etch point of the etch point set within a corresponding neighborhood filtering range comprises the steps of: and judging the similarity between the candidate point and the corrosion point according to the brightness distribution condition of the spot center neighborhood of the candidate point and the corrosion point.
- 10. The line structured light filtering method according to claim 9, wherein the step of judging the similarity between the candidate point and the corrosion point based on the brightness distribution of the spot center neighborhood of the candidate point and the corrosion point comprises the steps of: presetting a facula center neighborhood of the candidate point and a facula center neighborhood of the corrosion point; Respectively extracting brightness values of pixels in the corresponding spot center neighborhood from the target image and the background image to respectively obtain a candidate lighting brightness distribution array and a corrosion point brightness distribution array; Judging whether the brightness value of each pixel position in the candidate lighting brightness distribution array is larger than the brightness value of the corresponding pixel position in the corrosion point brightness distribution array or not, if so, marking the candidate position, and if not, marking the corrosion position; Counting the ratio of the number of candidate positions in the spot center neighborhood to the total number of positions to obtain candidate ratio, and Judging whether the candidate proportion is larger than a preset proportion threshold value, if so, judging that the candidate point is similar to the corresponding corrosion point, and if not, judging that the candidate point is dissimilar to the corresponding corrosion point.
- 11. The line structured light filtering method according to claim 9, wherein the step of judging the similarity between the candidate point and the corrosion point based on the brightness distribution of the spot center neighborhood of the candidate point and the corrosion point comprises the steps of: presetting a facula center neighborhood of the candidate point and a facula center neighborhood of the corrosion point; Respectively extracting brightness values of pixels in the corresponding spot center neighborhood from the target image and the background image to respectively obtain a candidate lighting brightness distribution array and a corrosion point brightness distribution array; Calculating a cross correlation coefficient between the candidate light intensity distribution array and the corrosion light intensity distribution array by a cross correlation coefficient model, and And judging whether the cross correlation coefficient is larger than a preset coefficient threshold value, if so, judging that the candidate point is similar to the corresponding corrosion point, and if not, judging that the candidate point is dissimilar to the corresponding corrosion point.
- 12. The robot obstacle avoidance method is characterized by comprising the following steps: Starting laser of the line structure light camera to acquire an image within a preset exposure time so as to obtain a laser starting frame image; closing the laser of the line structured light camera to acquire images within the same exposure time to obtain a laser closed frame image; filtering the laser on-frame image by the line structured light filtering method according to any one of claims 1 to 11 based on the laser off-frame image to obtain a filtered set of spot points, and Based on the filtered light spot set, reconstructing a three-dimensional point cloud to guide the robot to avoid the obstacle.
- 13. Robot, its characterized in that includes: A robot body; A line structured light camera mounted to the robot body, and A control module communicatively connected to the robot body and the line structure light camera for performing the steps in the robot obstacle avoidance method of claim 12.
Description
Line structure optical filtering method, robot obstacle avoidance method and robot Technical Field The invention relates to the technical field of depth ranging, in particular to a line structure optical filtering method, a robot obstacle avoidance method and a robot. Background The line structure light ranging scheme is applied as a depth ranging scheme in more and more fields, wherein obstacle avoidance using a line structure light vision sensor in a service robot field such as a sweeper has become a mainstream. Because the reconstruction principle of the line structure light module is triangular ranging, depth information is provided by a laser, and laser spots on an image are calculated to obtain three-dimensional point clouds, when a strong ambient light source such as sunlight appears in the operation process of the sweeper, surrounding objects can be illuminated, and the image has the characteristic of being illuminated by the ambient light besides line laser. If the light spot lightened by the ambient light is mistakenly selected for reconstruction, noise points can be formed, and the normal operation of the sweeper is affected. Currently, a conventional denoising scheme is usually to collect a background image when the laser is turned off, and reconstruct the background-subtracted image. However, although the scheme is feasible for static or low-speed scenes, for a sweeper in rapid straight movement or rotation, the background is usually difficult to remove correctly, wrong noise points exist, the distribution of light spots is changed, the extraction precision of the light spot center is affected, and deviation of point cloud reconstruction is easily caused. Disclosure of Invention The invention has the advantages that the line structure light filtering method, the robot obstacle avoidance method and the robot are provided, interference can be filtered out in a strong light environment and during rapid movement, and the accuracy of point cloud reconstruction is improved. Another advantage of the present invention is to provide a line structured light filtering method, a robot obstacle avoidance method, and a robot, where in one embodiment of the present invention, the line structured light filtering method is capable of filtering out static noise spots in a strong light environment, and also capable of filtering out dynamic noise spots caused by the straight movement or rotation of the robot in a strong light environment, while retaining an effective point cloud, and avoiding erroneous filtering. Another advantage of the present invention is to provide a line structured light filtering method, a robot obstacle avoidance method, and a robot, where in one embodiment of the present invention, the robot obstacle avoidance method can ensure that the robot is not subject to problems such as deceleration and pause, and idle winding caused by influence of ambient light during a motion obstacle avoidance process. Another advantage of the present invention is to provide a line structured light filtering method, a robot obstacle avoidance method, and a robot, in which complicated structures and designs are not required in the present invention in order to achieve the above objects. Therefore, the invention successfully and effectively provides a solution, which not only provides a simple line structure optical filtering method, a robot obstacle avoidance method and a robot, but also increases the practicability and reliability of the line structure optical filtering method, the robot obstacle avoidance method and the robot. To achieve at least one of the above advantages and other advantages and objects of the present invention, the present invention provides a line structured light filtering method comprising the steps of: respectively acquiring images acquired by a line structured light camera when laser is turned on or turned off so as to correspondingly acquire a target image and a background image; extracting spot centers in the target image and the background image respectively to obtain a candidate point set and a corrosion point set, respectively, and And carrying out neighborhood filtering on each candidate point of the candidate point set based on the corrosion points of the corrosion point set to obtain a filtered spot point set. According to one embodiment of the present application, the step of neighborhood filtering each candidate point of the candidate point set based on the corrosion point of the corrosion point set to obtain a filtered flare point set includes the steps of: determining a neighborhood filtering range for each candidate point in the set of candidate points, and Judging whether each candidate point of the candidate point set is similar to the corrosion point of the corrosion point set in the corresponding neighborhood filtering range, if so, filtering the candidate point, and if not, reserving the candidate point. According to one embodiment of the present application, the step