Skip to content

Commit

Permalink
Add visualization launch
Browse files Browse the repository at this point in the history
  • Loading branch information
tutunarsl committed Jun 29, 2024
1 parent 9d91737 commit fe4a9e2
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 4 deletions.
8 changes: 4 additions & 4 deletions smb_slam/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ For all the above cases, if you run in simulation, you can launch rviz by settin
3. Building a Map Offline (Replay Mode):

Run the following command to start running a replayer node that uses an external odometry specified in the launch file and the point cloud. Different than the online SLAM pipeline, this replayer runs sequentially. This means, the node will not skip measurements and instead it will wait for computation of the previous point cloud to finish before moving on. As a result, in compute limited systems might run slower than real-time and vice-versa, i.e. faster than real-time in powerful devices. This node saves the generated map, a rosbag that contains the registered point clouds as well as the calculated poses and finally, the path of the robot as a .pcd file such that the user can visualize the path next to the map. The saving folder is specified within the `.launch` file.

```
roslaunch smb_slam replay_SLAM.launch
```

> **Note**: The user is responsible to make sure that the specified topics are in the bag. The node will guide if there is something missing.

```
roslaunch smb_slam replay_SLAM.launch
```

### Map Saving

Expand Down
17 changes: 17 additions & 0 deletions smb_slam/launch/visualize_map.launch
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<launch>

<arg name="pcd_file_path" default="$(find smb_slam)/data/maps/map.pcd"/>
<arg name="rviz_config" default="$(find open3d_slam_ros)/rviz/visualizer_node.rviz"/>
<arg name="launch_rviz" default="true"/>

<node name="pointcloud_visualizer" pkg="open3d_slam_ros" type="visualizer_node" output="screen">
<param name="pcd_file_path" value="$(arg pcd_file_path)"/>
</node>

<node name="rviz_viz_of_map" pkg="rviz" type="rviz"
args="-d $(arg rviz_config)"
if="$(arg launch_rviz)">
</node>

</launch>

0 comments on commit fe4a9e2

Please sign in to comment.