Closed davideCremona closed 4 years ago
Hi @davideCremona,
in the paper the horizontal and vertical focal lenghts are assumed to be the same, which they approximately are for most cameras. In the code, we want to account for slightly different horizontal and vertical focal lenghts that some users might have and the mean is just an estimate of the two ratios that should be very close in practice.
Hi,
I'm studying a little more your paper and I've a question: In the paper, you say that using the knowledge behind the pinhole camera model, you can find an estimation of the object distance using this formula:
t_hat_real = t_hat_synthetic * bbox_ratio * focal_length_ratio
Looking at the code, this is implemented by the line 100 of codebook.py:
z = diag_bb_ratio * mean_K_ratio * render_radius
but since
mean_K_ratio
is computed as:and K[0,0] is horizontal focal length in pixel units, K[1,1] is vertical focal length in pixel units I cannot relate the f_real/f_syn member of the paper formula. Are you using another method for computing the focal length ratio or it is an estimation of the real focal length ratio?
Thank you, Davide