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

modify body_models #9

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Prev Previous commit
Next Next commit
🔨 add bias for smplx to fit with smpl
chingswy committed Sep 21, 2019
commit 83aa34ae949d71fb768b57cf249db45314a88fae
5 changes: 4 additions & 1 deletion smplx/body_models.py
Original file line number Diff line number Diff line change
@@ -269,7 +269,10 @@ def __init__(self, model_path, data_struct=None,
self.register_buffer('v_template',
to_tensor(to_np(data_struct.v_template),
dtype=dtype))

# add bias
if self.v_template.shape[0] == 10475:
bias = torch.Tensor(np.array([[0, 0.1728, 0.0218]]))
self.v_template = self.v_template + bias
# The shape components
shapedirs = data_struct.shapedirs
# The shape components