Distance measuring method, distance measuring device, vehicle, storage medium and computer program product
By selecting the sampling points covering the rising and falling edges of the echo data and using their parameter values to determine the ranging results, the analysis deterioration problem caused by incomplete data in optical ranging is solved, and higher accuracy and efficiency are achieved.
Patent Information
- Application Number
- CN202510157686.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-11
- Publication Date
- 2025-08-12
AI Technical Summary
The existing optical ranging technology can easily lead to deterioration of the analysis results when data is incomplete, and it is impossible to effectively obtain information such as the reflectivity of the target object, and has high calculation complexity.
By selecting the target sampling points covering the rising and falling edges of the echo data, the parameter values of these sampling points determine the ranging results, and an algorithm with lower computing complexity is used to reduce the computing power requirement.
It improves the ranging accuracy and intensity accuracy, reduces the computational complexity, and improves data processing speed and efficiency.
Smart Images

Figure CN120468804A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of distance measurement technology, and in particular to a distance measurement method, a distance measurement device, a vehicle, a storage medium, and a computer program product. Background Art
[0002] Optical ranging is a technology that uses optical principles to measure the distance between objects. For example, optical ranging can be performed using LiDAR or time-of-flight sensors in smartphones, home appliances, and industrial equipment. However, existing optical ranging methods suffer from incomplete data, which can lead to poor analytical results. Summary of the Invention
[0003] The embodiments of the present application provide a ranging method, a ranging device, a vehicle, a storage medium, and a computer program product, which improve the accuracy of optical ranging to at least partially solve the above-mentioned technical problems.
[0004] To achieve the above-mentioned object, according to a first aspect of the present application, a ranging method is provided, comprising:
[0005] Determining a target sampling point according to the echo data, wherein the target sampling point covers a rising edge and a falling edge of the echo data;
[0006] A distance measurement result is determined based on the parameter value of the target sampling point.
[0007] Optionally, determining a target sampling point according to the echo data includes:
[0008] Sampling the echo data to obtain a plurality of sampling points;
[0009] According to a set threshold, at least three sampling points with adjacent sampling times among the plurality of sampling points are selected as the target sampling points;
[0010] The at least three sampling points cover the rising edge and the falling edge of the echo data.
[0011] Optionally, the step of selecting at least three sampling points with adjacent sampling times among the plurality of sampling points as the target sampling points according to a set threshold comprises:
[0012] Comparing the sampling values of the sampling points with the set thresholds in sequence;
[0013] When a sampling value greater than the set threshold is detected, determining a first sampling point, a second sampling point, and a third sampling point;
[0014] The second sampling point and the third sampling point are two adjacent sampling points whose sampling times are later than the first sampling point.
[0015] Optionally, determining the first sampling point, the second sampling point, and the third sampling point includes:
[0016] Selecting a first candidate sampling point, a second candidate sampling point, and a third candidate sampling point from the sampling values greater than the set threshold, where the second candidate sampling point and the third candidate sampling point are two sampling points whose sampling times are later than the first candidate sampling point;
[0017] If the first candidate sampling point is on the rising edge of the echo data, determining whether the third candidate sampling point is on the falling edge of the echo data;
[0018] If the third candidate sampling point is on a falling edge of the echo data, the first candidate sampling point is determined as the first sampling point, the second candidate sampling point is determined as the second sampling point, and the third candidate sampling point is determined as the third sampling point.
[0019] Optionally, the ranging result includes a distance corresponding to the echo data, and determining the ranging result based on the parameter value of the target sampling point includes:
[0020] determining a target time of the echo data according to a sampling time of the first sampling point, a sampling value of the first sampling point, a sampling value of the second sampling point, a sampling value of the third sampling point, and a set interval time, wherein the interval time between the first sampling point and the second sampling point, and the interval time between the second sampling point and the third sampling point are the set interval time;
[0021] A distance corresponding to the echo data is determined based on the target time.
[0022] Optionally, determining the target time of the echo data according to the sampling time of the first sampling point, the sampling value of the first sampling point, the sampling value of the second sampling point, the sampling value of the third sampling point, and the set interval time includes:
[0023] determining a constant value according to the sampling value of the first sampling point, the sampling value of the second sampling point, and the sampling value of the third sampling point;
[0024] The target time of the echo data is determined according to the constant value, the sampling time of the first sampling point and the set interval time.
[0025] Optionally, the constant value is calculated using the following formula:
[0026]
[0027] Wherein, C is the constant value, y0 is the sampling value of the first sampling point, y1 is the sampling value of the second sampling point, and y2 is the sampling value of the third sampling point.
[0028] Optionally, the target time of the echo data is calculated by the following formula:
[0029]
[0030] Wherein, C is the constant value, μ is the target time of the echo data, t0 is the sampling time of the first sampling point, τ is the set interval time, a is the number of sampling period intervals between the first sampling point and the second sampling point, and b is the number of sampling period intervals between the second sampling point and the third sampling point.
[0031] Optionally, the ranging result further includes an echo intensity of the echo data, and determining the ranging result based on the parameter value of the target sampling point further includes:
[0032] An echo intensity of the echo data is determined based on the target time.
[0033] Optionally, determining the echo intensity of the echo data based on the target time includes:
[0034] determining a double variance of the echo data according to a sampling value of the first sampling point, a sampling value of the second sampling point, a sampling time of the first sampling point, the set interval time, and a target time of the echo data;
[0035] The echo intensity of the echo data is determined according to the twice variance, the sampling time of the first sampling point, the sampling value of the first sampling point, and the target time of the echo data.
[0036] Optionally, the double variance of the echo data is calculated by the following formula:
[0037]
[0038] Among them, 2σ 2 is twice the variance of the echo data, t0 is the sampling time of the first sampling point, a is the number of sampling period intervals between the first sampling point and the second sampling point, τ is the set interval time, y0 is the sampling value of the first sampling point, y1 is the sampling value of the second sampling point, and μ is the target time of the echo data.
[0039] Optionally, the echo intensity of the echo data is calculated using the following formula:
[0040]
[0041] Wherein, A is the echo intensity of the echo data, 2σ 2 is twice the variance of the echo data, μ is the target time of the echo data, t0 is the sampling time of the first sampling point, and y0 is the sampling value of the first sampling point.
[0042] Optionally, the echo data includes first echo data and second echo data, and determining the ranging result based on the parameter value of the target sampling point further includes:
[0043] determining a first target time based on a parameter value of a target sampling point in the first echo data;
[0044] determining a second target time based on a parameter value of the target sampling point in the second echo data;
[0045] The distance corresponding to the echo data is determined according to the first target time and the second target time.
[0046] According to a second aspect of the present application, a distance measuring device is provided, comprising:
[0047] a memory configured to store instructions; and
[0048] The processor is configured to call the instructions from the memory and implement the above-mentioned ranging method when executing the instructions.
[0049] According to a third aspect of the present application, a vehicle is provided, comprising the aforementioned ranging device.
[0050] According to a fourth aspect of the present application, a computer-readable storage medium is provided, on which instructions are stored. When the instructions are executed by a processor, the processor is configured to perform the above-mentioned ranging method.
[0051] According to a fifth aspect of the present application, a computer program product is provided, which includes a computer program, and when the computer program is executed by a processor, the steps of the above-mentioned ranging method are implemented.
[0052] In summary, this application determines the target sampling point based on the echo data. The target sampling point covers the rising and falling edges of the echo data, and the ranging result is determined based on the parameter value of the target sampling point. In this way, there is no need to use all the sampling points in the echo data to calculate the optical ranging result. Algorithms with lower computational complexity can be used, which reduces the computing power required for optical ranging, increases data processing speed, and can obtain higher ranging accuracy and intensity accuracy, thereby improving the efficiency of optical ranging.
[0053] Other features and advantages of the present application will be described in detail in the subsequent detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] To more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of the present application. Those skilled in the art can also derive other drawings based on these drawings without inventive effort.
[0055] In order to more completely understand the present application and its beneficial effects, the following description will be given in conjunction with the accompanying drawings, wherein the same drawing numbers represent the same parts in the following description.
[0056] Figure 1 This is a schematic diagram of the principle of using a constant ratio timing method to perform lidar ranging;
[0057] Figure 2 A schematic diagram of an echo waveform of a laser radar provided in an embodiment of the present application;
[0058] Figure 3 A flow chart of a distance measurement method provided in an embodiment of the present application;
[0059] Figure 4 This is a schematic diagram of the optical path of a laser radar provided in a specific embodiment of the present application;
[0060] Figure 5 A schematic flow chart of a laser radar ranging method provided in a specific embodiment of the present application;
[0061] Figure 6 This is a structural diagram of a distance measuring device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0062] 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 embodiments described 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 those skilled in the art without creative work are within the scope of protection of the present application.
[0063] In the description of this application, it should be understood that the terms "first" and "second" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly specifying the number of the technical features indicated. Therefore, features specified as "first" or "second" may explicitly or implicitly include one or more of the described features. In the description of this application, "plurality" means two or more, unless otherwise specifically qualified. In this application, the word "exemplary" is used to mean "serving as an example, illustration, or illustration." Any embodiment described in this application as "exemplary" is not necessarily to be construed as preferred or advantageous over other embodiments. The following description is provided to enable anyone skilled in the art to implement and use the present application. In the following description, details are listed for illustrative purposes. It should be understood that one of ordinary skill in the art will recognize that the present application can be implemented without these specific details. In other instances, well-known structures and processes are not described in detail to avoid obscuring the description of this application with unnecessary detail. Therefore, this application is not intended to be limited to the embodiments shown, but is to be accorded the widest scope consistent with the principles and features disclosed herein.
[0064] Time of Flight (ToF) is a key parameter in optical ranging, which represents the time it takes for the light signal to be emitted and returned to the ToF sensor. This parameter directly affects the accuracy of optical ranging. This application takes laser radar for optical ranging as an example. Currently, there are mainly two solutions for obtaining ToF parameters in the design and production of laser radar. One is to use a time-to-digital converter (TDC) chip to record the emission and reception moments of the laser pulse respectively, so as to further obtain the time difference between the two. However, the cost of this solution is relatively high. The other is to use an analog-to-digital converter (ADC) chip to capture the complete signal waveform (the so-called full waveform) fed back by the photosensitive element during the detection cycle, and obtain the time difference between the emission and reception moments of the laser pulse after further analysis. The cost of this solution is relatively low, so the use of laser radars that usually use ADC chips to obtain ToF data is more common.
[0065] In the ranging method of laser radar using an ADC chip, a constant fraction timing method (CFT) is usually used to measure the distance between the target object and the laser radar. Figure 1 The figure is a schematic diagram of the principle of using a constant ratio timing method to measure the distance of a laser radar. Figure 1As shown, compared with the pulse arrival time calculation method based on fixed threshold triggering, this method can effectively reduce the walking error (i.e., the detection time deviation caused by the change of pulse amplitude and pulse shape). However, it still does not make full use of the complete echo data collected by the ADC chip. It only uses the rising edge data of the laser pulse, and does not use the data contained in the waveform peak and falling edge. Therefore, the data sample used by this method is not complete enough, which easily leads to the degradation of the analysis result. In addition, this method cannot obtain information such as the reflectivity of the target object. For example, it cannot obtain the echo intensity of the laser radar. Based on this, the embodiment of the present application makes full use of the echo data of the laser radar collected by the ADC chip, and can obtain higher-precision laser radar ranging accuracy and intensity information. In addition, by using an algorithm with lower computational complexity, the computing power demand pressure of the laser radar ranging is reduced, the data processing speed is increased, and the efficiency of the laser radar ranging is improved.
[0066] In order to better understand the calculation principle of the distance measurement method in the embodiment of the present application, the characteristics of the echo data using a laser radar as an example are first described.
[0067] The laser radar waveform can be approximated as a Gaussian waveform. That is, the laser radar pulses have a Gaussian distribution in the time domain. A Gaussian waveform is a symmetrical bell-shaped curve. Figure 2 This is a schematic diagram of the echo waveform of a laser radar provided in an embodiment of the present application. The image of the ideal Gaussian function can be as follows Figure 2 Therefore, we can first construct a Gaussian function to describe the laser radar echo data, and then extract the required feature data from the echo data based on the Gaussian function.
[0068] As an example, the typical form of the Gaussian function is expressed as formula (1):
[0069]
[0070] Where f(x) is the value of the Gaussian function with respect to the variable x. A is the maximum value of the Gaussian function, that is, the peak height of the curve. μ is the abscissa of the Gaussian function's maximum point, which determines the position of the curve on the x-axis. σ is the standard deviation, which determines the spread of the Gaussian function curve. A larger standard deviation results in a wider Gaussian function curve and a flatter trend. Conversely, a smaller standard deviation results in a narrower Gaussian function curve and a sharper trend.
[0071] The echo data of the laser radar within one detection cycle collected by the ADC chip in the embodiment of the present application satisfies the above-mentioned Gaussian function. Among them, one detection cycle of the laser radar refers to the time it takes for the laser radar to transmit a pulse and receive the echo data of the pulse. Figure 2The x-axis represents the sampling time, and the y-axis represents the sampling value. Within a detection cycle, echo data includes multiple sampling times at equal intervals, with each sampling time corresponding to an x-axis coordinate. The sampling value represents the characteristics of the echo data collected by the ADC chip at that sampling time, such as echo intensity or echo energy. The pulse width of the Gaussian function corresponding to each echo data point is related to the standard deviation σ of the echo data point.
[0072] Typically, LiDAR ranging is obtained by fitting all sampling points within a detection cycle. Based on the characteristics of the echo data described above, the present embodiment only needs to collect data from the sampling points corresponding to the required sampling time to obtain the LiDAR ranging result. The following describes the calculation method of the present embodiment based on the principle of the Gaussian waveform described above.
[0073] Figure 3 This is a flow chart of a distance measurement method provided in an embodiment of the present application. Figure 3 As shown, the ranging method may include steps 301-302, and the following is a detailed introduction using the optical ranging method of laser radar ranging as an example.
[0074] Step 301: Determine target sampling points based on echo data, where the target sampling points cover the rising edge and the falling edge of the echo data.
[0075] Step 302: Determine the distance measurement result based on the parameter value of the target sampling point.
[0076] In the embodiment of the present application, the echo data refers to the echo data within a sampling period. The echo data may include multiple sampling points, each sampling point corresponds to a sampling time, and the interval time between every two adjacent sampling points is the same. The target sampling point refers to the sampling point used to calculate the laser radar ranging result. The target sampling point in the embodiment of the present application covers the rising edge and falling edge of the echo data. In this way, ranging can be performed based on the target sampling point. Then, based on the parameter value of the target sampling point, the ranging result between the target object and the laser radar can be determined. The ranging result may include the distance between the target object and the laser radar, as well as the echo intensity of the echo data. The echo intensity refers to the light intensity or energy reflected back by the target object measured by the laser radar, which is used to indicate the reflectivity of the target object. For example, reflectivity, surface material, shape, etc. In this way, the target object can be classified, identified, and tracked.
[0077] In summary, the embodiments of the present application do not need to use all sampling points within the detection period to calculate the ranging results between the target object and the lidar. By using an algorithm with lower computational complexity, the computing power demand for lidar ranging is reduced, the data processing speed is increased, and higher ranging accuracy and intensity accuracy can be obtained, thereby improving the efficiency of lidar ranging.
[0078] In the related art, only the rising edge data of the laser pulse is used, resulting in incomplete data used for calculation. Based on this, in an embodiment of the present application, the selected target sampling point needs to cover the rising edge and falling edge of the laser pulse on the same echo data. Therefore, the interval time of adjacent sampling points in the embodiment of the present application matches the pulse duration in the echo data. Among them, the pulse duration refers to the time from the start to the end of the pulse of the echo data. Taking the example that the target sampling points include at least three sampling points on the same echo data, at least three sampling points cover the rising edge and falling edge of the echo data. As an example, the interval time between the first sampling point and the third sampling point is greater than or equal to the pulse duration of the echo data. That is, twice the set interval time is greater than or equal to the pulse duration of the echo data. Among them, the set interval time refers to the interval time between two adjacent sampling points, which can be set according to needs.
[0079] Specifically, taking three sampling points as target sampling points as an example, in step 301, the echo data can be sampled to obtain multiple sampling points. Then, based on a set threshold, at least three of the multiple sampling points are selected as target sampling points. The set threshold is a pre-set value used to determine whether the sampling value of the Gaussian function corresponding to the echo data reaches the threshold. Only when the threshold is reached can the sampling value be determined as valid, thereby distinguishing the target object from background noise or other spurious signals in the echo data and reducing false detections.
[0080] In this embodiment of the present application, target sampling points can be selected by sequentially comparing the sampling values of the sampling points with a set threshold. When a sampling value greater than the set threshold is detected, it indicates that the sampling value is the sampling value of the echo data. At least three sampling points among the sampling values exceeding the set threshold are then selected as target sampling points. The target sampling points must cover both the rising and falling edges of the echo data.
[0081] Taking the target sampling points as three sampling points with adjacent sampling times as an example, in one example, based on the comparison result of the sampling value at the current sampling time with the sampling values at the adjacent sampling times, it can be determined whether the three adjacent sampling points near the threshold overlap the rising edge and the falling edge, thereby determining the first sampling point, the second sampling point, and the third sampling point with adjacent sampling times. The first sampling point is the sampling point with the earliest sampling time among the target sampling points, and the second sampling point and the third sampling point are two adjacent sampling points with sampling times after the first sampling point.
[0082] In this embodiment of the present application, the selection of the first, second, and third sampling points is not limited to three sampling points with adjacent sampling times. The selection is based on whether the three target sampling points simultaneously cover the rising and falling edges of the echo data. Specifically, the first, second, and third candidate sampling points can be selected when the sampling value is greater than a set threshold. The second and third candidate sampling points are two sampling points whose sampling times are after the first candidate sampling point. The intervals between the first, second, and third candidate sampling points are the same. If the first candidate sampling point is on the rising edge of the echo data, a determination is made as to whether the third candidate sampling point is on the falling edge of the echo data. If the third candidate sampling point is on the falling edge of the echo data, the first candidate sampling point is determined as the first sampling point, the second candidate sampling point is determined as the second sampling point, and the third candidate sampling point is determined as the third sampling point.
[0083] Taking three sampling points with adjacent sampling times as an example, to ensure that the three sampling points in the embodiment of the present application necessarily cover the rising and falling edges of the echo data, the first sampling point may be a sampling point before crossing the threshold, or the first sampling point after crossing the threshold. The following describes two scenarios in detail.
[0084] First, determine whether the sampled value at the current sampling time is on a rising edge. Specifically, determine whether the sampled value at the current sampling time is greater than the sampled value at the previous sampling time. If the sampled value at the current sampling time is greater than the sampled value at the previous sampling time, it can be determined that the sampled value at the current sampling time is on a rising edge. Next, determine whether the sampled value at the next sampling time is on a falling edge. In other words, determine whether the sampled value at the next sampling time is less than the sampled value at the current sampling time.
[0085] At this point, two situations may occur. First, if the sample value at the next sampling time is smaller than the sample value at the current sampling time, it can be determined that the sample value at the next sampling time is a sample value on the falling edge. In this case, the sampling point at the previous sampling time can be used as the first sampling point, that is, the sampling point before crossing the threshold. Then, the sampling point at the current sampling time is used as the second sampling point, and the sampling point at the next sampling time is used as the third sampling point. In this way, the first, second, and third sampling points can simultaneously cover the rising and falling edges of the echo data.
[0086] Second, if the sample value at the next sampling time is greater than or equal to the sample value at the current sampling time, it indicates that the sample value at the next sampling time is not on the falling edge. Therefore, the first sampling point after the threshold is crossed, that is, the sampling point at the current sampling time, is used as the first sampling point. The sampling points at the next two sampling times after the current sampling time are then used as the second sampling point and the third sampling point. In this way, the first sampling point, the second sampling point, and the third sampling point can simultaneously cover the rising and falling edges of the echo data.
[0087] Through the above two methods, the three adjacent sampling points in the target sampling points can simultaneously cover the rising edge and falling edge of the echo data. It should be noted that the above method is an example of an embodiment of the present application. The target sampling points in the echo data can be selected based on needs. The number of target sampling points and the selection method are not limited. It only needs to cover the rising edge and falling edge of the echo data at the same time. This is not limited here.
[0088] In an embodiment of the present application, the ranging result may include the distance between the target object and the laser radar. The parameter values of the target sampling point may include the sampling time of the first sampling point, the sampling value of the first sampling point, the sampling value of the second sampling point, the sampling value of the third sampling point, and a set interval time. The interval time between the first sampling point and the second sampling point, and the interval time between the second sampling point and the third sampling point, are the set interval times. Therefore, the target time of the echo data can be determined based on the sampling time of the first sampling point, the sampling value of the first sampling point, the sampling value of the second sampling point, the sampling value of the third sampling point, and the set interval time. Specifically, a constant value can be first determined based on the sampling value of the first sampling point, the sampling value of the second sampling point, and the sampling value of the third sampling point. Then, the target time of the echo data is determined based on the constant value, the sampling time of the first sampling point, and the set interval time. The distance between the target object and the laser radar is then determined based on the target time.
[0089] Next, we will take three sampling points as an example to illustrate the calculation principle of the embodiment of the present application. Assume that the sampling time of the first sampling point is recorded as t0, set the interval time as τ, a is the number of sampling period intervals between the first sampling point and the second sampling point, and b is the number of sampling period intervals between the second sampling point and the third sampling point. Then, the sampling time of the second sampling point is t0+aτ, and the sampling time of the third sampling point is t0+(a+b)τ. The sampling value of the first sampling point is y0, the sampling value of the second sampling point is y1, and the sampling value of the third sampling point is y2. Then y0, y1 and y2 can be listed in the following equation group (2):
[0090]
[0091] Among them, A is the echo intensity of the echo data, μ is the target time of the echo data, the target time refers to the time from the laser radar emission to the reflection from the target object, σ is the standard deviation of the echo data, 2σ 2 is twice the variance of the echo data. A, μ, and σ are unknowns. By solving for the value of μ, we can further analyze the ToF parameters based on the pulse emission time. The value of A can be used as the echo intensity. By performing logarithmic operations on both sides of the equal signs of the three equations in equation group (2), we can obtain equation group (3):
[0092]
[0093] Then, subtract the left and right sides of the equal sign of the first equation from the left and right sides of the equal sign of the second equation in the equation group (3), and subtract the left and right sides of the equal sign of the second equation from the left and right sides of the equal sign of the third equation, to obtain the equation group (4):
[0094]
[0095] Next, divide the left and right sides of the equal sign of the first equation in the equation group (4) by the left and right sides of the equal sign of the second equation, and we can get formula (5):
[0096]
[0097] From this, we can see that there is only one unknown number μ in formula (5). Since y0, y1 and y2 are all sampled values of the ADC chip, the left side of the equal sign in formula (5) is a constant value. In order to simplify the calculation, the left side of the equal sign can be recorded as C. Further simplification can be obtained:
[0098]
[0099] Therefore, it can be solved that the target time of the echo data is calculated by formula (6):
[0100]
[0101] Where μ is the target time of the echo data, t0 is the sampling time of the first sampling point, τ is the set interval time, y0 is the sampling value of the first sampling point, y1 is the sampling value of the second sampling point, and y2 is the sampling value of the third sampling point. Therefore, the target time of the echo data can be calculated based on the sampling values of the first, second, and third sampling points, as well as the set interval time. The distance between the target object and the lidar can be determined based on the target time of the echo data and the speed of the laser.
[0102] The ranging results in the embodiments of the present application may also include the echo strength of the echo data. Therefore, the echo strength of the echo data may also be determined based on the target time. Specifically, the twice-variance of the echo data may be determined based on the sampling value of the first sampling point, the sampling value of the second sampling point, the sampling time of the first sampling point, the set interval time, and the target time of the echo data. The echo strength of the echo data may be determined based on the twice-variance, the sampling time of the first sampling point, the sampling value of the first sampling point, and the target time of the echo data.
[0103] As an example, the first equation in the equation group (4) can be used to obtain equation (7):
[0104]
[0105] Then, based on the first equation in equation group (2), the echo intensity of the echo data can be calculated by equation (8):
[0106]
[0107] The μ and 2σ obtained above are 2 Substituting into formula (8), we can get the echo intensity of the echo data.
[0108] In summary, in the embodiment of the present application, only three natural logarithm operations are involved in calculating the C value, and one exponential operation is involved in calculating the parameter A. The remaining steps are simple elementary operations, and the task of extracting the ToF and amplitude information of the echo data can be completed by consuming less computing power.
[0109] In the embodiments of the present application, the ToF of the echo data can be calculated based on the time delay of a single echo data by using Time-Correlated Single Photon Counting (TCSPC) technology. The calculation based on a single echo data is used to obtain the corresponding target time. The target time is then subtracted from the preset initial time to obtain the ToF of the LiDAR, thereby determining the distance between the target object and the LiDAR.
[0110] In addition, the time difference calculation based on the echo data of the two optical paths can also be performed by using a photodetector. The following description is made by taking an avalanche photodiode (APD) as an example. Figure 4 This is a schematic diagram of the optical path of a laser radar provided in a specific embodiment of the present application. Figure 4As shown in the figure, after the laser radar laser pulse is emitted, it first passes through the spectrometer. A part of it is captured by the APD after reflection. The sampling time of this signal is used to calculate the start time of the laser pulse for ToF calculation. The other part hits the target object after passing through the spectrometer and returns along the original path, and is then captured by the APD. The difference between this moment and the start time of the ToF laser pulse is the ToF of the echo data that needs to be solved.
[0111] Therefore, in an embodiment of the present application, the echo data may include first echo data and second echo data. The first echo data is the echo data that enters the APD after being reflected by the spectrometer, and the second echo data is the echo data reflected back by the target object. In step 302, the first target time can also be determined based on the parameter value of the target sampling point in the first echo data. The first target time is the start time of the laser pulse for calculating ToF. Then, the second target time is determined based on the parameter value of the target sampling point in the second echo data. The second target time is the end time of the laser pulse for calculating ToF. Then, the ToF of the target object detected by the laser radar can be obtained based on the first target time and the second target time. Finally, the distance between the target object and the laser radar can be determined based on the ToF.
[0112] Figure 5 This is a flow chart of a laser radar ranging method provided in a specific embodiment of the present application.
[0113] Specifically, the above-mentioned ranging method is executed after collecting the data of the detection cycle of a single laser pulse of the laser radar. First, all the sampling points are detected in sequence according to the sampling time to determine whether the sampling point is the first point that exceeds the set threshold, that is, to determine whether the point is higher than the set estimate and the previous point is lower than the set threshold. If not, step to the next point and repeat the step. If yes, calculate the μ value of the echo data according to formula (6) and save the record. Continue to process the data of the sampling point to determine whether the next sampling point is the second μ value of the detection cycle until the μ values of two sets of echo data of this detection cycle are obtained. The first μ value is the emission time of the laser pulse, and the second μ value is the echo arrival time. The difference between the two μ values is the ToF parameter we need to extract. At the same time, the amplitude parameter A of the second set of echo data with a later sampling time can also be calculated according to formula (8) to determine the echo intensity of the echo signal.
[0114] Figure 6 Schematic diagram of the structure of a distance measuring device 600 provided in an embodiment of the present application. Figure 6 As shown, the distance measurement device 600 may include a memory 601 and a processor 602. The memory 601 is configured to store instructions. The processor 602 is configured to call instructions from the memory and implement the above-mentioned distance measurement method when executing the instructions.
[0115] The present application also provides a vehicle that can include the aforementioned distance measuring device. The vehicle in the present application can be a fuel vehicle, a plug-in hybrid vehicle, or a new energy vehicle, etc., and this application does not specifically limit this.
[0116] An embodiment of the present application further provides a computer-readable storage medium having instructions stored thereon. When the instructions are executed by a processor, the processor is configured to execute the above-mentioned ranging method.
[0117] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps of the above-mentioned ranging method are implemented.
[0118] Since the instructions stored in the ranging device, the vehicle, the computer-readable storage medium, and the computer program product can execute the steps of any ranging method provided in the embodiments of the present application, the beneficial effects that can be achieved by any ranging method provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.
[0119] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0120] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0121] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0122] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0123] In a typical configuration, a computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.
[0124] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0125] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology for information storage. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices, or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media such as modulated communication signals and carrier waves.
[0126] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.
[0127] The above are merely preferred embodiments of the present application and do not constitute any form of limitation to the present application. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present application without departing from the content of the technical solution of the present application are still within the scope of the technical solution of the present application.
Claims
1. A distance measurement method, characterized in that: include: Determining a target sampling point according to the echo data, wherein the target sampling point covers a rising edge and a falling edge of the echo data; A distance measurement result is determined based on the parameter value of the target sampling point.
2. The distance measurement method according to claim 1, wherein: Determining the target sampling point according to the echo data includes: Sampling the echo data to obtain a plurality of sampling points; According to a set threshold, at least three sampling points among the plurality of sampling points are used as the target sampling points; The at least three sampling points cover the rising edge and the falling edge of the echo data.
3. The distance measurement method according to claim 2, wherein: The step of selecting at least three sampling points from the plurality of sampling points as the target sampling points according to the set threshold comprises: Comparing the sampling values of the sampling points with the set thresholds in sequence; When a sampling value greater than the set threshold is detected, determining a first sampling point, a second sampling point, and a third sampling point; The second sampling point and the third sampling point are two sampling points whose sampling times are later than the first sampling point.
4. The distance measurement method according to claim 3, wherein: The determining of the first sampling point, the second sampling point, and the third sampling point includes: Selecting a first candidate sampling point, a second candidate sampling point, and a third candidate sampling point from the sampling values greater than the set threshold, where the second candidate sampling point and the third candidate sampling point are two sampling points whose sampling times are later than the first candidate sampling point; If the first candidate sampling point is on the rising edge of the echo data, determining whether the third candidate sampling point is on the falling edge of the echo data; If the third candidate sampling point is on a falling edge of the echo data, the first candidate sampling point is determined as the first sampling point, the second candidate sampling point is determined as the second sampling point, and the third candidate sampling point is determined as the third sampling point.
5. The distance measurement method according to claim 3, characterized in that: The ranging result includes the distance corresponding to the echo data, and determining the ranging result based on the parameter value of the target sampling point includes: determining a target time of the echo data according to a sampling time of the first sampling point, a sampling value of the first sampling point, a sampling value of the second sampling point, a sampling value of the third sampling point, and a set interval time, wherein the interval time between the first sampling point and the second sampling point, and the interval time between the second sampling point and the third sampling point are the set interval time; A distance corresponding to the echo data is determined based on the target time.
6. The distance measurement method according to claim 5, characterized in that: The determining the target time of the echo data according to the sampling time of the first sampling point, the sampling value of the first sampling point, the sampling value of the second sampling point, the sampling value of the third sampling point, and the set interval time includes: determining a constant value according to the sampling value of the first sampling point, the sampling value of the second sampling point, and the sampling value of the third sampling point; The target time of the echo data is determined according to the constant value, the sampling time of the first sampling point and the set interval time.
7. The distance measurement method according to claim 6, characterized in that: The constant value is calculated by the following formula: Wherein, C is the constant value, y0 is the sampling value of the first sampling point, y1 is the sampling value of the second sampling point, and y2 is the sampling value of the third sampling point.
8. The distance measurement method according to claim 7, characterized in that: The target time of the echo data is calculated by the following formula: Wherein, C is the constant value, μ is the target time of the echo data, t0 is the sampling time of the first sampling point, τ is the set interval time, a is the number of sampling period intervals between the first sampling point and the second sampling point, and b is the number of sampling period intervals between the second sampling point and the third sampling point.
9. The distance measurement method according to claim 5, characterized in that: The ranging result also includes the echo intensity of the echo data, and the determining of the ranging result based on the parameter value of the target sampling point further includes: An echo intensity of the echo data is determined based on the target time.
10. The distance measurement method according to claim 9, characterized in that: The determining the echo intensity of the echo data based on the target time includes: determining a double variance of the echo data according to a sampling value of the first sampling point, a sampling value of the second sampling point, a sampling time of the first sampling point, the set interval time, and a target time of the echo data; The echo intensity of the echo data is determined according to the twice variance, the sampling time of the first sampling point, the sampling value of the first sampling point, and the target time of the echo data.
11. The distance measurement method according to claim 10, characterized in that: The double variance of the echo data is calculated by the following formula: Among them, 2σ 2 is twice the variance of the echo data, t0 is the sampling time of the first sampling point, a is the number of sampling period intervals between the first sampling point and the second sampling point, τ is the set interval time, y0 is the sampling value of the first sampling point, y1 is the sampling value of the second sampling point, and μ is the target time of the echo data.
12. The distance measurement method according to claim 11, characterized in that: The echo intensity of the echo data is calculated using the following formula: Wherein, A is the echo intensity of the echo data, 2σ 2 is twice the variance of the echo data, μ is the target time of the echo data, t0 is the sampling time of the first sampling point, and y0 is the sampling value of the first sampling point.
13. The distance measurement method according to any one of claims 1 to 12, characterized in that: The echo data includes first echo data and second echo data, and determining the ranging result based on the parameter value of the target sampling point further includes: determining a first target time based on a parameter value of a target sampling point in the first echo data; determining a second target time based on a parameter value of the target sampling point in the second echo data; The distance corresponding to the echo data is determined according to the first target time and the second target time.
14. A distance measuring device, characterized in that: include: a memory configured to store instructions; as well as A processor is configured to call the instructions from the memory and implement the ranging method according to any one of claims 1 to 13 when executing the instructions.
15. A vehicle, characterized in that: The device comprises a distance measuring device according to claim 14.
16. A computer-readable storage medium, characterized in that The computer-readable storage medium stores instructions, which, when executed by a processor, enable the processor to be configured to perform the ranging method according to any one of claims 1 to 13.
17. A computer program product, characterized in that The computer program product comprises a computer program, which implements the steps of the distance measurement method according to any one of claims 1 to 13 when executed by a processor.