Obtain the position and orientation information of the Isaac Sim simulated environment for JetBot

My code for retrieving the position and orientation of JetBot in the simulated environment is as follows:

The result displayed by the simulation software is as follows:

he return result of the Python code is as follows:

The position information from the displayed result corresponds correctly to the position in the simulation, but the orientation information does not match. What could be the reason for this discrepancy? How can I modify the code to correctly retrieve the orientation from the simulation?

@nick222446 i am just a fellow user passing by - looks like it’s displaying the orientation as quaternion as opposed to euler shown in GUI. there were a few threads about it that may be worth looking further into:

Change the coordinate in Isaac SIm - Omniverse / Isaac Sim - NVIDIA Developer Forums

this may be relevant api as well - Core [omni.isaac.core] — isaac_sim 2023.1.1-rc.8 documentation (nvidia.com)


Hi, @nick222446 , as mentioned by @Simplychenable , you have the different type of orientation here. You may want the euler angles, if I understood correctly.

I would like to suggest the following two things for you, you may use other API to get the euler angle or quaternions.

Or you can just click the red box in the following picture which can transfer the type.



1 Like

I have come across an API for converting to Euler angles, but I’m not sure what I need to import or how to call this API. Below is my understanding of it:
euler_angles = quat_to_euler_angles([-0.8080703, 0.00162996, 0.00224201, 0.5890796], bool=False, bool=False)
Would this code be sufficient to convert to Euler angles?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.