Skip to content

Commit

Permalink
chore(hesai): add decoder unit tests for OT128, QT128 (#214)
Browse files Browse the repository at this point in the history
Signed-off-by: Max SCHMELLER <[email protected]>
  • Loading branch information
mojomex authored Nov 1, 2024
1 parent 214373a commit 3fceb3d
Show file tree
Hide file tree
Showing 7 changed files with 58 additions and 2 deletions.
Binary file not shown.
26 changes: 26 additions & 0 deletions nebula_tests/data/hesai/ot128/1730271167765338806/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
rosbag2_bagfile_information:
version: 5
storage_identifier: ""
duration:
nanoseconds: 98498380
starting_time:
nanoseconds_since_epoch: 1730271167765338806
message_count: 2
topics_with_message_count:
- topic_metadata:
name: /pandar_packets
type: pandar_msgs/msg/PandarScan
serialization_format: cdr
offered_qos_profiles: "- history: 1\n depth: 5\n reliability: 2\n durability: 2\n deadline:\n sec: 9223372036\n nsec: 854775807\n lifespan:\n sec: 9223372036\n nsec: 854775807\n liveliness: 1\n liveliness_lease_duration:\n sec: 9223372036\n nsec: 854775807\n avoid_ros_namespace_conventions: false"
message_count: 2
compression_format: ""
compression_mode: ""
relative_file_paths:
- 1730271167765338806_0.db3
files:
- path: 1730271167765338806_0.db3
starting_time:
nanoseconds_since_epoch: 1730271167765338806
duration:
nanoseconds: 98498380
message_count: 2
Binary file not shown.
Binary file not shown.
26 changes: 26 additions & 0 deletions nebula_tests/data/hesai/qt128/1730273789074637152/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
rosbag2_bagfile_information:
version: 5
storage_identifier: ""
duration:
nanoseconds: 100122457
starting_time:
nanoseconds_since_epoch: 1730273789074637152
message_count: 2
topics_with_message_count:
- topic_metadata:
name: /pandar_packets
type: pandar_msgs/msg/PandarScan
serialization_format: cdr
offered_qos_profiles: "- history: 1\n depth: 5\n reliability: 2\n durability: 2\n deadline:\n sec: 9223372036\n nsec: 854775807\n lifespan:\n sec: 9223372036\n nsec: 854775807\n liveliness: 1\n liveliness_lease_duration:\n sec: 9223372036\n nsec: 854775807\n avoid_ros_namespace_conventions: false"
message_count: 2
compression_format: ""
compression_mode: ""
relative_file_paths:
- 1730273789074637152_0.db3
files:
- path: 1730273789074637152_0.db3
starting_time:
nanoseconds_since_epoch: 1730273789074637152
duration:
nanoseconds: 100122457
message_count: 2
Binary file not shown.
8 changes: 6 additions & 2 deletions nebula_tests/hesai/hesai_ros_decoder_test_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
namespace nebula::test
{

const nebula::ros::HesaiRosDecoderTestParams TEST_CONFIGS[6] = {
const nebula::ros::HesaiRosDecoderTestParams TEST_CONFIGS[8] = {
{"Pandar40P", "Dual", "Pandar40P.csv", "40p/1673400149412331409", "hesai", 0, 0.0, 0., 360., 0.3f,
200.f},
{"Pandar64", "Dual", "Pandar64.csv", "64/1673403880599376836", "hesai", 0, 0.0, 0., 360., 0.3f,
Expand All @@ -36,7 +36,11 @@ const nebula::ros::HesaiRosDecoderTestParams TEST_CONFIGS[6] = {
{"PandarXT32", "Dual", "PandarXT32.csv", "xt32/1673400677802009732", "hesai", 0, 0.0, 0., 360.,
0.05f, 120.f},
{"PandarXT32M", "LastStrongest", "PandarXT32M.csv", "xt32m/1660893203042895158", "hesai", 0, 0.0,
0., 360., 0.5f, 300.f}};
0., 360., 0.5f, 300.f},
{"PandarQT128", "LastStrongest", "PandarQT128.csv", "qt128/1730273789074637152", "hesai", 0, 0.0,
0., 360., 0.3f, 300.f},
{"Pandar128E4X", "LastStrongest", "Pandar128E4X.csv", "ot128/1730271167765338806", "hesai", 0,
0.0, 0., 360., 0.3f, 300.f}};

// Compares geometrical output of decoder against pre-recorded reference pointcloud.
TEST_P(DecoderTest, TestPcd)
Expand Down

0 comments on commit 3fceb3d

Please sign in to comment.