jedeschaud / ct_icp

CT-ICP: Continuous-Time LiDAR Odometry
MIT License
737 stars 127 forks source link

How to obtain the relative timestamps? #71

Open Hero941215 opened 1 year ago

Hero941215 commented 1 year ago

Hello authors,

You have completed a great job!

During the process of studying your article and code, I found that the relative timestamp range of each point you provided is [0,1]. The classic LOAM algorithm also seems to have a method for calculating relative timestamps (they use the first and last points of a frame to determine the angle at the beginning and end of the frame), and the calculated timestamps are not within the range of [0,1].

Therefore, I would like to know how you process the original point cloud data to obtain the relative timestamp of each point within the range of [0,1]?

pierdell commented 1 year ago

Hi,

The timestamps the frame are indeed set between 0 and 1, but all datasets are acquired at a frequency of 10Hz. To obtain the real timestamps, thus you can use the following formula:

$t_a = tr 0.1 + 0.1 I{frame}$

Where $I_{frame}$ is the index of the frame, and $t_r$ the relative timestamp.

Hero941215 commented 1 year ago

Thank you very much for your reply.

According to the formula you provided, when we can obtain the real timestamp of each point in a frame of point cloud, the relative timestamp can be further calculated, and the range is within [0,1].

However, the point cloud in KITTI-raw is stored in txt format and provides [x, y, z, intensity]. So, how is the real timestamp ta obtained?

pierdell commented 1 year ago

We provide a link to the raw-kitti datasets (which have timestamps).

To obtain this timestamps, we took the azimuth (yaw) angle and linearly interpolated between 0 and 1 Starting 0 towards the back of the car (180° with respect to the X-Axis), and going clockwise.

See the picture of the timestamps (blue means 0, red 1):

Capture d'écran 2023-05-26 09:26:47

Hero941215 commented 1 year ago

We provide a link to the raw-kitti datasets (which have timestamps).

To obtain this timestamps, we took the azimuth (yaw) angle and linearly interpolated between 0 and 1 Starting 0 towards the back of the car (180° with respect to the X-Axis), and going clockwise.

See the picture of the timestamps (blue means 0, red 1):

Thank you very much. I understand how the timestamp was obtained