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

Support SMPL and SMPLX #8

Open
zhaishengfu opened this issue Jul 23, 2021 · 9 comments
Open

Support SMPL and SMPLX #8

zhaishengfu opened this issue Jul 23, 2021 · 9 comments

Comments

@zhaishengfu
Copy link

Hello, wonderful projects.
I tested it and want to use SMPL parameter, but I find the error that said
"Loaded data appears to be from older SMPL model. supporting SMPL was taking up a lot of development time, " +
"so I disabled it. If you need this functionality, please contact me and I can get it working -Adam"

I think supporting SMPL is good for your project, and I do not know why it takes up a lot of time, because I think SMPL is subset of SMPL+H

@zhaishengfu
Copy link
Author

And , Can you support SMPLX model? I use SMPLX parameter and the translation seems not correct

@zhaishengfu zhaishengfu changed the title Support SMPL Support SMPL and SMPLX Aug 5, 2021
@AdamBebko
Copy link
Collaborator

Hi, Glad to hear you find the tool useful.

The main issue with supporting the other models is that I have to create and support different FBX files as the basis of each "Average" body model. Each one gets deformed differently in the different models, and have different pose-dependent blend shapes, so it basically requires maintaining 3 versions of the all the model scripts.

I can probably reactivate support for SMPL without too much work since I had it working before, but SMPL X will be much more work. I'll add it to the list of things to do, but I can't guarantee we can get to that. I'll be on vacation for much of August, but can try to restore SMPL functionality in September. Keep poking me if it's delayed too long after that

@AdamBebko
Copy link
Collaborator

Just to add: SMPL X (as well as all the dynamic soft tissue stuff), is definitely on our road map, but is currently not a huge priority for our lab. So we hope to get to it, but are currently focusing our small teams' efforts elsewhere

@zhaishengfu
Copy link
Author

Thanks for your reply!
Indeed in some cases, people do not need the full capacity 。 What I mean is, for SMPLX, I do not need dnamic soft tissue and so on . For SMPL/SMPLH/SMPLX, I only want to use the same pose in all of theses models. I try to see your AmassData.py and find your pose and translation data:
self.data_as_dict = {
"gender": self.gender,
"trans": self.trans,
"poses": self.poses_as_quaternion,
"betas": self.betas,
"dmpls": self.dmpls,
"fps": self.fps,
}
I wnat to know how SMPL and SMPLX parameters transfer to this format(only pose is enough for me.)
I tried myself with SMPL and SMPLX parameters(using Expose and so on), but the pelvis rotation and translation is not the same range with AMass sample data, so the final result is strange.

For example When using Expose (https://github.com/vchoutas/expose), I used "transl" for your global trans, but Expose's transl is in range like
(0.1, 0.1, 34)

and I see that AMass animation sample the 'trans" is in range like
(0.1, 0.1, 0.1)

So I think there are some information that I missed?

@AdamBebko
Copy link
Collaborator

Hmm well the matrices that are used to convert the animation data to a mesh are quite different. between the different models, since they use different average bodies for each one.

In general though, the poses are just a hierarchical tree of joint rotations, they should be pretty similar in all 3 models. If you read the original SMPLX paper, they do a pretty good job of explaining the different matrices involved. You can probably get the poses directly from the models that way in Python. Nima Ghorbani also has some good python scripts online that walk you through how to access the different data in the models in Python.

@liuhaorandezhanghao
Copy link

嗯嗯,用于将动画数据转换为网格的矩阵完全不同。在不同模型之间,因为它们对每个模型使用不同的平均身体。

但总的来说,姿势只是关节旋转的分层树,它们在所有 3 个模型中应该非常相似。如果您阅读原始 SMPLX 论文,他们会很好地解释所涉及的不同矩阵。您可能可以直接从 Python 中的模型中获取姿势。Nima Ghorbani 也有一些不错的在线 Python 脚本,可以引导您了解如何在 Python 中访问模型中的不同数据。

Hello, I reproduce smpl in unity and write a pose for its basic human model. I already have pose parameters for a certain frame, and I have a question to ask you.
That is, I saw that the pose parameters of the smpl folder are 72 for each frame. When looking at the original paper of smpl, I also have the same confusion: we use 3+3*23=72 parameters to represent each frame. Pose, here is the expression of the axis angle, that for any joint point we only have three parameters, but for the axis angle expression there should be four parameters, the rotation axis and the rotation vector, I checked some information, " "Visual Slam Fourteen Lectures" describes the rotation vector (we think that any rotation can be represented by a rotation and a rotation angle, so we use a vector whose direction is consistent with the rotation axis and the length is equal to the rotation angle. This vector is called Rotation vector, (or axis-angle), only a three-dimensional vector can describe the rotation).
The three parameters of a certain joint of smpl represent a vector, right, the direction of this vector is the axis of rotation, and the modulus of the vector is the angle of rotation? I think this parameter is basically between -1 and 1, so the calculated rotation angle is very small, and the result is wrong. Can not restore the predetermined posture.
Could you please give some pointers, how should I calculate the rotation axis and angle based on the pose parameter?

@AdamBebko
Copy link
Collaborator

I'm not sure I understood your question, but the pose rotations in the original SMPL model are expressed as exponential rotations, not as rotation vectors. I'm not sure why they did that, but I suspect it's to save on data storage size. Perhaps that is what is causing your confusion? I'm not affiliated with the SMPL people, I just made this tool! :)

@BingliangLi
Copy link

Just wondering can we still expect SMPL-X support in this project? Seems the development is paused for quite a long time.

@AdamBebko
Copy link
Collaborator

AdamBebko commented May 24, 2023 via email

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

4 participants