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

weird geometry & texture on leg #14

Closed
ZunDuJiaDu opened this issue Dec 12, 2023 · 4 comments
Closed

weird geometry & texture on leg #14

ZunDuJiaDu opened this issue Dec 12, 2023 · 4 comments

Comments

@ZunDuJiaDu
Copy link

ZunDuJiaDu commented Dec 12, 2023

image
Anyone met the same weird geometry and texture on the leg?

I guess this is caused by the mismatch of SMPLX model and provided images. Do you have suggestions?

@huangyangyi
Copy link
Owner

Yes, this can happen when SMPL-X estimates are inaccurate. You can try passing a extra loss mask to mask out all the normal regularization loss and reconstruction losses in the incorrect area, in this part of the code

TeCH/core/lib/trainer.py

Lines 242 to 246 in 5efe7d6

if self.cfg.data.loss_mask is not None:
self.loss_mask = np.array(Image.open(self.cfg.data.loss_mask).resize(self.input_image.shape[1:]))[..., -1] / 255
self.loss_mask_norm = np.array(Image.open(self.cfg.data.loss_mask).resize((512, 512)))[..., -1] / 255
self.loss_mask = torch.tensor(self.loss_mask, dtype=torch.float).to(self.device).unsqueeze(0) * self.input_mask
self.loss_mask_norm = torch.tensor(self.loss_mask_norm, dtype=torch.float).to(self.device).unsqueeze(0) * self.normal_mask

@Subin-Kim46
Copy link

[Origin image]
image

[Mesh]
image

Thank you so much.
I want an outstretched leg on mesh. But, I got a folded leg like image.
Any suggestion for this error?

@huangyangyi
Copy link
Owner

The SMPL-X pose estimation method (PIXIE) we use often encounter such problem, you can try to replace the smplx estimation with Pymaf-x or other more advanced methods

@YuliangXiu
Copy link
Collaborator

@huangyangyi @Subin-Kim46 @ZunDuJiaDu

The issue of bending legs get resolved finally, please check out tricks.md/bending-legs.

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