Distance measurement method and device, electronic device, and storage medium

By smoothly interpolation processing of the histogram data in the time of flight measurement system, the flight time of signal photons is determined, and the measurement accuracy problem under the influence of ambient light interference and dark noise is solved, and the signal photon detection accuracy and measurement accuracy are achieved.

CN115038989BActive Publication Date: 2025-06-13SUTENG INNOVATION TECHNOLOGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202080004944.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-11-25
Publication Date
2025-06-13
Estimated Expiration
2040-11-25

AI Technical Summary

Technical Problem

In practical applications, the time-of-flight measurement system is affected by ambient light interference and dark noise of the photoelectric sensor, resulting in a decrease in measurement accuracy.

Method used

By acquiring multiple histogram data, smooth interpolation processing is performed to generate a histogram, determining the flight time of signal photons, thereby calculating the distance between the measuring device and the target to be measured.

Benefits of technology

Effectively filter out noise photon events, improve the accuracy of signal photon detection, and improve the accuracy of time-of-flight measurement, while no changes to the existing hardware structure are required to save design costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115038989B_ABST
    Figure CN115038989B_ABST
Patent Text Reader

Abstract

The present application discloses a distance measurement method and apparatus, an electronic device, and a storage medium. The method includes, in an embodiment of the present application, obtaining a plurality of histogram data; performing smoothing interpolation processing on the plurality of histogram data to generate a histogram; determining the flight time of signal photons according to the histogram, and determining the distance between the measurement device and the target to be measured according to the flight time of the signal photons. Thus, the distance measurement method of the present application can process a plurality of histogram data through smoothing interpolation to filter out noise photon events and improve the accuracy of signal photon detection. In addition, the present application is optimized and improved based on the inherent photoelectric sensor and time-to-digital converter, without the need to change the existing hardware structure, saving design costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of measurement, and particularly to a distance measurement method and device, an electronic device, and a storage medium. Background Art

[0002] Time-of-flight (TOF) measurement systems have important applications in various fields of three-dimensional ranging and three-dimensional imaging, such as autonomous driving, face recognition, 3D games, and virtual reality. Specifically, the time-of-flight (TOF) measurement technology is that a light source emits continuous or pulsed outgoing light beams, which are reflected by the target to be measured and then return. A photoelectric sensor receives the returned echo light beams, and the distance to the target to be measured, that is, the depth information, is calculated by calculating the time difference between the emitted outgoing light beam and the received echo light beam, or by calculating the phase difference between the outgoing light beam and the echo light beam.

[0003] In the actual measurement process of time-of-flight, interference from ambient light and dark noise of the photoelectric sensor itself will cause a large amount of interference information, that is, noise signals, in the measurement system. Therefore, how to avoid the influence of noise signals to improve the accuracy of time-of-flight ranging is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the Invention

[0004] Embodiments of this application provide a distance measurement method and device, an electronic device, and a storage medium.

[0005] In a first aspect, embodiments of this application provide a distance measurement method, the method including:

[0006] Obtaining a plurality of histogram data;

[0007] Performing smooth interpolation processing on the plurality of histogram data to generate a histogram;

[0008] Determining the flight time of signal photons according to the histogram, and determining the distance between the measurement device and the target to be measured according to the flight time of the signal photons.

[0009] In a second aspect, embodiments of this application provide a distance measurement device, the device including:

[0010] An obtaining module, configured to obtain a plurality of histogram data;

[0011] A generating module, configured to perform smooth interpolation processing on the plurality of histogram data to generate a histogram;

[0012] A determining module, configured to determine the flight time of signal photons according to the histogram, and determine the distance between the measurement device and the target to be measured according to the flight time of the signal photons.

[0013] In a third aspect, an embodiment of the present application provides a computer storage medium storing multiple instructions adapted to be loaded and executed by a processor to perform the above method steps.

[0014] In a fourth aspect, an embodiment of the present application provides an electronic device, which may include: a processor and a memory;

[0015] wherein, the memory stores a computer program adapted to be loaded and executed by the processor to perform the above method steps.

[0016] The beneficial effects brought by the technical solutions provided in some embodiments of the present application at least include:

[0017] In the embodiment of the present application, multiple histogram data are obtained; the multiple histogram data are subjected to smooth interpolation processing to generate a histogram; the flight time of signal photons is determined according to the histogram, and the distance between the measuring device and the target to be measured is determined according to the flight time of the signal photons. Thus, the distance measurement method of the present application can process multiple histogram data through smooth interpolation to filter out noise photon events and improve the accuracy of signal photon detection. In addition, the present application is optimized and improved based on the inherent photoelectric sensor and time-to-digital converter, without the need to change the existing hardware structure, saving the design cost. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] To more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required in the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0019] Figure 1 It is a schematic diagram of the architecture of a distance measurement system according to an embodiment provided by the present application;

[0020] Figure 2 It is a schematic flowchart of a distance measurement method according to an embodiment provided by the present application;

[0021] Figure 3 It is a time stamp schematic diagram of n integration periods in an embodiment provided by the present application;

[0022] Figure 4 It is a histogram generated by an embodiment provided by the present application without smooth interpolation;

[0023] Figure 5 It is a schematic flowchart of a distance measurement method according to another embodiment provided by the present application;

[0024] Figure 6Schematic diagram of the convolution and processing process of the first matrix in the distance measurement method provided by this application;

[0025] Figure 7a Histogram generated by an embodiment of smoothed interpolation provided by this application;

[0026] Figure 7b Histogram generated by another embodiment of smoothed interpolation provided by this application;

[0027] Figures 8a - 8d Schematic diagram of the specific processing process of smoothed interpolation in the distance measurement method of an embodiment provided by this application;

[0028] Figure 9 Schematic diagram of the process flow of the distance measurement method of yet another embodiment provided by this application;

[0029] Figure 10 Schematic diagram of the structure of a distance measurement device of an embodiment provided by this application;

[0030] Figure 11 Schematic diagram of the structure of another distance measurement device of an embodiment provided by this application;

[0031] Figure 12 Schematic diagram of the structure of yet another distance measurement device of an embodiment provided by this application;

[0032] Figure 13 Schematic diagram of the structure of the electronic device provided by this application. Detailed implementation manners

[0033] When the following description involves the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. On the contrary, they are merely examples of devices and methods consistent with some aspects of this application as detailed in the appended claims.

[0034] In the description of this application, it should be understood that terms such as "first", "second", etc. are only used for descriptive purposes and cannot be construed as indicating or implying relative importance. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific circumstances. In addition, in the description of this application, unless otherwise specified, "a plurality" means two or more. "And / or" describes the association relationship of associated objects and indicates that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the associated objects before and after.

[0035] Please refer to Figure 1, Figure 1 It is a schematic diagram of the architecture of a distance measurement system provided by an embodiment of the present application.

[0036] As Figure 1 shown, the distance measurement system may include a photoelectric sensor, a time-to-digital converter (TDC), a random access memory (RAM), and a processor. Among them, the photoelectric sensor may adopt devices such as a photodiode (PD) and a single-photon avalanche diode (SPAD) to receive photon events. The time-to-digital converter (TDC) samples and outputs the photon events received by the photoelectric sensor. The processor is used to generate a histogram based on the received photon events, and perform operations such as smoothing interpolation on the histogram to determine the signal photons used to calculate the distance between the measuring device and the target to be measured.

[0037] Specifically, in a three-dimensional ranging scenario, a single-photon avalanche diode (SPAD) receives the echo photons reflected by the target to be measured and triggers an avalanche pulse electrical signal. The avalanche pulse electrical signal is transmitted to the time-to-digital converter (TDC) for recording the time. The random access memory (RAM) stores the time of the received echo photons. The processor performs processing such as smoothing interpolation on the data stored in the random access memory to filter out the noise signals received during the measurement process, and obtains the time of the outgoing photons emitted by the transmitting end of the distance measurement system, calculates the time difference between the emitted outgoing photons and the received echo photons, which is the flight time of the detected photons. Finally, the distance between the distance measurement system and the target to be measured is calculated based on the flight time.

[0038] Next, in conjunction with Figure 1 the introduced distance measurement system, the distance measurement method provided by the embodiment of the present application will be introduced.

[0039] In one embodiment, Figure 2 as shown, a flowchart of a distance measurement method is provided. The distance measurement method includes the following steps:

[0040] S201, obtain a plurality of histogram data.

[0041] Among them, the histogram data may include the timestamps of each photon event within a frame period. A frame period includes n integration periods, and the timestamp is used to represent the moment when a photon event is received within an integration period. Photon events may include noise photon events and signal photon events.

[0042] Specifically, as Figure 3 shown, within the n integration periods T0 of a frame period, the timestamps of the noise photon events and signal photon events received in each integration period.

[0043] Further, referring to Figure 4 , the timestamps t1, t2, …, t(n) of multiple photon events received within one frame period, and the number of photon events corresponding to each timestamp t1→bin1, t2→bin2, ..., t(n)→bin(n).

[0044] S202. Perform smoothing interpolation processing on multiple histogram data to generate a histogram.

[0045] S203. Determine the flight time of signal photons according to the histogram, and determine the distance between the measurement device and the target to be measured according to the flight time of the signal photons.

[0046] In the embodiments of the present application, multiple histogram data are obtained; smoothing interpolation processing is performed on the multiple histogram data to generate a histogram; the flight time of signal photons is determined according to the histogram, and the distance between the measurement device and the target to be measured is determined according to the flight time of the signal photons. Thus, the distance measurement method of the present application can process multiple histogram data through smoothing interpolation to filter out noise photon events and improve the accuracy of signal photon detection. In addition, the present application is optimized and improved based on the inherent photoelectric sensor and time-to-digital converter, without the need to change the existing hardware structure, saving the design cost.

[0047] Any distance measurement method provided by the embodiments of the present application can be executed by any suitable device with data processing capabilities, including but not limited to: terminal devices, servers, etc. Or, any distance measurement method provided by the embodiments of the present application can be executed by a processor. For example, the processor executes any distance measurement method mentioned in the embodiments of the present application by calling the corresponding instructions stored in the memory. This will not be elaborated below.

[0048] As Figure 5 shown, step S202 in the above embodiments of the present application may specifically include the following steps:

[0049] S501. Determine a first matrix based on the timestamps in multiple histogram data.

[0050] Wherein, the first matrix is used to represent converting the timestamps in the histogram data into a one-dimensional matrix. For example, if there are 2 photon events with timestamp t 1 , 1 photon event with timestamp t 2 , and 3 photon events with timestamp t 3 , then the first matrix can be expressed as: [t 1 , t 1 , t 2 , t 3 , t 3 , t 3 .

[0051] S502, perform smooth interpolation processing on the first matrix based on a preset window function coefficient matrix to obtain a second matrix.

[0052] Among them, the preset window function can be a rectangular window function.

[0053] Specifically, the values in the window function coefficient matrix can be determined by the number and intensity of photon events corresponding to each timestamp in multiple histogram data.

[0054] In addition, this application can also perform smooth interpolation processing on the first matrix by using the coefficient matrix of window functions such as Hamming window function or Kaiser window function to obtain a second matrix.

[0055] Furthermore, the above step S502 can include: performing a convolution sum operation on the first matrix based on the coefficient matrix of the rectangular window function to obtain a second matrix.

[0056] Such as Figure 6 In the process of converting the first matrix to the second matrix as shown, perform convolution sum processing on the first matrix and the window function coefficient matrix. For example, perform convolution sum operation on the data 3, 6, 6, 6, 6, 7, 8, 8, 8, 8, 9 in the first matrix and 0.073, 0.075, 0.077, 0.078, 0.079, 0.079, 0.079, 0.079, 0.079, 0.078, 0.077 in the window function coefficient matrix, and the data in the following second matrix can be obtained:

[0057] 3 * 0.073 ≈ 0.2,

[0058] 6 * 0.075 + 3 * 0.073 ≈ 0.7,

[0059] 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 1.1,

[0060] 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 1.6,

[0061] 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 2.1,

[0062] 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 2.6,

[0063] 8 * 0.079 + 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 3.2,

[0064] 8 * 0.079 + 8 * 0.079 + 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 3.8,

[0065] 8 * 0.079 + 8 * 0.079 + 8 * 0.079 + 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 4.4,

[0066] 8 * 0.078 + 8 * 0.079 + 8 * 0.079 + 8 * 0.079 + 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 5.1,

[0067] 9 * 0.077 + 8 * 0.078 + 8 * 0.079 + 8 * 0.079 + 8 * 0.079 + 7 * 0.079 + 6 * 0.079 + 6 * 0.078 + 6 * 0.077 + 6 * 0.075 + 3 * 0.073 ≈ 5.8。

[0068] S503, generate a histogram based on the second matrix.

[0069] Furthermore, the present application can generate a histogram by accumulating the number of photon events corresponding to each timestamp in the second matrix. Among them, the abscissa data of the histogram is determined according to the time range where each data in the second matrix is located, and the ordinate data of the histogram is determined according to the number of data in each time range.

[0070] For example, if the second matrix is [t0.3, t1.2, t2.1, t2.3, t2.8, t3.1, t3.4], then the abscissa data of the histogram includes four time ranges: 0 - t1, t1 - t2, t2 - t3, t3 - t4. And since the number of data in the 0 - t1 time range is 1 (t0.3), the number of data in the t1 - t2 time range is 1 (t1.2), the number of data in the t2 - t3 time range is 3 (t2.1, t2.3, t2.8), and the number of data in the t3 - t4 time range is 2 (t3.1, t3.4), therefore, the ordinate data of the histogram is 1, 1, 3, 2 respectively. Thus, a histogram as shown in Figure 7a is generated according to this second matrix. From Figure 7a it can be seen that the number of accumulated photon events in the time range t2 - t3 is the largest, and the reception time of the signal photon events is within the time range t2 - t3. Obtaining the timestamp based on the preset rule is the reception time of the signal photon events. For example, it can be the maximum value, minimum value, or intermediate value in the time range t2 - t3.

[0071] In addition, the present application can also round the timestamps in the second matrix to integers and then perform quantity accumulation. A preferred embodiment can be that after rounding the timestamps in the second matrix in Embodiment 7a to integers, an integerized second matrix [t0, t1, t2, t2, t3, t3, t3] is obtained. Then, after further accumulating the number of photon events corresponding to each timestamp in the integerized second matrix, a histogram as shown in Figure 7b can be generated. As can be seen from Figure 7b , the number of photon events accumulated at timestamp t3 is the largest, which is the reception time of the signal photon events.

[0072] As Figures 8a - 8c shows, a specific implementation of the smoothing interpolation process is given. As Figure 8a shows, a histogram composed of non-smoothed interpolation histogram data has timestamps measured by a time-to-digital converter within multiple integration periods in a frame period distributed within the range of 0 to T0. The timestamps of signal photon events are coherent, and the timestamps of noise photon events are random. Therefore, after experiencing multiple integration periods, the number of signal photon events accumulated is greater than the number of noise photon events accumulated, forming a peak in the histogram, which is then recognized by the backend processing circuit. Among them, at timestamp tk is the time of flight (TOF) of the signal photon corresponding to the target to be measured. As can be observed from Figure 8a , the number of noise photon events corresponding to the timestamps at tk-1, tk+1, and tn-2 is also relatively high, which is likely to cause misidentification of the time of flight of the signal photon events. As Figure 8b shows, a specific process of performing convolution sum processing on the first matrix [t1, t1, t2, t2, t3, t4,..., tn-2, tn-1, tn] of the photon time data is shown. The window function {a1, a2, a3, a4, a5} adopted in this process can specifically be a 5th-order low-pass FIR filter, and each data at the position of the first matrix is operated once, and the operation result is stored in another memory at the corresponding same position coordinate; after the calculation of the current position is completed, the window function moves one bit to the right and calculates the data at the next position. For example:

[0073] a1*t1 = t1,

[0074] a2*t1 + a1*t1 = t1.5,

[0075] a3*t2 + a2*t1 + a1*t1 = t2.2,

[0076] a4*t2 + a3*t2 + a2*t1 + a1*t1 = t2.9,

[0077] a5*t3 + a4*t2 + a3*t2 + a2*t1 + a1*t1 = t3.6

[0078] …tn.k

[0079] According to the above calculation process, the window function coefficient matrix continuously performs a moving convolution sum operation on the first matrix until a complete convolution sum operation is performed on the entire first matrix, obtaining the second matrix [t1, t1.5, t2.2, t2.9, t3.6, …, tn-1.k1, tn-2.k2, tn.k]. By calculating the histogram distribution of the second matrix, it can be obtained that there is t 1 -t 2 There is t between 1 and t 1.5 , so the quantity corresponding to the timestamp t 1 is 2; there is t between t 2 -t 3 and t 2.2 and t 2.9 , so the quantity corresponding to the timestamp t 2 is 2; there is t between t 3 -t 4 and t 3.6 , so the quantity corresponding to the timestamp t 3 is 1; there is t between t 4 -t 5 and t 4.3 , so the quantity corresponding to the timestamp t 4 is 1, …, there is t between t k -t k+1 and t k.1 , t k.2 , t k.4 , t k.7 , so the quantity corresponding to the timestamp t k is 4, …, and so on, obtaining the processed histogram shown in Figure 8c . By comparing Figure 8a and Figure 8c , it can be seen that the spikes corresponding to the noise photons in the time ranges near t k+1 -t k+2 and t n-2 -t n-1 are "smoothed out", while the data corresponding to t k -t k+1 is retained.

[0080] Furthermore, the above embodiments of the present application can also obtain the histogram by rounding the timestamps in the second matrix to integers and then accumulating the quantities. For example, for Figure 8bThe time stamps of the second matrix in [matrix] are rounded to obtain an integerized second matrix [t1, t2, t2, t3, t4, …, tn-1, tn-2, tn]. By accumulating the number of photon events corresponding to each time stamp in this integerized second matrix, Figure 8d the histogram shown in Figure 8a and Figure 8d can be obtained. Similarly, by comparing k+1 and n-2 , it can also be seen that the spikes corresponding to the noise photons near time stamps such as t k are "smoothed out", while the data corresponding to t

[0081] is retained. Thus, the histogram after the smoothing interpolation process of this application can more accurately identify the peak corresponding to the flight time of the signal photon events. Therefore, the time data after the smoothing interpolation calculation improves the signal-to-noise ratio, and further improves the accuracy of the flight time detection.

[0082] As Figure 9 shown, step S203 in the above embodiment of this application may specifically include the following steps:

[0083] S901, determining the time stamp corresponding to the maximum number of photon events in the histogram as the reception time of the signal photon.

[0084] S902, determining the flight time of the signal photon according to the preset emission time of the signal photon and the reception time.

[0085] S903, determining the distance between the measuring device and the target to be measured according to the flight time of the signal photon and the speed of the signal photon.

[0086] Assume that the preset emission time t1 is 14 ns, and the reception time of the signal photon is 80 ns. Then, the flight time of the signal photon can be determined to be 66 ns. When the speed of the signal photon is 300000 km / s, the distance between the measuring device and the target to be measured can be determined to be approximately 10 m.

[0087] Figure 10 is a schematic structural diagram of a distance measuring device 10 provided by an exemplary embodiment of this application. This distance measuring device 10 can be set in electronic devices such as terminal devices and servers, and execute the distance measuring method of any of the above embodiments of this application. As Figure 10 shown, this distance measuring device 10 includes:

[0088] An acquisition module 11, configured to acquire a plurality of histogram data;

[0089] A generating module 12 for performing smooth interpolation processing on the multiple histogram data to generate a histogram; a determining module 13 for determining the flight time of signal photons according to the histogram, and determining the distance between the measuring device and the target to be measured according to the flight time of the signal photons.

[0090] In an embodiment of the present application, multiple histogram data are obtained; smooth interpolation processing is performed on the multiple histogram data to generate a histogram; the flight time of signal photons is determined according to the histogram, and the distance between the measuring device and the target to be measured is determined according to the flight time of the signal photons. Thus, the distance measurement method of the present application can process multiple histogram data through smooth interpolation to filter out noise photon events and improve the accuracy of signal photon detection. In addition, the present application is optimized and improved based on the inherent photoelectric sensor and time-to-digital converter, without changing the existing hardware structure, saving the design cost.

[0091] Optionally, the histogram data includes the timestamp of each photon event.

[0092] Optionally, as Figure 11 shown, the generating module 12 includes:

[0093] A first determining unit 21 for determining a first matrix based on the timestamps in the multiple histogram data;

[0094] An obtaining unit 22 for performing smooth interpolation processing on the first matrix based on a preset window function coefficient matrix to obtain a second matrix;

[0095] A generating unit 23 for generating a histogram based on the second matrix.

[0096] Optionally, each item of data in the preset window function coefficient matrix is determined by the number of photon events corresponding to each timestamp in the histogram data and the intensity of the photon events.

[0097] Optionally, the obtaining unit 22 is specifically configured to perform a convolution sum operation on the first matrix based on the coefficient matrix of the rectangular window function to obtain a second matrix.

[0098] Optionally, the generating unit 23 is specifically configured to generate the histogram by accumulating the number of photon events corresponding to each timestamp in the second frequency domain matrix.

[0099] Optionally, as Figure 12 shown, the determining module 13 includes:

[0100] A second determining unit 31 for determining the reception time of the signal photons as the timestamp corresponding to the maximum number of photon events in the histogram;

[0101] A third determination unit 32 determines the flight time of the signal photon according to the preset emission time and the reception time of the signal photon;

[0102] A fourth determination unit 32 determines the distance between the measurement device and the target to be measured according to the flight time of the signal photon and the speed of the signal photon.

[0103] It should be noted that when the distance measurement device provided in the above embodiment executes the distance measurement method, only the division of the above functional modules is used for illustration. In practical applications, the above functions can be assigned to different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the distance measurement device provided in the above embodiment and the embodiment of the distance measurement method belong to the same concept. The implementation process is shown in the method embodiment and will not be repeated here.

[0104] The serial numbers of the embodiments of the present application above are only for description and do not represent the advantages and disadvantages of the embodiments.

[0105] Please refer to Figure 13 which is a schematic structural diagram of an electronic device provided by an embodiment of the present application. As Figure 13 shown, the electronic device 20 may include: at least one processor 131, at least one network interface 134, a user interface 133, a memory 135, and at least one communication bus 1003.

[0106] Among them, the communication bus 132 is used to realize the connection and communication between these components.

[0107] Among them, the user interface 133 may include a display screen (Display) and a camera (Camera). Optionally, the user interface 133 may further include a standard wired interface and a wireless interface.

[0108] Among them, the network interface 134 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface).

[0109] Among them, the processor 131 may include one or more processing cores. The processor 131 connects various parts within the entire electronic device 20 through various interfaces and circuits. By running or executing instructions, programs, code sets, or instruction sets stored in the memory 135, and by calling the data stored in the memory 135, it executes various functions of the electronic device 20 and processes data. Optionally, the processor 131 may be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), or programmable logic array (PLA). The processor 131 may integrate a combination of one or several of a central processing unit (CPU), a graphics processing unit (GPU), and a modem, etc. Among them, the CPU mainly processes the operating system, user interface, application programs, etc.; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the modem is used to process wireless communication. It can be understood that the above-mentioned modem may not be integrated into the processor 131 and may be implemented separately by a single chip.

[0110] Among them, the memory 135 may include random access memory (RAM) and may also include read-only memory. Optionally, the memory 135 includes a non-transitory computer-readable storage medium. The memory 135 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 135 may include a program storage area and a data storage area. Among them, the program storage area may store instructions for implementing the operating system, instructions for at least one function (such as touch function, sound playback function, image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store the data involved in the above-mentioned various method embodiments. Optionally, the memory 135 may also be at least one storage device located far from the aforementioned processor 131. As Figure 13 shown, the memory 135, as a computer storage medium, may include an operating system, a network communication module, a user interface module, and a distance measurement application program.

[0111] In Figure 13In the electronic device 20 shown, the user interface 133 is mainly used to provide an interface for the user to input and obtain the data input by the user; and the processor 131 can be used to call the distance measurement application program stored in the memory 135 and specifically perform the following operations:

[0112] Obtain a plurality of histogram data;

[0113] Perform a smoothing interpolation process on the plurality of histogram data to generate a histogram;

[0114] Determine the flight time of the signal photons according to the histogram, and determine the distance between the measuring device and the target to be measured according to the flight time of the signal photons.

[0115] In a possible embodiment, the processor 110 executes to determine a first matrix based on the timestamps in the plurality of histogram data;

[0116] Perform a smoothing interpolation process on the first matrix based on a preset window function coefficient matrix to obtain a second matrix;

[0117] Generate a histogram based on the second matrix.

[0118] In a possible embodiment, the processor 110 executes to determine the reception time of the signal photons as the timestamp corresponding to the maximum number of photon events in the histogram;

[0119] Determine the flight time of the signal photons according to the preset emission time of the signal photons and the reception time;

[0120] Determine the distance between the measuring device and the target to be measured according to the flight time of the signal photons and the speed of the signal photons.

[0121] The embodiment of the present application also provides a computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When it runs on a computer or a processor, the computer or the processor is caused to execute one or more steps in the above Figure 2 、 Figure 5 、 Figure 9 shown embodiments. If each component module of the above distance measurement device is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in the computer-readable storage medium.

[0122] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by wire (such as coaxial cable, optical fiber, Digital Subscriber Line (DSL)) or wireless (such as infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that the computer can access or a data storage device such as a server or data center that includes one or more integrated available media. The available medium can be a magnetic medium (such as a floppy disk, hard disk, magnetic tape), an optical medium (such as a Digital Versatile Disc (DVD)), or a semiconductor medium (such as a Solid State Disk (SSD)), etc.

[0123] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above 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 embodiments of the above methods. The foregoing storage media include: Read Only Memory (ROM), Random Access Memory (RAM), magnetic disks, or optical disks and other media that can store program codes. Without conflict, the technical features in this embodiment and the implementation solutions can be combined arbitrarily.

[0124] The above-described embodiments are merely described as preferred implementation manners of the present application, and do not limit the scope of the present application. Without departing from the design spirit of the present application, various deformations and improvements made by those of ordinary skill in the art to the technical solutions of the present application shall fall within the protection scope determined by the claims of the present application.

Claims

1. A distance measurement method, characterized in that, the method includes: Obtaining a plurality of histogram data, the histogram data including timestamps of each photon event, and the photon events including noise photon events and signal photon events; Determining a first matrix based on the timestamps in the plurality of histogram data; Performing a convolution sum operation on the first matrix based on a preset window function coefficient matrix to filter out the timestamps of the noise photon events, obtaining a second matrix, and each item of data in the preset window function coefficient matrix being determined by the number of photon events corresponding to each timestamp in the histogram data and the intensity of the photon events; Generating the histogram by accumulating the number of photon events corresponding to each timestamp in the second matrix; Generating a histogram based on the second matrix, the abscissa data of the histogram being determined according to the time range where each data in the second matrix is located, and the ordinate data of the histogram being determined according to the number of data in each time range; Determining the flight time of the signal photon according to the histogram; Determining the distance between the measuring device and the target to be measured according to the flight time of the signal photon.

2. The distance measurement method according to claim 1, characterized in that, the determining the flight time of the signal photon according to the histogram and determining the distance between the measuring device and the target to be measured according to the flight time of the signal photon includes: Determining the timestamp corresponding to the maximum number of photon events in the histogram as the receiving time of the signal photon; Determining the flight time of the signal photon according to the preset emission time of the signal photon and the receiving time; Determining the distance between the measuring device and the target to be measured according to the flight time of the signal photon and the speed of the signal photon.

3. A distance measurement device, characterized in that, the device includes: An acquisition module for acquiring a plurality of histogram data, the histogram data including timestamps of each photon event, and the photon events including noise photon events and signal photon events; A generation module for determining a first matrix based on the timestamps in the plurality of histogram data; performing a convolution sum operation on the first matrix based on a preset window function coefficient matrix to filter out the timestamps of the noise photon events, obtaining a second matrix, and each item of data in the preset window function coefficient matrix being determined by the number of photon events corresponding to each timestamp in the histogram data and the intensity of the photon events; generating the histogram by accumulating the number of photon events corresponding to each timestamp in the second matrix; generating a histogram based on the second matrix, the abscissa data of the histogram being determined according to the time range where each data in the second matrix is located, and the ordinate data of the histogram being determined according to the number of data in each time range; A determination module for determining the flight time of the signal photon according to the histogram and according to the flight time of the signal photon, determining the distance between the measuring device and the target to be measured.

4. A computer storage medium, characterized in that, ​ The computer storage medium stores multiple instructions, and the instructions are adapted to be loaded and executed by a processor to perform the method steps described in claim 1 or 2.

5. An electronic device, characterized in that it includes: a processor and a memory; wherein, the memory stores a computer program, and the computer program is adapted to be loaded and executed by a processor to perform the method steps described in claim 1 or 2.

Citation Information

Patent Citations

  • Range and parameter extraction using processed histograms generated from a time of flight sensor - parameter extraction

    EP3370080A1