I have a rosbag
in which a /tf
topic is recorded.
I need to remap all tf
frames in that bag which refer to the frame named /world
to refer to a new frame named /vision
. I tried the following but it's unfortunately not working:
rosrun tf tf_remap _mappings:='[{old: /world, new: /vision}]'
Am I missing something?
I have also tried to do it from a launch file:
<launch>
<node pkg="tf" type="tf_remap" name="tf_remapper" output="screen">
<rosparam param="mappings">
- {old: "/world",
new: "/vision"}
</rosparam>
</node>
</launch>
Same result...
I found people saying that, in addition to running the tf_remap
node, rosbag
should be run as follows:
rosbag play x.bag /tf:=/tf_old
Also did that... still not working.
The tf_frame
s are still referring to /world
rather than /vision
.
Any help would be highly appreciated!
Edit
This is to clarify more what I am trying to achieve:
What I want is to remap all the frames recorded in the bag and referring to /world
, and make them refer to /vision
instead. There should be no /world
frame in the remapped output of the bag. Somewhere else in the code, I will define the frame named /world
and its relation to /vision
.