Open TobiasJacob opened 2 years ago
Thanks for bringing this up, I have a more general .vec() implemented but need to add the special case where only the quaternion is extracted.
Right now, you can extract the quaternion using the .vec() function which is implemented for each group. The vec() function is differentiable and extracts the vector embedding for each group. In the case of SE3, it will return a 7d vector with the translation and quaternion [t, q]
from lietorch import SE3
ex = SE3.Identity(1)
t, q = ex.vec().split([3,4], -1)
You can also initialize any group from a vector using the FromVec https://github.com/princeton-vl/lietorch#converting-between-groups-elements-and-euclidean-embeddings
This is a minimal example demonstrating the issue:
results in
A quick check reveals that the class Quat, referenced in
groups.py:139
is indeed not defined. A convenient method to extract the rotation/quaternion/SO3 object from an SE3 object would be helpful.