ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

Geometry tools for python

asked 2012-10-08 02:33:06 -0600

updated 2014-01-28 17:13:53 -0600

ngrennan gravatar image

I want to perform some basic geometry computations using python, for example calculating the euclidean distance between two points. Of course, implementing that is easy enough, but littering code with this kind of basic functions seems pretty redundant.

Searching for a existing solution I only found the pr2_python package. This is basically exactly what I'm looking for, but it is not available as a package from .debs and very heavyweight in it's dependencies.

Any other options, or is everyone just copying and pasting as needed? :)

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
2

answered 2012-10-08 03:05:05 -0600

Lorenz gravatar image

Alternatives might be numpy/scipy and the tf.transformations library that you can find in tf/src/tf/transformations.py. PyKDL could work, too.

edit flag offensive delete link more
3

answered 2012-10-08 08:28:37 -0600

jbinney gravatar image

I think a lot of people have their own file of python geometry functions - pr2_python is the result of merging a few of ours into one file. The functions use tf.transformations, and provide a little higher level, ros specific functionality, such as converting between transform messages and homogeneous matrices. If there's enough interest, maybe we could clean up that file and move it somewhere in the geometry stack. Until then you can copy the files you need out of pr2_python (they should only depend on tf, numpy, and a couple other things)

edit flag offensive delete link more

Comments

1

There's a lot of stuff in pr2_python that I've found quite useful, though not always quite right. The heavyweight dependencies are an issue I've noticed too. If you wanted to move it over to github (and maybe split some of the pieces out), I'd be more than happy to help out.

Dan Lazewatsky gravatar image Dan Lazewatsky  ( 2012-10-08 09:12:48 -0600 )edit

Question Tools

Stats

Asked: 2012-10-08 02:33:06 -0600

Seen: 482 times

Last updated: Oct 08 '12