METHOD FOR DEPTH MEASUREMENT WITH A TIME-OF-FLIGHT CAMERA USING AMPLITUDE-MODULATED CONTINUOUS LIGHT
20220128692 · 2022-04-28
Inventors
Cpc classification
G01S17/42
PHYSICS
G01S17/894
PHYSICS
G01S7/4915
PHYSICS
G01S17/32
PHYSICS
International classification
G01S17/32
PHYSICS
G01S17/894
PHYSICS
G01S7/4915
PHYSICS
Abstract
A method for depth measurement with a time-of-flight camera using amplitude-modulated continuous light by acquiring for each of a plurality of pixels of a sensor array of the camera at least one sample sequence having at least four amplitude samples (A.sub.0, A.sub.1, A.sub.2, A.sub.3) at a sampling frequency higher than a modulation frequency of the amplitude-modulated continuous light. The method further includes: determining for each sample sequence of each pixel a confidence value (C) indicating a degree of correspondence of the amplitude samples (A.sub.0, A.sub.1, A.sub.2, A.sub.3) with a sinusoidal time evolution of the amplitude; and determining for each of a plurality of binning areas, each of which comprises a plurality of pixels, a binned depth value (D.sub.b) based on the amplitude samples (A.sub.0, A.sub.1, A.sub.2, A.sub.3) of sample sequence of pixels from the binning area, wherein the contribution of a sample sequence to the binned depth value (D.sub.b) depends on its confidence value (C).
Claims
1. A method for depth measurement with a time-of-flight camera using amplitude-modulated continuous light, the method comprising: acquiring for each of a plurality of pixels of a sensor array of the camera at least one sample sequence comprising at least four amplitude samples at a sampling frequency higher than a modulation frequency of the amplitude-modulated continuous light; characterised in that the method further comprises: determining for each sample sequence of each pixel a confidence value indicating a degree of correspondence of the amplitude samples with a sinusoidal time evolution of the amplitude; and determining for each of a plurality of binning areas, each of which comprises a plurality of pixels, a binned depth value based on the amplitude samples of sample sequences of pixels from the binning area, wherein the contribution of a sample sequence to the binned depth value depends on its confidence value.
2. A method according to claim 1, further comprising acquiring four amplitude samples at a sampling frequency four times higher than a modulation frequency of the amplitude-modulated continuous light.
3. A method according to claim 1, further comprising acquiring, for at least one pixel, a plurality of sample sequences.
4. A method according to claim 1, wherein the confidence value is determined by a relation of the amplitude samples of an individual sample sequence to each other.
5. A method according to claim 1, further comprising: classifying each sample sequence as valid if the confidence value fulfills a predefined criterion and as invalid otherwise; and using the amplitude samples of a sample sequence to determine the binned depth value only if the sample sequence is valid.
6. A method according to claim 5, wherein the sample sequence is classified based on a relation of the confidence value to a first threshold value.
7. A method according to claim 1, wherein the binned depth value (DO is determined based on a linear combination of amplitude samples of sample sequences of pixels from the binning area, wherein the contribution of each sample sequence to the linear combination depends on the confidence value of the respective sample sequence.
8. A method according t claim 1, wherein the binned depth value is determined by averaging pixel depth values of sample sequences of pixels from the binning area, wherein a weight of each pixel depth value depends on the confidence value of the respective sample sequence of the respective pixel, an wherein the pixel depth value is determined based on the amplitude samples of the sample sequence of the pixel.
9. A method according to claim 1, further comprising determining a first difference between a first amplitude sample and a third amplitude sample of a sample sequence of a pixel, and assigning sample sequences having a positive first difference to a first group and sample sequences having a negative first difference to a second group.
10. A method according to claim 9, further comprising: defining a vector having a second difference between a second amplitude sample and a fourth amplitude sample as a first component and the first difference as a second component; defining a first group vector which is a linear combination, based on the confidence values of the respective sample sequence, of the vectors of the first group and a second group vector which is a linear combination, based on the confidence value of the respective sample sequence, of the vectors of the second group; and determining the binned depth value based on a phase difference between the second group vector and the first group vector.
11. A method according to claim 10, further comprising: determining the binned depth value based on both the first group vector and the second group vector if the phase difference is below a second threshold; and determining the binned depth value based on only one of the first group vector and the second group vector if the phase difference is above the second threshold.
12. A method according to claim 11, wherein the second threshold is 180°.
13. A method according to claim 11, wherein if the phase difference (Δϕ) is above the second threshold, the binned depth value is determined based on the group vector of the group having more valid sample sequences.
14. A method according to claim 1, further comprising: determining the binned depth value based on both the first group vector and the second group vector if the first components of both group vectors are negative; and determining the binned depth value (D.sub.b) based on only one of the first group vector and the second group vector if at least one first component is positive.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Further details and advantages of the present invention will be apparent from the following detailed description of not limiting embodiments with reference to the attached drawing, wherein:
[0032]
[0033]
[0034]
[0035]
[0036]
[0037]
[0038]
[0039]
[0040]
[0041]
[0042]
[0043]
[0044]
[0045]
[0046]
[0047]
[0048]
[0049]
[0050]
DETAILED DESCRIPTION
[0051]
[0052] A sinusoidal signal with amplitude A and phase can be represented by a 2D vector that can be determined from the 4 amplitude samples determined in the tap measurements, i.e.
r(A,ϕ)=(A.Math.cos ϕ,A.Math.sin ϕ)=(d.sub.13,d.sub.02) (eq. 1)
where d.sub.02=A.sub.0−A.sub.2, which is hereinafter referred to as a first difference, and d.sub.13=A.sub.1−A.sub.3, which is hereinafter referred to as a second difference, are the pairwise differences of two amplitude samples A.sub.k, k=0 . . . 3. The amplitude and phase of the received signal can therefore be computed as
ϕ=a tan 2(d.sub.02,d.sub.13) (eq.2)
A=√{square root over ((d.sub.02).sup.2+(d.sub.13).sup.2)} (eq. 3)
While the amplitude A of the signal is proportional to the number of the received photons, the phase ϕ is proportional to the depth D of the object seen by the corresponding pixels.
where D is the pixel depth value, i.e. the distance from the pixel of the camera, c is the speed of light and f.sub.mod is the modulation frequency of the signal. Accordingly, the depth can be calculated by
[0053]
[0054] However, motion artifacts can occur along the edges of an object 20 which is moving in the scene of the camera 1. As tap measurements are performed subsequently, a pixel 3 close to an object edge may “see” the object surface during the acquisition of one amplitude sample, while in a subsequent acquisition it may see the background.
[0055]
[0056] Due to the different depth and remission of the foreground and background object, the amplitude samples A.sub.k may vary drastically. As a consequence, the phase and depth computed according to eq.2 and eq.5 may be wrong. The result is illustrated by the diagram in
[0057] According to prior art, there are two main approaches to alleviate this problem, both of which make use of a binning method. A plurality of pixels, e.g. 4×4 pixels, are taken as a binning area, for which a single depth value is determined. In a first approach, the amplitude sample A.sub.k for all pixels in the binning area are summed and a single depth value is calculated using eq.2 (with the sums instead of the individual amplitude samples A.sub.k) and eq.5. This approach may be referred to as “tap binning”. The result of this is shown in
[0058] According to another approach, pixel depth values are determined for each individual pixel in the binning area and these pixel depth values are averaged to determine a depth value for the binning area. This approach may be referred to as “pixel binning”. The results are shown in
[0059] The abovementioned problems are reduced or eliminated by the inventive method.
[0060] After the start of the method, a binning area 4 is selected at 100. This may be e.g. an area comprising 4×4 pixels 3 (see also
[0061] where the amplitude A is computed according to eq.3, but can be approximated by
A=√{square root over ((d.sub.02).sup.2+(d.sub.13).sup.2)}≈MAX(|d.sub.02|,|d.sub.13|) (eq. 7)
[0062] By this definition, the confidence value C is always in the range between 0 and 1, with the highest possible value 1 representing a perfect sinusoidal function. At 140, this confidence value C is compared with a first threshold C.sub.min, which could be calculated, estimated or determined by calibration using a stationary scenery. In the following examples, the first threshold C.sub.min could be 0.25. The first threshold C.sub.min may also be referred to as a “motion parameter”, since it may be suitable to distinguish sample sequences that are affected by object motion from those that are unaffected by object motion. If the confidence value C is smaller than the first threshold C.sub.min, the respective sample sequence is classified as invalid at 190 and is basically not regarded further. If, on the other hand, the confidence value C is greater than the first threshold C.sub.min, the respective sample sequence is classified as valid at 150. The amplitude values or the first and second difference d.sub.02, d.sub.13, which can be regarded as second and first component of a vector, respectively, are kept for further processing.
[0063] This procedure can be regarded as a creation of a binary confidence mask, which is graphically illustrated in
[0064]
[0065] At 160, the sign of the first difference d.sub.02 is determined. If the sign is positive, the sample sequence and its vector are assigned to a first group at 170, and if the sign is negative, the sample sequence and its vector are assigned to a second group at 180. As indicated by the dashed arrows, the steps 160, 170 and 180 can also be skipped in a simplified version of the method.
[0066] The steps mentioned so far are repeated for all pixels 3 in the binning area 4 and, where applicable, for all sample sequences of each pixel 3. When it is determined at 200 that the last pixel 3 has been processed, the method continues at 210 by adding the vectors in the first and second group, respectively, to calculate a first group vector r.sub.P=[x.sub.Py.sub.P] and a second group vector r.sub.M=[x.sub.My.sub.M]. In other words, all vectors with a positive first difference d.sub.02 are summed and all vectors with a negative first difference d.sub.02 are summed. Therefore, the components of the first and second group vector r.sub.P, r.sub.M are calculated as follows, where the sum over multiple integration times is optional:
[0067] It should be noted that in either of the first and second group, only vectors of valid sample sequences are summed, while invalid sample sequences are disregarded for the binning process. The phases of any two vectors in the first group differ by less than 180°, wherefore the addition of these vectors cannot lead to flying pixels. The same applies to the vectors in the second group. The fact that the phases of the summed vectors differ by less than 180° guarantees that the resulting group vectors are not affected by the binning effect.
[0068] At 220, the phase difference ΔΦ of the second and first group vector is calculated (assuming both phases to be between 0° and 360°) and compared to a second threshold Φ.sub.max. In particular, the second threshold Φ.sub.max may be equal to 180°. If the phase difference ΔΦ is smaller, like in the example of
r.sub.b=r.sub.P+r.sub.M (eq. 10)
[0069] If the phase difference ΔΦ is greater, as shown in the example of
where N.sub.P, N.sub.M are the numbers of valid sample sequences in the first and second group, respectively. Finally, the binned depth value D.sub.b is determined based on the binned vector r.sub.b using eq.2 and eq.5.
[0070] If several sample sequences with several integration times It=1,2, . . . n are recorded, the binned values, e.g. the components x.sub.b, y.sub.b can be normalized as:
with N.sub.It being the number of pixels 3 with valid sample sequences for a specific integration time and T.sub.It being the length of the integration time. This yields a normalized amplitude which shows no artificial jumps as it is independent on the number of pixels 3 considered in the binning and thus allows to apply standard image processing methods, like stray light compensation to the binned taps or amplitude.
[0071] In the simplified version of the method indicated by the dashed line, all vectors of valid pixels 3 are added to determine the binned vector r.sub.b at 250:
Afterwards, the binned depth value D.sub.b is determined based on the binned vector r.sub.b.
[0072] There are two possible alternatives to checking the in equation for the phase difference ΔΦ at 220. First, one could check the following relation:
x.sub.My.sub.P<x.sub.Py.sub.M (eq. 13)
If so, the method continues at 230, if not, it continues at 240. This condition is in relation to the slope of a vector (x,y) which is proportional to y/x. For the crucial case of distinguishing whether the angle between two vectors is smaller or larger than 180°, either one of the vectors has to be in quadrant 1 and the other in quadrant 3 or one vector is located in quadrant 2, the other in quadrant 4. For any other case, the distinction is trivial. If one vector is in quadrant 1 and the other vector is in quadrant 4, the angle between the two vectors is obviously larger than 180°. If one vector is in quadrant 2 and the other vector is in quadrant 3, the angle between the two vectors is obviously smaller than 180°.
[0073] Second, one could decide whether both x.sub.P and x.sub.M are negative, which means that the object depth is close to half of the ambiguity depth. If so, the method continues at 230, if not, it continues at 240.
[0074]
[0075] If multiple sample sequences are acquired for each pixel 3, a pixel depth value is determined for each sample sequence individually, and eq.8 has to be modified to average over all valid sample sequences of all pixels 3 or over all valid pixels 3 of all integration times. The result of calculating the binned depth value D.sub.b is a low-resolution depth image, where the binned depth value D.sub.b represents the arithmetic mean of the valid pixels in the respective binning area 4.