I could not get Wil Selby's code to work out of the box, neither the source code nor the Docker image. I kept running into protoc errors, even in the Docker image. I suspect it's a dependency issue.
Here's how I got it to work on Ubuntu 18.04 LTS, circa Sept. 10, 2020. I have only tested this on data from the OS1-64.
Install Cartographer ROS
Use the Cartographer ROS installation instructions (click here) and make sure to source the /home/<your directory>/cartographer_ros/install_isolated/setup.bash
file.
Configure Cartographer ROS to Use OS1 Data
This is where Wil Selby's code comes in handy.
Download Wil Selby's fork of ouster_example.
cd <any directory>
git clone https://github.com/wilselby/ouster_example.git
Copy all the folders and files from wilselby/ouster_example/cartographer_ros
to cartographer_ros/install_isolated/share/cartographer_ros
.
├── configuration_files
│ ├── assets_writer_cart_2d.lua
│ ├── assets_writer_cart_3d.lua
│ ├── cart_2d.lua
│ ├── cart_3d.lua
│ ├── demo_2d.rviz
│ ├── demo_3d.rviz
│ └── transform.lua
├── launch
│ ├── assets_writer_cart_2d.launch
│ ├── assets_writer_cart_3d.launch
│ ├── cart_2d.launch
│ ├── cart_3d.launch
│ ├── demo_cart_2d.launch
│ ├── demo_cart_3d.launch
│ ├── offline_cart_2d.launch
│ └── offline_cart_3d.launch
└── urdf
│ └── os1_sensor.urdf
Modify the .launch files.
Open each launch file from step 2 and edit the directory and file references to reflect your installation in the install_isolated
directory.
Run Cartographer ROS
roslaunch cartographer_ros <launch file> bag_filename:=<full path to your rosbag file>
Wil Selby's Sample Data
curl -O https://data.ouster.io/downloads/office_demo_9_25_19.bag
References