Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On orientation/rotation state in DeepMimic. #175

Open
joonkyu4220 opened this issue Mar 23, 2022 · 3 comments
Open

On orientation/rotation state in DeepMimic. #175

joonkyu4220 opened this issue Mar 23, 2022 · 3 comments

Comments

@joonkyu4220
Copy link

joonkyu4220 commented Mar 23, 2022

Hello sir, thank you for sharing your marvelous work.

I am very much inspired by your DeepMimic paper, so I looked into your code.
While going through your code, I noticed some of the differences between what is written in the paper and what is implemented in the code.

In your paper it says

The state s describes the configuration of the character's body, with features consisting of the relative positions of each link with respect to the root (designated to be the pelvis), their rotations expressed in quaternions, and their linear and angular velocities.

However, in the code, if my understanding is correct, only position and (linear) velocity are being treated as 'state'.
I checked get_state_size in deepmimic_env.py leading to GetStateSize in DeepMimicCharController.cpp,
followed by GetStatePoseSize and GetStateVelSize, where mPosDim is fixed to 3, by GetPoseDim in the same file.
I also checked _record_state() in rl_agent.py, leading to RecordState in DeepMimicCharController.cpp, again referring to GetStatePoseSize and GetStateVelSize, to segment the pose vector.

The closest issue I found was issue 91, which didn't quite answer my question.
I apologize in advance, in case it's an issue already raised, or in case it's my misunderstanding of the codes.

Thank you also in advance, for your response.

@xbpeng
Copy link
Owner

xbpeng commented Mar 24, 2022

that's the base controller, the controller we actually use overrides the recordstate methods:

tMatrix origin_trans = mChar->BuildOriginTrans();

@joonkyu4220
Copy link
Author

Sorry I missed that, thank you for your response.
I'll close this issue right away.

@joonkyu4220
Copy link
Author

Sorry I missed that.
Thank you for your response.

Just one more thing before I close this issue, if I may.

In DeepMimic, you used quaternion to represent joint orientations in the state vector, and angle-axis to represent the target orientations(or, action).
But in the code, and in AMP, you seem to have switched to using normal-tangent representation and rotational vector(angle and axis multiplied), respectively.
Is the choice of your state and action representations based on some experiments that you have done?
Or is there any insight or postulation behind your decision?

Thank you again in advance.

@joonkyu4220 joonkyu4220 reopened this Mar 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants