How to get list of all tf frames programatically?
Hi all,
I have a question on how to obtain tf frames in a ros node (preferrably Python).
I am aware of the method tf2_ros.Buffer.lookup_transform()
, however, one has to specify source and target frame for that.
Lets say I have an array of known markers, but only a subset of them are detected by the camera. I want to know which of these markers are detected by looking at the existing tf frames. Is there a more elegant way to do so instead of looping over all possible markers and try to lookup the transform in a try catch block?
Thanks in advance!
P.S I am using kinetic on Ubuntu 16.04
EDIT:
In the tutorial TfUsingPython I found the method allFramesAsString()
but it seems to use tf, not tf2. would there be an equivalence in tf2? Or is it generally a bad practice to mix the use of tf and tf2?