Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: change the parameters so that there would be no LiDAR flicker #372

Open
wants to merge 1 commit into
base: tier4/universe
Choose a base branch
from

Conversation

SakodaShintaro
Copy link
Contributor

@SakodaShintaro SakodaShintaro commented Jan 22, 2025

After merging #337, the LiDAR started flickering when using logging_simulator with the sample rosbag.

Result

Without this PR :

Screencast.from.2025.01.22.11.20.22.webm

With this PR :

Screencast.from.2025.01.22.11.28.04.webm

Test Procedure

ros2 launch autoware_launch logging_simulator.launch.xml \
    map_path:=$HOME/autoware_map/sample-map-rosbag \
    vehicle_model:=lexus \
    sensor_model:=aip_xx1 
ros2 bag play $HOME/autoware_map/sample-rosbag/sample.db3 -r 1.0 -s sqlite3

@SakodaShintaro SakodaShintaro self-assigned this Jan 22, 2025
Copy link
Contributor

@vividf vividf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR should not be changed in this way. The method you are using to run the rosbag is incorrect because the sample rosbag uses a different timestamp system than the current xx1 timestamp system.

To properly run the sample rosbag, you need to use the sample sensor kit parameters:
Sample Sensor Kit Parameters.

Note that the current xx1 parameter is tested with the latest xx1 release, so the parameter shouldn't be changed.

@SakodaShintaro
Copy link
Contributor Author

SakodaShintaro commented Jan 22, 2025

@vividf

I see.
The sample rosbag does not have LiDAR data for the rear.

$ ros2 bag info ~/autoware_map/sample-rosbag

Files:             sample.db3
Bag size:          262.7 MiB
Storage id:        sqlite3
Duration:          29.874325231s
Start:             Feb 26 2021 14:02:26.338218272 (1614315746.338218272)
End:               Feb 26 2021 14:02:56.212543503 (1614315776.212543503)
Messages:          8262
Topic information: Topic: /clock | Type: rosgraph_msgs/msg/Clock | Count: 2941 | Serialization Format: cdr
                   Topic: /sensing/gnss/ublox/fix_velocity | Type: geometry_msgs/msg/TwistWithCovarianceStamped | Count: 30 | Serialization Format: cdr
                   Topic: /sensing/gnss/ublox/nav_sat_fix | Type: sensor_msgs/msg/NavSatFix | Count: 30 | Serialization Format: cdr
                   Topic: /sensing/gnss/ublox/navpvt | Type: ublox_msgs/msg/NavPVT | Count: 30 | Serialization Format: cdr
                   Topic: /sensing/imu/tamagawa/imu_raw | Type: sensor_msgs/msg/Imu | Count: 853 | Serialization Format: cdr
                   Topic: /sensing/lidar/left/velodyne_packets | Type: velodyne_msgs/msg/VelodyneScan | Count: 299 | Serialization Format: cdr
                   Topic: /sensing/lidar/right/velodyne_packets | Type: velodyne_msgs/msg/VelodyneScan | Count: 299 | Serialization Format: cdr
                   Topic: /sensing/lidar/top/velodyne_packets | Type: velodyne_msgs/msg/VelodyneScan | Count: 288 | Serialization Format: cdr
                   Topic: /vehicle/status/control_mode | Type: autoware_vehicle_msgs/msg/ControlModeReport | Count: 873 | Serialization Format: cdr
                   Topic: /vehicle/status/gear_status | Type: autoware_vehicle_msgs/msg/GearReport | Count: 873 | Serialization Format: cdr
                   Topic: /vehicle/status/steering_status | Type: autoware_vehicle_msgs/SteeringReport | Count: 873 | Serialization Format: cdr
                   Topic: /vehicle/status/velocity_status | Type: autoware_vehicle_msgs/msg/VelocityReport | Count: 873 | Serialization Format: cdr

Is it correct to say that such data can no longer be handled by the xx1 launcher?
This is a new restriction.

And what data did you use in your test?

#337 (comment)

@vividf
Copy link
Contributor

vividf commented Jan 23, 2025

@SakodaShintaro
Yes, the sample rosbag is too old and uses the latest xx1 parameters.
I tested the data with release v0.47 (I cannot tell which rosbag I am using since I just randomly down one of the rosbag from the website)

@a-maumau
Copy link
Contributor

a-maumau commented Jan 24, 2025

It might only target versions >=v0.47 for xx1, but I will leave a comment for reference.

I have encountered with the similar problem which seems left LiDAR and other LiDARs get separated (this makes kind of a flickering phenomenon).
The rosbag that I used was recorded in beta/v0.47.
Fixing the lidar_timestamp_noise_window to this PR's value solves the issue.

For testing the latest features on older versions, we might need to relax the window size.

@vividf
Copy link
Contributor

vividf commented Jan 24, 2025

@a-maumau
Thanks for your comment.

Increasing the noise window value is usually not the right approach to solving this issue. The noise window is necessary because Velodyne sensors do not publish timestamps perfectly every 100 ms.

Additionally, if you're using Vehicle 4 data, it won’t work because PTP has been out of sync for several months.

The correct way to determine whether parameter adjustments are needed is:

  1. Understand the logic behind the timestamp offset and noise window by referring to the README.
  2. Check your sensor’s timestamp and adjust the timestamp_offset value accordingly.
  3. Avoid modifying the noise window unless absolutely necessary. For example, setting it to 0.08 is not ideal, as it might cause the system to randomly match point clouds.

Hope this helps! Let me know if you have any questions.

@SakodaShintaro
Copy link
Contributor Author

@a-maumau
Thank you for the information.

The rosbag I used was recorded in beta/v0.47.

Can you tell me the link to the data search?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants