Open jviereck opened 4 years ago
You look for an entity or a Python function ?
I now understand your question. I don't see any QuaternionToRPY in src/matrix/operator.cpp so I guess there is none. I wouldn't be hard to write though.
I think I have an entity doing more or less that in sot-talos-balance
Thanks for providing the implementation in #121.
What I am missing is also how to get a dg:vector as a VectorQuaternion
. When I try to plug a dg::vector as input to a VectorQuaternion
, I am getting a type error.
Can you provide an example code ?
Here is a reduced example with the corresponding error message:
import dynamic_graph as dg
import dynamic_graph.sot.core
vec = dynamic_graph.sot.core.vector_constant.VectorConstant('vc')
vec.sout.value = (0, 0, 0, 1)
op = dynamic_graph.sot.core.operator.QuaternionToMatrix('q2m')
dg.plug(vec.sout, op.sin)
# dgpyError: Compl. Uncompatible types for plugin.(while trying to plug
# <sotVectorConstant(vc)::output(vector)::sout> on
# <QuaternionToMatrix(q2m)::input(VectorQuaternion)::sin>) with types
# <N5Eigen10QuaternionIdLi0EEE> on <PN12dynamicgraph10SignalBaseIiEE>.
I see your problem. I don't think it is implemented.
Hi,
given a dg::vector representing a quaternion as
x, y, z, w
, is there a way to convert it to a rpy vector?There is a
QuaternionToMatrix
andMatrixToRPY
entity here 1. However, I cannot figure out how to get adg::vector
into aVectorQuaternion
type.Best Julian