pointcloudset CLI

The best way to work with large ROS1 or ROS2 files is to convert the rosbag beforehand with the provided command line tool.

It is also possible to convert whole or parts of ROS files to the native file formats supported by pointcloudset:

.csv / .xyz .las .pcd

For text formats, the Python API supports both headered and headerless files. csv writes a header by default and xyz writes no header by default. The CLI uses those defaults.

Example

An example to convert topic /os1_cloud_node/point within the test.bag rosbag to the converted directory.

pointcloudset convert -t /os1_cloud_node/points -d converted test.bag

List all PointCloud2 topics in a ROS file.

pointcloudset topics test.bag

pointcloudset

pointcloudset [OPTIONS] COMMAND [ARGS]...

Options

--install-completion

Install completion for the current shell.

--show-completion

Show completion for the current shell, to copy it or customize the installation.

convert

The main CLI function to convert ROS1 and ROS2 files to pointcloudset or native file formats supported by pointcloudset.

Examples:

convert all ROS1 bag files in a directory $ pointcloudset convert . -d converted

convert all frames of bagfile xyz.bag into csv files $ pointcloudset convert xyz.bag -o csv -d converted_csv xyz.bag

convert a ROS2 directoy to a pointcloudset file $ pointcloudset convert something_ros2 -d converted

convert the first 10 frames of a bag file int0las files $ pointcloudset convert xyz.bag -o las -d converted_las –start 1 –end 10

pointcloudset convert [OPTIONS] ROS_FILE

Options

-t, --topic <topic>
Default:

'/os1_cloud_node/points'

-d, --output-dir <folder_to_write>
Default:

'.'

-o, --output-format <output_format>
Default:

'POINTCLOUDSET'

-s, --start <start_frame_number>
Default:

0

-e, --end <end_frame_number>
--keep-zeros, --no-keep-zeros
Default:

False

Arguments

ROS_FILE

Required argument

topics

List all ROS PointCloud2 topics which can be converted.

Args:

ros_file (str): ROS1 or ROS2 file or directory

Examples:

show all PointCloud2 topis in a ROS1 bag file $ pointcloudset topics test.bag

pointcloudset topics [OPTIONS] ROS_FILE

Arguments

ROS_FILE

Required argument