Skip to content

Commit 1ad7f34

Browse files
authored
Add MANO loader
1 parent f1f0017 commit 1ad7f34

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

smplx/body_models.py

+4
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,17 @@ def create(model_path, model_type='smpl',
9191
# If it's a folder, assume
9292
if osp.isdir(model_path):
9393
model_path = os.path.join(model_path, model_type)
94+
else:
95+
model_type = osp.basename(model_path).split('_')[0].lower()
9496

9597
if model_type.lower() == 'smpl':
9698
return SMPL(model_path, **kwargs)
9799
elif model_type.lower() == 'smplh':
98100
return SMPLH(model_path, **kwargs)
99101
elif model_type.lower() == 'smplx':
100102
return SMPLX(model_path, **kwargs)
103+
elif 'mano' in model_type.lower():
104+
return MANO(model_path, **kwargs)
101105
else:
102106
raise ValueError('Unknown model type {}, exiting!'.format(model_type))
103107

0 commit comments

Comments
 (0)