- This is a shell script to remove unnecessary topic at rosbag2 playing.
- Ubuntu 20.04 LTS, ROS Galactic
- Ubuntu 22.04 LTS, ROS Humble
-
- Write Unnecessary topic in TOPIC_LIST
# Record topic with regular expressions
PERCEPTION_TOPIC=$(ros2 bag info $FILE_NAME | awk '{print $2}' | grep --regexp="/perception/*")
# topic list
TOPIC_LIST=(
/perception/object_recognition/detection/objects
/perception/object_recognition/tracking/objects
/perception/object_recognition/objects
)
chmod a+x remap_rosbag2.sh
./remap_rosbag2.sh file.db3