Closed mamoll closed 9 years ago
Original report by dhiraj gandhi (Bitbucket: g.prakashchand@gmail.com, ).
Hello all,
I tried to use the function dubins() , defined in DubinsStateSpace() in class in python.
But it is giving error that the 'DubinsStateSpace' object has no attribute 'dubins'.
So is this function only available in C++ or I'm doing some mistake in implementation please let me know.
following is the code
space = ob.DubinsStateSpace(0.2) bounds = ob.RealVectorBounds(2) bounds.setLow(-2) bounds.setHigh(2) space.setBounds(bounds) start = ob.State(space) start().setX(-0.5) start().setY(-0.5) start().setYaw(0) goal = ob.State(space) goal().setX(0.5) goal().setY(0.5) goal().setYaw(0) path = space.dubins(start(),goal())
Original comment by Mark Moll (Bitbucket: mamoll, GitHub: mamoll).
The dubbing function is not exposed in python. You can do the following to get states along a Dubins curve connecting two states:
s = ob.State(space) for i in range(10): space.interpolate(start(), goal(), i/10., s()) print(s)
Original comment by dhiraj gandhi (Bitbucket: g.prakashchand@gmail.com, ).
Thank you very much for your reply.
Exactly the same point came to my mind, I tried it, it worked.
Thanks a lot for suggestion.
Original report by dhiraj gandhi (Bitbucket: g.prakashchand@gmail.com, ).
Hello all,
I tried to use the function dubins() , defined in DubinsStateSpace() in class in python.
But it is giving error that the 'DubinsStateSpace' object has no attribute 'dubins'.
So is this function only available in C++ or I'm doing some mistake in implementation please let me know.
following is the code