stereolabs / zed-ros-wrapper

ROS wrapper for the ZED SDK
https://www.stereolabs.com/docs/ros/
MIT License
447 stars 391 forks source link

Actual timestamp for IMU and Images when SVO playback #872

Closed umbnich closed 1 year ago

umbnich commented 1 year ago

Preliminary Checks

Description

Hi, I’m playbacking an SVO recorded a month ago. When I echo the …/imu/data/header the stamp refers to the epoch at which the SVO was recorded while if I echo the …/left_raw/image_raw_color/header the stamp refers to the current epoch (grab frame epoch?).

I want to have both the imu and images data to be synchronized and refer to the date when the SVO was recorded. Is this possible?

The final purpose is to use the ZED2i sensors with other external sensors, all synchronized.

Thank you

Steps to Reproduce

In sync.yaml:

zed_nodelet_name:   'zed2i_node'      # Default name of the ZEDWrapperNodelet publishing topics (normally overwritten in launch file)
approx_sync:        true           # Use approximate synchronization for the input topics. If `false` all the message must have the same timestamp, this is almost impossible if subscribing also to IMU and Magnetometer topics and the parameter `sensors_timestamp_sync` is false in the ZED nodelet
queue_size:         600            # Size of message queue for each synchronized topic (more than 1 second of buffer for IMU data)
sub_imu:            true            # Synchronize IMU messages
sub_mag:            true            # Synchronize Magnetometer messages

But I also tried setting all false.

  1. Launch roslaunch zed_nodelet_example zed_sync_nodelet.launch camera_model:=zed2i svo_file:="path_to_svo.svo"
  2. Echo both imu/data/header and image_raw_color/header rostopic echo /zed2i/zed_nodelet/imu/data/header -> stamp/secs is 1666105792 (epoch at which the svo was recorded) rostopic echo /zed2i/zed_nodelet/left_raw/image_raw_color/header -> stamp/secs is now (epoch at which the code is running)

Expected Result

IMU and Images timestamps are equal and refer to the epoch at which the SVO was recorded

Actual Result

IMU and Images timestamps are different. IMU refers at the epoch at which the SVO was recorded while Images refers to the current epoch.

ZED Camera model

ZED2i

Environment

OS: Ubuntu 20.04.5 LTS
CPU: Intel(R) Core(TM) i9-8950HK CPU @ 2.90GHz
GPU: NVIDIA GeForce GTX 1050 Ti with Max-Q
ZED SDK: 3.8.1
CUDA: 11.7.99 (v11.7)

Anything else?

No response

github-actions[bot] commented 1 year ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment otherwise it will be automatically closed in 5 days