-
Notifications
You must be signed in to change notification settings - Fork 279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Strict type checks (#197) on python interface of Buffer::setTransform make direct input from bagfile cumbersome #219
Comments
Good catch, I think that enforcing members |
awesome! |
Gave some thought to it, it would seem like we have to ensure that the members |
Previously introduced type check at the buffer::setTransform python interface checks the supplied variable against the strict geometry_msgs::Vector3 and geometry_msgs::Quaternion types[0]. This was later reported to make input from bag files cumbersome because of temporary intermediate types[1]. This relaxes the type check and only ensures that the expected members are present. It still issues a UserWarning about the type mismatch. [0] PR ros#197 [1] Issue ros#219
After the above patch is applied, with your test program we have:
|
Hi, I also ran into this (not so obvious) problem. It is also hard to work with the Python bindings, because the tf_ros2 documentation (for Python) in virtually nonexistent: http://docs.ros.org/kinetic/api/tf2_ros/html/python/tf2_ros.html |
@ros-pull-request-builder test this please |
@pklip A PR for filling out the documentation would be greatly appreciated. It's source is here: https://github.com/ros/geometry2/tree/indigo-devel/tf2_ros/doc |
) Previously introduced type check at the buffer::setTransform python interface checks the supplied variable against the strict geometry_msgs::Vector3 and geometry_msgs::Quaternion types[0]. This was later reported to make input from bag files cumbersome because of temporary intermediate types[1]. This relaxes the type check and only ensures that the expected members are present. It still issues a UserWarning about the type mismatch. [0] PR #197 [1] Issue #219
Fixed in #221 |
#197 introduced new type checks on the python interface of
Buffer::setTransform
to fix #159.Unfortunately this makes filling a tf buffer from a bagfile cumbersome, as bagfiles have their own type definitions for messages.
Here is an example program that demonstrates the problem:
This is the output:
To work around this you need to manually transform the type
tmpTmLCns._geometry_msgs__TransformStamped
to typegeometry_msgs.msg._TransformStamped.TransformStamped
.I would propose to make the type checks less strict, e.g. just enforcing that the transform has a member
translation
which has three floating point values and a memberrotation
that has four./cc @spaghetti-
The text was updated successfully, but these errors were encountered: