A method for extracting light spots, a ranging method, a lidar, and a robot

By drawing the position-light intensity curve in lidar, screening and evaluating the spot brightness and width, the problem of spot extraction is solved, and accurate ranging is achieved in complex environments.

CN115524683BActive Publication Date: 2025-07-04SHENZHEN CAMSENSE TECHNOLOGIES CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211143032.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-20
Publication Date
2025-07-04
Estimated Expiration
2042-09-20

AI Technical Summary

Technical Problem

Existing lidars are unstable in complex environments and are susceptible to multipath and spot splitting problems, resulting in distance measurement errors, especially when the surfaces of high and low reflective materials are not robust.

Method used

By collecting the photosensitive information on the lidar photosensitive sheet, drawing the position-light intensity curve, determining the candidate spot, and scoring the brightness and width, a stable target spot is selected, and the noise is processed using Gaussian filtering and smooth filtering, the spot center of mass is calculated based on the big data mapping relationship, and the influence of multipath and spot splitting is eliminated.

Benefits of technology

It improves the stability and robustness of spot extraction, and can accurately extract the center of mass of spots in complex scenarios to achieve stable distance measurement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115524683B_ABST
    Figure CN115524683B_ABST
Patent Text Reader

Abstract

Embodiments of the present invention relate to the technical field of lidar, and disclose a spot extraction method, a ranging method, a lidar and a robot. The spot extraction method first collects the photosensitive information on the photosensitive film of the lidar and draws a position-intensity curve, then determines candidate spots through the position-intensity curve, and finally scores the brightness and width of the candidate spots, and determines and extracts the target spot according to the scoring result. This spot extraction method can solve the problems of multiple spots formed by multipath and spot splitting, and has strong stability and robustness. Furthermore, when the lidar ranges, it can effectively and stably extract the centroid of the spot, and realize ranging in complex scenarios.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present invention relate to the technical field of lidar, and in particular, to a method for spot extraction, a ranging method, a lidar, and a robot. Background Art

[0002] Lidar (Laser Radar) can be used to measure the distance to a target and is widely used in robots. The point cloud information generated by lidar contains information such as angle, distance, and brightness. In actual application scenarios, objects may exist at both near and far distances, and the objects have different materials with high and low reflectivity. Usually, the triangulation ranging method of lidar is used to measure the distance by receiving the spot emitted by the transmitter. The position offset of the spot on the sensor in the receiver determines the distance of the target object.

[0003] In the process of implementing the embodiments of the present invention, the inventors found that at least the following problems exist in the above related technologies: During the ranging process, due to the complexity of the environment, the spot will be affected by various environmental conditions, such as multipath problems, spot splitting problems, etc., which will cause errors in spot extraction, and then lead to problems such as deviations in the detected distance data. The existing method determines the position of the spot by the maximum and minimum slopes of two adjacent points in the light intensity curve, which has low stability and weak robustness for special materials such as high and low reflectivity. Summary of the Invention

[0004] Embodiments of the present application provide a method for spot extraction, a ranging method, a lidar, and a robot.

[0005] The objectives of the embodiments of the present invention are achieved through the following technical solutions:

[0006] To solve the above technical problems, in a first aspect, an embodiment of the present invention provides a method for spot extraction, the method including: collecting the photosensitive information on the photosensitive film of the lidar and drawing a position-light intensity curve; determining candidate spots through the position-light intensity curve; scoring the brightness and width of the candidate spots, and determining and extracting a target spot according to the scoring result.

[0007] In some embodiments, the scoring the brightness and width of the candidate spots, and determining and extracting a target spot according to the scoring result includes: calculating the brightness score of each candidate spot based on the position-light intensity curve; calculating the width score of each candidate spot based on the position-light intensity curve; determining the candidate spot with the highest comprehensive evaluation based on the brightness score and the width score, and taking it as the target spot; extracting the target spot.

[0008] In some embodiments, calculating the width score of each candidate light spot based on the position-light intensity curve includes: establishing a mapping relationship between the centroid of the light spot and the theoretical width through big data; obtaining the theoretical width of each candidate light spot according to the mapping relationship; determining the actual width of each candidate light spot based on the position-light intensity curve; respectively calculating the deviation between the theoretical width and the actual width of each candidate light spot; and calculating the width score of each candidate light spot based on the deviation.

[0009] In some embodiments, determining candidate light spots through the position-light intensity curve includes: counting the light intensity value with the most occurrences and the highest light intensity value in the position-light intensity curve; determining whether the difference between the light intensity value with the most occurrences and the highest light intensity value is greater than or equal to a preset difference threshold; if so, calculating a light intensity target value according to the light intensity value with the most occurrences and the highest light intensity value; obtaining the position data corresponding to the light intensity target value on the position-light intensity curve, and determining the candidate light spot according to the position data.

[0010] In some embodiments, the method further includes: when the difference between the light intensity value with the most occurrences and the highest light intensity value is less than the preset difference threshold, determining that there is no extractable light spot.

[0011] In some embodiments, the method further includes: obtaining the minimum light intensity value within the range between the two closest boundaries of two adjacent candidate light spots from the position-light intensity curve; determining whether the difference between the minimum light intensity value and the light intensity value with the most occurrences is less than a preset splitting threshold; if so, determining that there is no extractable light spot.

[0012] In some embodiments, before counting the light intensity value with the most occurrences and the highest light intensity value in the position-light intensity curve, the method further includes: performing a filtering process on the position-light intensity curve; the performing a filtering process on the position-light intensity curve includes: performing an n-order Gaussian filtering on the position-light intensity curve; and performing a smoothing filtering on the position-light intensity curve after Gaussian filtering.

[0013] To solve the above technical problems, in a second aspect, an embodiment of the present invention provides a ranging method applied to a lidar. The method includes: extracting a target light spot according to the light spot extraction method described in the first aspect; obtaining the centroid of the target light spot; and calculating the distance information between the target object and the lidar according to the centroid of the target light spot.

[0014] To solve the above technical problems, in a third aspect, an embodiment of the present invention provides a lidar, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein, the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method described in the first aspect or the second aspect above.

[0015] To solve the above technical problems, in a fourth aspect, an embodiment of the present invention further provides a robot, including the lidar described in the third aspect.

[0016] Compared with the prior art, the beneficial effects of the present invention are: different from the prior art, an embodiment of the present invention provides a spot extraction method, a ranging method, a lidar and a robot. The spot extraction method first collects the photosensitive information on the photosensitive film of the lidar and draws a position-light intensity curve, then determines candidate spots through the position-light intensity curve, and finally scores the brightness and width of the candidate spots, and determines and extracts the target spot according to the scoring result. This spot extraction method can solve the problems of multiple spots formed by multipath and spot splitting, and has strong stability and robustness. Furthermore, when the lidar ranges, it can effectively and stably extract the centroid of the spot to achieve ranging in complex scenarios. Description of the Drawings

[0017] In one or more embodiments, exemplary illustrations are provided through the pictures in the corresponding drawings. These exemplary illustrations do not constitute limitations on the embodiments. Elements / modules and steps with the same reference numerals in the drawings are represented as similar elements / modules and steps. Unless otherwise stated, the drawings in the figures do not constitute a scale limitation.

[0018] Figure 1 is a schematic diagram of one application environment of the spot extraction method and the ranging method provided by an embodiment of the present invention;

[0019] Figure 2 is a schematic flowchart of a spot extraction method provided by Embodiment 1 of the present invention;

[0020] Figure 3 is an example diagram of a position-light intensity curve with a single spot;

[0021] Figure 4 is Figure 2 a sub-flowchart of step S20 in the shown spot extraction method;

[0022] Figure 5 is Figure 2 another sub-flowchart of step S20 in the shown spot extraction method;

[0023] Figure 6 It is an example diagram of a position-light intensity curve with multiple (two) split light spots;

[0024] Figure 7 is Figure 2 a sub-process schematic diagram of step S30 in the light spot extraction method shown;

[0025] Figure 8 is Figure 7 a sub-process schematic diagram of step S32 in the light spot extraction method shown;

[0026] Figure 9 It is an example diagram of a position-light intensity curve with multiple (two) extractable light spots;

[0027] Figure 10 It is a schematic flowchart of a ranging method provided in the second embodiment of the present invention;

[0028] Figure 11 It is a schematic structural diagram of a light spot extraction device provided in the third embodiment of the present invention;

[0029] Figure 12 It is a schematic structural diagram of a ranging device provided in the fourth embodiment of the present invention;

[0030] Figure 13 It is a schematic hardware structure diagram of a lidar provided in the fifth embodiment of the present invention;

[0031] Figure 14 It is a schematic structural diagram of a robot provided in the sixth embodiment of the present invention. Detailed implementation manners

[0032] The present invention will be described in detail below in conjunction with specific embodiments. The following embodiments will help those skilled in the art to further understand the present invention, but do not limit the present invention in any form. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present invention, several deformations and improvements can still be made. These all belong to the protection scope of the present invention.

[0033] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0034] It should be noted that, without conflict, the features in the embodiments of the present invention can be combined with each other, and all are within the protection scope of this application. In addition, although functional modules are divided in the device schematic diagram and the logical sequence is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order from the module division in the device or the flowchart.

[0035] Unless otherwise defined, all technical and scientific terms used in this specification have the same meaning as commonly understood by those skilled in the technical field to which the present invention belongs. The terms used in this specification in the description of the present invention are only for the purpose of describing specific embodiments and are not applicable to limiting the present invention. The term "and / or" used in this specification includes any and all combinations of one or more of the related listed items. The terms "horizontal" coordinate, "vertical" coordinate, "left" boundary, "right" boundary and similar expressions used in this specification are only for the purpose of illustration.

[0036] In addition, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0037] When the current lidar measures distance, in a relatively complex scenario, the light spot will be affected by various environmental conditions, resulting in various problems that will cause errors in light spot extraction and thus cause ranging deviation. For example, the multipath problem, that is, the light spot is reflected from one object to another object, so that the receiver obtains light spots on two or more objects. Another example is the light spot splitting problem, that is, the light spot is split by the support column of the lidar cover when it is close or the light spot is split into two at the edge of the object. In some point clouds with normal ranging, such point clouds seem abnormal and will have a great impact on subsequent mapping. At the same time, the existing method determines the position of the center of gravity of the light spot in the camera sensor by the maximum and minimum slopes of two adjacent points in the light intensity curve. For the performance of special materials such as high and low reflectivity, the stability is not high, the robustness is not strong, and it is also impossible to make decisions on the problems of multiple light spots formed by the above-mentioned multipath and light spot splitting.

[0038] To solve the above problems, the embodiments of the present invention provide a light spot extraction method, a ranging method, a lidar and a robot. The light spot extraction method determines the left and right boundaries of each light spot through the position-light intensity curve of each light spot, excludes and filters out the multipath light spots through the limitation of the left and right boundaries, and then extracts stable and accurate target light spots through the comprehensive evaluation of the position data and light intensity data of each light spot within the range limited by the left and right boundaries.

[0039] Figure 1Schematic diagram of an application environment of the spot extraction method and the ranging method provided by an embodiment of the present invention. The application environment includes a lidar 10 and an object A. Among them, the lidar 10 can emit a laser beam and collect, through a sensor in the camera, the laser spot formed by the laser beam reflected by the object A, and output data such as the position and light intensity of the spot. Both the spot extraction method and the ranging method provided by the embodiments of the present invention are executed by the lidar 10. The object A is an object that can reflect the laser beam output by the lidar 10, that is, Figure 1 the target object to be ranged by the lidar 10 in the application scenario shown.

[0040] Specifically, the embodiments of the present invention will be further described below with reference to the accompanying drawings.

[0041] Embodiment 1

[0042] The embodiment of the present invention provides a spot extraction method, which is applied to a lidar. The lidar may be the lidar 10 as shown in the above application scenario and Figure 1 shown. Please refer to Figure 2 , which shows the flow of a spot extraction method provided by an embodiment of the present invention. The method includes but is not limited to the following steps:

[0043] Step S10: Collect the photosensitive information on the photosensitive film of the lidar and draw a position-light intensity curve;

[0044] In the embodiment of the present invention, first, after the spot hits the lidar, on the camera sensor of the lidar, different pixel points represent different positions. Whether each pixel point receives the laser and the different number of photons received will also result in different light intensity data collected by each pixel point. The light intensity of several pixel points that receive the spot is relatively high, while the light intensity of pixel points that do not receive the spot is relatively low. At this time, the photosensitive information on the photosensitive film of the camera sensor, that is, the positions of each row of pixel points and the corresponding light intensity data, can be exported, so that the position parameters of at least one row of pixel points on the photosensitive film and the light intensity parameters corresponding to the pixel points are automatically drawn through a drawing software and the position-light intensity curve is exported.

[0045] Please refer to Figure 3, which shows an example of a position-light intensity curve with a single light spot provided by an embodiment of the invention. Herein, the abscissa represents the position data of the pixel points where the light spot falls on the photosensitive film of the camera sensor, and the ordinate represents the light intensity data of the received light. In the example shown in FIG. 3, the position-light intensity curve is plotted by extracting the position data and light intensity data of the four brightest rows of pixel points among the pixel points with light spots on the photosensitive film, and the position data and light intensity data obtained by projecting and accumulating the position data and light intensity data of the four rows of pixel points column by column into one row of pixel points are used as the values of the abscissa and ordinate for plotting the position-light intensity curve. Optionally, it can also be that the data of the four rows of pixel points are averaged column by column and then assigned to one row of pixel points. Optionally, the number of rows of pixel points selected can also be other integers greater than or equal to 1. In the embodiment of the present invention, selecting an appropriate number of rows of pixel points to replace the entire light spot to export data can improve the frame rate of the lidar, reduce the resources for algorithm processing, and thus speed up the processing speed. And, in Figure 3 the shown example, the advantage of selecting four rows of pixel points compared to other numbers of rows of pixel points is that it has better stability compared to the case of less than four rows, and has a higher frame rate and faster processing speed compared to the case of more than four rows. Therefore, the Figure 3 and the following other position-light intensity curves all take the four brightest rows of pixel points as an example.

[0046] Step S20: Determine candidate light spots through the position-light intensity curve;

[0047] In the embodiment of the present invention, after obtaining the position-light intensity curve, by combining the change situation of the light intensity data on the position-light intensity curve, one or more candidate light spots that may be the target light spot can be first screened out, and then the candidate light spots are further screened to extract the target light spot that can be used to extract the centroid. Specifically, please refer to Figure 4 , which shows a sub-process of step S20 in the light spot extraction method provided by the embodiment of the present invention. The determining candidate light spots through the position-light intensity curve includes: Figure 2 Step S21: Perform filtering processing on the position-light intensity curve;

[0048]

[0049] ​Specifically, the filtering process includes Gaussian filtering and smoothing filtering. That is, the filtering process for the position-light intensity curve includes: performing nth-order Gaussian filtering on the position-light intensity curve; performing smoothing filtering on the position-light intensity curve after Gaussian filtering. Among them, performing the Gaussian filtering can suppress the high-frequency data points of the position-light intensity curve and remove noise, and n can take 5, 7, 9. Performing the smoothing filtering can make the curve smoother, which is beneficial to the subsequent selection of the left and right boundaries. And, the specific method of the smoothing filtering is to take the average value of every consecutive m points on the curve, where m can take 3, 4, 5.

[0050] Step S22: Count the light intensity value that appears most frequently and the highest light intensity value in the position-light intensity curve;

[0051] After filtering the position-light intensity curve, count all the light intensity data on the curve, that is, Figure 3 the number of occurrences and the highest value of each ordinate value shown, so as to obtain the light intensity value MostValue that appears most frequently and the highest light intensity value MaxValue in the position-light intensity curve.

[0052] Step S23: Determine whether the difference between the light intensity value that appears most frequently and the highest light intensity value is greater than or equal to a preset difference threshold; if so, jump to step S24; if not, jump to step S26;

[0053] After obtaining the light intensity value MostValue that appears most frequently and the highest light intensity value MaxValue, calculate the difference between the two. And, since usually the highest light intensity value MaxValue is greater than the light intensity value MostValue that appears most frequently, therefore, the difference is MaxValue - MostValue. After obtaining the difference, determine whether the difference is greater than or equal to the preset difference threshold. If so, there may be an extractable light spot, and jump to step S24 for further calculation. Among them, the preset difference threshold can be set according to the accuracy of the sensor, the background brightness of the application scenario, the laser brightness emitted by the lidar, etc.

[0054] Step S24: Calculate the light intensity target value according to the light intensity value that appears most frequently and the highest light intensity value;

[0055] When the difference between the light intensity value that appears most frequently and the highest light intensity value is greater than or equal to the preset difference threshold, there may be an extractable light spot. At this time, further, calculate the light intensity target value through the following formula:

[0056] TargetValue = MostValue + a * (MaxValue - MostValue)

[0057] Wherein, a is a coefficient factor determined by experimental data, TargetValue represents the target light intensity value, MostValue represents the light intensity value with the most occurrences, and MaxValue represents the highest light intensity value.

[0058] Step S25: Obtain the position data corresponding to the target light intensity value on the position-light intensity curve, and determine the candidate light spot according to the position data.

[0059] After calculating the target light intensity value, the corresponding position data of the target light intensity value on the position-light intensity curve can be found, so as to obtain the candidate light spot according to the defined range of the position data. For example, please continue to refer to Figure 3 , after calculating the target light intensity value, after finding the target light intensity value on the vertical coordinate representing the light intensity, draw an auxiliary line L1 perpendicular to the vertical coordinate and parallel to the horizontal coordinate. The two intersection points a and b of the auxiliary line L1 and the position-light intensity curve can be used as the left and right boundaries of the light spot respectively, and the abscissas of the corresponding points a and b are the position data of the left boundary and the right boundary respectively.

[0060] Step S26: Determine that there is no extractable light spot.

[0061] When the difference between the light intensity value with the most occurrences and the highest light intensity value is less than the preset difference threshold, it means that there is no extractable light spot at this time, and the process of light spot extraction is ended.

[0062] Furthermore, in some embodiments, please refer to Figure 1 together. When the laser hits object A, it may also hit the edge of object A, resulting in the splitting of the light spot into two light spots. Therefore, the embodiment of the present invention also provides a method for screening and filtering out the split light spot situation. Please refer to Figure 5 , which shows another sub-process of step S20 in the light spot extraction method provided by the embodiment of the present invention. The method further includes: Figure 2 Step S27: Obtain the minimum light intensity value within the range between the two closest boundaries of adjacent two candidate light spots from the position-light intensity curve;

[0063] Step S28: Judge whether the difference between the minimum light intensity value and the light intensity value with the most occurrences is less than the preset splitting threshold; if so, jump to step S26.

[0064] Please refer to

[0065] together. Figure 6, which shows an example of a position-light intensity curve of a plurality of (two) split light spots provided by the invention embodiment, and Figure 3 Similarly, the abscissa represents the position data of the pixel points where the light spots fall on the photosensitive film of the camera sensor, and the ordinate represents the light intensity data of the received light. As Figure 6 It is not difficult to see that the two split light spots are independent and generated from the bottom line. Neither of the two light spots can accurately represent the accurate distance information of the object. At this time, it is determined that there is no extractable light spot.

[0066] Specifically, obtain the minimum light intensity value within the range between the two closest boundaries of two adjacent candidate light spots. As Figure 6 shown, it is the light intensity data corresponding to all position data within the range between the right boundary of the left light spot and the left boundary of the right light spot. Then, take the minimum light intensity value MinValue of these light intensity data, and calculate the difference between the minimum light intensity value MinValue and the most frequently occurring light intensity value MostValue. Among them, since the two split light spots are independent light spots generated from the bottom line, the minimum light intensity value MinValue is usually the value of the bottom line, and the bottom line is generated due to the background brightness in the application scenario. Preferably, since the most frequently occurring light intensity value MostValue is usually greater than the minimum light intensity value MinValue, the difference is MostValue - MinValue. After obtaining the difference, determine whether the difference is less than the preset split threshold. If so, it is considered that two split and independent light spots are generated, and it is determined that there is no extractable light spot. Among them, the preset split threshold can be set according to the accuracy of the sensor, the background brightness of the application scenario, the laser brightness emitted by the lidar, etc.

[0067] Step S30: Score the brightness and width of the candidate light spots, and determine and extract the target light spot according to the scoring result.

[0068] In the invention embodiment, after obtaining the candidate light spots, the light spot with the highest comprehensive evaluation among the candidate light spots can be extracted according to the position data and light intensity data of the candidate light spots, as the target light spot for further extracting the centroid and performing distance measurement. Among them, when Figure 3 shown, there is only one light spot on the position-light intensity curve, then the comprehensive evaluation of the light spot does not need to be calculated, and this light spot can be output as the target light spot.

[0069] When there are multiple light spots, such as two light spots, and they are not split and independent as Figure 6 shown, then it is necessary to calculate the comprehensive evaluation of the light spots to extract the light spot with the highest comprehensive evaluation as the target light spot for distance measurement. Specifically, please refer to Figure 7 , which shows what is provided by the invention embodimentFigure 2 A sub - process of step S30 in the spot extraction method shown, which scores the brightness and width of the candidate spots and determines and extracts the target spot according to the scoring results, includes:

[0070] Step S31: Calculate the brightness score of each candidate spot based on the position - light intensity curve;

[0071] Specifically, according to the position data and light intensity data within the left and right boundaries of each candidate spot, the centroid and brightness of each spot are obtained, and combined with Figure 3 As can be seen, when obtaining the centroid of the candidate spot, the centroid of the spot can be obtained through the position data between the left boundary a and the right boundary b, that is, the abscissa value, and the light intensity data corresponding to each position between the left boundary a and the right boundary b, that is, the ordinate value. And the calculation formula is as follows:

[0072]

[0073] Among them, cx represents the centroid of the spot, ∑ i x i is the sum of the abscissas of each point in the interval defined by the left boundary a and the right boundary b, ∑ i y i *x i is the sum of the products of the abscissas and the corresponding ordinates, that is, the light intensity data, of each point in the interval defined by the left boundary a and the right boundary b.

[0074] Furthermore, the brightness of the candidate spot can be calculated. The calculation formula for the brightness of the spot is as follows:

[0075]

[0076] Among them, ∑ i y i is the sum of the ordinates, that is, the light intensity data, of each point in the range of the position - light intensity curve defined by the left boundary a and the right boundary b. The ordinate x b -x a +1 is the position width in the interval defined by the left boundary a and the right boundary b, that is, the actual width of the spot.

[0077] In the embodiment of the present invention, the greater the brightness of the candidate spot, the higher the brightness score.

[0078] Step S32: Calculate the width score of each candidate spot based on the position - light intensity curve;

[0079] When calculating the width score of the candidate spot, the theoretical width needs to be obtained through big data first, and then further calculation is carried out in combination with the centroid and actual width of the spot obtained in step S31. Specifically, please refer to Figure 8, which shows Figure 7 a sub - process of step S32 in the spot extraction method shown, calculating the width score of each candidate spot based on the position - light intensity curve, includes:

[0080] Step S321: Establish a mapping relationship between the centroid of the spot and the theoretical width through big data;

[0081] First, it is necessary to establish the relationship between the centroid of the spot and the theoretical width through a large amount of data, and the relationship is as follows:

[0082] depth = α * cx + β

[0083] Where α is the coefficient factor, β is the bias, cx is the centroid of the spot, and depth is the theoretical width in the interval defined by the left and right boundaries.

[0084] When writing the above formula for the relationship between the centroid of the spot and the theoretical width in matrix form, the following formula can be obtained:

[0085]

[0086] Substitute a large number of cx and depth values in the experimental data into the above matrix, and solve the over - determined equation by the least - squares method to obtain the specific values of the parameters α and β.

[0087] Step S322: Obtain the theoretical width of each candidate spot according to the mapping relationship;

[0088] Then, substitute the centroid of the candidate spot obtained in step S31 into the relationship or matrix obtained in step S321 to obtain the theoretical width corresponding to the centroid of one or more spots.

[0089] Step S323: Determine the actual width of each candidate spot based on the position - light intensity curve;

[0090] Next, the actual width of each candidate spot can also be obtained through the Figure 3 shown position - light intensity curve. The value of the actual width is the numerical value of the position width defined by the left and right boundaries of the candidate spot. When calculating for the Figure 3 shown example spot, the actual width is the width x in the interval defined by the left boundary a and the right boundary b calculated in step S31 b -x a +1.

[0091] Step S324: Calculate the deviation between the theoretical width and the actual width of each candidate spot respectively;

[0092] Then, for each light spot, calculate the deviation between the theoretical width and the actual width of each light spot respectively. If the theoretical width and the actual width are closer, the deviation is smaller; if the theoretical width and the actual width are less close, the deviation is larger.

[0093] Step S325: Calculate the width score of each candidate light spot based on the deviation.

[0094] Finally, the light spot with the smallest deviation is the light spot closest to the theoretical width. At this time, the light spot with the smallest deviation is used as the light spot with the highest width score. That is, the size of the deviation is inversely correlated with the width score.

[0095] Step S33: Based on the brightness score and the width score, determine the candidate light spot with the highest comprehensive evaluation, and use it as the target light spot.

[0096] Please also refer to Figure 9 , which shows an example of a position-light intensity curve diagram of an invention embodiment with multiple (two) extractable light spots. When it is different from Figure 3 shown where there are multiple extractable light spots, such as Figure 9 shown where there are two light spots, there will be light spots obtained by the left and right boundary restrictions of the three combinations of (p1, p2), (p3, p4), and (p1, p4). For the light spots obtained by these three restrictions, it is necessary to calculate the light spot with the highest brightness score and the light spot with the highest width score among them through step S32, and then assign weights and sum the brightness score and the width score respectively to select the light spot with the highest score, which is the target light spot available for distance measurement. Obviously, in Figure 9 the example shown, the light spot with the highest comprehensive evaluation is the light spot defined by the boundary (p3, p4) on the right.

[0097] Step S34: Extract the target light spot.

[0098] After determining the target light spot, output data such as the centroid of the light spot, the width of the light spot, and the position of the light spot of the target light spot to achieve the extraction of the target light spot. The extracted target light spot can be used to further calculate the distance of the target object.

[0099] Embodiment 2

[0100] An embodiment of the present invention provides a ranging method, which is applied to a lidar. The lidar may be the lidar 10 as shown in the above application scenario and Figure 1 shown. Please refer to Figure 10 , which shows the process of a ranging method provided by an embodiment of the present invention. The method includes but is not limited to the following steps:

[0101] Step S1: Extract the target light spot according to the light spot extraction method described in Embodiment 1;

[0102] Step S2: Obtain the centroid of the target light spot;

[0103] Step S3: Calculate the distance information between the target object and the lidar according to the centroid of the target light spot.

[0104] In the embodiment of the present invention, a target light spot that accurately retains the distance information of the object to be measured can be extracted by the light spot extraction method described in Embodiment 1. Then, the centroid of the target light spot can be obtained by the formula shown in Step S31. Finally, according to the centroid of the target light spot, the distance information between the target object and the lidar is calculated. The calculation formula of the distance information is as follows:

[0105] d = n1 / (n2 - cx)

[0106] Where n1 and n2 are ranging parameters that can be obtained by the lidar through calibration, cx represents the centroid of the light spot, and d represents the distance.

[0107] In the embodiment of the present invention, an accurate target light spot is extracted by the light spot extraction method provided in Embodiment 1, so as to obtain a reliable centroid cx of the light spot, and then the accurate distance d of the target object can be calculated. Among them, for the specific light spot extraction method, please refer to Embodiment 1 and the appendix Figure 2 to the appendix Figure 9 described above, and details are not described herein again.

[0108] Embodiment 3

[0109] The embodiment of the present invention provides a light spot extraction device, which is applied to a lidar. The lidar can be the lidar 10 as described in the above application scenario and Figure 1 shown. Please refer to Figure 11 , which shows the structure of a light spot extraction device provided by the embodiment of the present invention. The light spot extraction device 100 includes: a collection unit 110, a determination unit 120, and an extraction unit 130.

[0110] The collection unit 110 is configured to collect the photosensitive information on the photosensitive film of the lidar and draw a position-light intensity curve; the determination unit 120 is configured to determine candidate light spots through the position-light intensity curve; the extraction unit 130 is configured to score the brightness and width of the candidate light spots, and determine and extract the target light spot according to the scoring result.

[0111] In some embodiments, the determining unit 120 is further configured to count the light intensity value that appears most frequently and the highest light intensity value in the position-light intensity curve; determine whether the difference between the light intensity value that appears most frequently and the highest light intensity value is greater than or equal to a preset difference threshold; if so, calculate a light intensity target value according to the light intensity value that appears most frequently and the highest light intensity value; obtain the position data corresponding to the light intensity target value on the position-light intensity curve, and determine the candidate light spot according to the position data.

[0112] In some embodiments, when the difference between the light intensity value that appears most frequently and the highest light intensity value is less than the preset difference threshold, the determining unit 120 is further configured to determine that there is no extractable light spot.

[0113] In some embodiments, the determining unit 120 is further configured to obtain the minimum light intensity value within the range between the two closest boundaries of two adjacent candidate light spots from the position-light intensity curve; determine whether the difference between the minimum light intensity value and the light intensity value that appears most frequently is less than a preset splitting threshold; if so, determine that there is no extractable light spot.

[0114] In some embodiments, the determining unit 120 is further configured to perform a filtering process on the position-light intensity curve. Specifically, the determining unit 120 is configured to perform an n-order Gaussian filtering on the position-light intensity curve; perform a smoothing filtering on the position-light intensity curve after Gaussian filtering.

[0115] In some embodiments, the extracting unit 130 is further configured to calculate a brightness score for each candidate light spot based on the position-light intensity curve; calculate a width score for each candidate light spot based on the position-light intensity curve; determine the candidate light spot with the highest comprehensive evaluation based on the brightness score and the width score, and use it as the target light spot; extract the target light spot.

[0116] In some embodiments, the extracting unit 130 is further configured to establish a mapping relationship between the centroid and the theoretical width of the light spot through big data; obtain the theoretical width of each candidate light spot according to the mapping relationship; determine the actual width of each candidate light spot based on the position-light intensity curve; calculate the deviation between the theoretical width and the actual width of each candidate light spot respectively; calculate the width score for each candidate light spot based on the deviation.

[0117] Embodiment 4

[0118] An embodiment of the present invention provides a ranging device, which is applied to a lidar. The lidar may be the lidar 10 as described in the above application scenario and Figure 1 as shown. Please refer to Figure 12, which shows the structure of a ranging device provided by an embodiment of the present invention. The ranging device 200 includes: an extraction module 210, an acquisition module 220, and a calculation module 230.

[0119] The extraction module 210 is configured to extract a target light spot according to a light spot extraction method. The extraction module 210 may include the light spot extraction device 100 shown in Embodiment 4 and Figure 11 specifically may include the extraction unit 130 in the light spot extraction device 100, which will not be elaborated here.

[0120] The acquisition module 220 is configured to acquire the centroid of the target light spot.

[0121] The calculation module 230 is configured to calculate the distance information between the target object and the lidar according to the centroid of the target light spot.

[0122] Embodiment 5

[0123] An embodiment of the present invention further provides a lidar. Please refer to Figure 13 , which shows the hardware structure of a lidar capable of executing Figures 2 to 9 the above-mentioned light spot extraction method and / or executing Figure 10 the above-mentioned ranging method. The lidar 10 may be Figure 1 the lidar 10 shown.

[0124] The lidar 10 includes: at least one processor 11; and a memory 12 communicatively connected to the at least one processor 11. Figure 13 Taking one processor 11 as an example. The memory 12 stores instructions executable by the at least one processor 11. The instructions are executed by the at least one processor 11 so that the at least one processor 11 can execute the above-mentioned Figures 2 to 9 light spot extraction method and / or execute the above-mentioned Figure 10 ranging method. The processor 11 and the memory 12 may be connected by a bus or other means. Figure 13 Taking connection by bus as an example.

[0125] The memory 12, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as program instructions / modules corresponding to the light spot extraction method or ranging method in the embodiments of the present application. For example, Figures 11 to 12 each module shown. The processor 11 executes various functional applications and data processing of the server by running the non-volatile software programs, instructions, and modules stored in the memory 12, that is, implements the light spot extraction method or ranging method in the above method embodiments.

[0126] The memory 12 may include a program storage area and a data storage area. The program storage area may store an operating system and application programs required for at least one function. The data storage area may store data created according to the use of the light spot extraction device or the ranging device, etc. In addition, the memory 12 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other non-volatile solid-state storage devices. In some embodiments, the memory 12 may optionally include a memory remotely provided with respect to the processor 11, and these remote memories may be connected to the light spot extraction device or the ranging device through a network. Examples of the above network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0127] The one or more modules are stored in the memory 12 and, when executed by the one or more processors 11, execute the light spot extraction method or the ranging method in any of the above method embodiments. For example, execute the Figures 2 to 10 method steps described above to implement the functions of each module and each unit in FIGS. 11 to Figure 12 .

[0128] The above product can execute the method provided in the embodiments of the present application, and has corresponding functional modules and beneficial effects for executing the method. For technical details not described in detail in this embodiment, reference may be made to the method provided in the embodiments of the present application.

[0129] The embodiments of the present application also provide a non-volatile computer-readable storage medium storing computer-executable instructions, and the computer-executable instructions are executed by one or more processors. For example, execute the Figures 2 to 10 method steps described above to implement the functions of each module in Figures 11 to 12 .

[0130] The embodiments of the present application also provide a computer program product including a computing program stored on a non-volatile computer-readable storage medium. The computer program includes program instructions, and when the program instructions are executed by a computer, the computer executes the light spot extraction method or the ranging method in any of the above method embodiments. For example, execute the Figures 2 to 10 method steps described above to implement the functions of each module in Figures 11 to 12 .

[0131] Embodiment Six

[0132] The embodiments of the present invention provide a robot. Please refer to Figure 14 , which shows a structural block diagram of a robot provided in the embodiments of the present invention. The robot 1 includes a lidar 10.

[0133] The lidar 10 is the lidar 10 described in Embodiment 5. For details, please refer to Embodiment 5, the application scenario, and the appendix Figure 1 and the appendix Figure 13 as shown, which will not be elaborated here

[0134] The robot 1 can be an industrial and service robot such as a floor-sweeping robot, a navigation robot, a mapping robot, etc. Specifically, the robot loaded with the lidar 10 can be selected according to the actual application scenario

[0135] In an embodiment of the present invention, a spot extraction method, a ranging method, a lidar, and a robot are provided. The spot extraction method first collects the photosensitive information on the photosensitive film of the lidar and draws a position-light intensity curve, then determines candidate spots through the position-light intensity curve, and finally scores the brightness and width of the candidate spots, and determines and extracts the target spot according to the scoring result. This spot extraction method can solve the problems of multiple spots formed by multipath and spot splitting, and has strong stability and robustness. Furthermore, when the lidar ranges, it can effectively and stably extract the centroid of the spot, realizing ranging in complex scenarios

[0136] It should be noted that the device embodiments described above are only illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment

[0137] Through the description of the above embodiments, those of ordinary skill in the art can clearly understand that each embodiment can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware. Those of ordinary skill in the art can understand that all or part of the processes in the above method embodiments can be completed by instructing relevant hardware through a computer program. The program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the above method embodiments. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM), etc

[0138] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; under the idea of the present invention, the technical features in the above embodiments or different embodiments can also be combined, and the steps can be implemented in any order, and there are many other changes in different aspects of the present invention as described above. For the sake of brevity, they are not provided in detail; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for extracting light spots, characterized in that, The method includes: Collecting the photosensitive information on the photosensitive film of the lidar and drawing a position-intensity curve; Determining candidate light spots through the position-intensity curve; Scoring the brightness and width of the candidate light spots, and determining and extracting the target light spot according to the scoring results.

2. The spot extraction method according to claim 1, wherein The scoring the brightness and width of the candidate light spots and determining and extracting the target light spot according to the scoring results includes: Calculating the brightness score of each candidate light spot based on the position-intensity curve; Calculating the width score of each candidate light spot based on the position-intensity curve; Based on the brightness score and the width score, determining the candidate light spot with the highest comprehensive evaluation and taking it as the target light spot; Extracting the target light spot.

3. The spot extraction method according to claim 2, wherein The calculating the width score of each candidate light spot based on the position-intensity curve includes: Establishing a mapping relationship between the centroid of the light spot and the theoretical width through big data; Obtaining the theoretical width of each candidate light spot according to the mapping relationship; Determining the actual width of each candidate light spot based on the position-intensity curve; Calculating the deviation between the theoretical width and the actual width of each candidate light spot respectively; Calculating the width score of each candidate light spot based on the deviation.

4. The spot extraction method according to claim 1, characterized in that The determining candidate light spots through the position-intensity curve includes: Counting the light intensity value with the most occurrences and the highest light intensity value in the position-intensity curve; Judging whether the difference between the light intensity value with the most occurrences and the highest light intensity value is greater than or equal to a preset difference threshold; If so, calculating the light intensity target value according to the light intensity value with the most occurrences and the highest light intensity value; Obtaining the position data corresponding to the light intensity target value on the position-intensity curve, and determining the candidate light spot according to the position data.

5. The spot extraction method according to claim 4, wherein The method further includes: When the difference between the light intensity value with the most occurrences and the highest light intensity value is less than the preset difference threshold, it is determined that there is no extractable light spot.

6. The spot extraction method according to claim 4, wherein The method further includes: Obtaining the minimum light intensity value within the range between the two closest boundaries of two adjacent candidate light spots from the position-intensity curve; Judging whether the difference between the minimum light intensity value and the light intensity value with the most occurrences is less than a preset splitting threshold; If so, it is determined that there is no extractable light spot.

7. The spot extraction method according to claim 4, characterized in that Before counting the light intensity value with the most occurrences and the highest light intensity value in the position-intensity curve, the method further includes: Performing a filtering process on the position-intensity curve; The performing a filtering process on the position-intensity curve includes: Performing an n-order Gaussian filter on the position-intensity curve; Performing a smoothing filter on the position-intensity curve after Gaussian filtering.

8. A ranging method, characterized in that, Applied to a lidar, the method includes: Extracting the target light spot according to the light spot extraction method according to any one of claims 1-7; Obtaining the centroid of the target light spot; Calculating the distance information between the target object and the lidar according to the centroid of the target light spot.

9. A lidar, characterized in that, Includes: At least one processor; And, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method according to any one of claims 1-8.

10. A robot, characterized in that, Comprising a lidar according to claim 9.

Citation Information

Patent Citations

  • Method and device for removing dithering

    CN107870323A

  • Quality judgment method of laser spot

    CN112816187A