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

draw_sample(...) should throw an error for "invalid" input arguments #293

Open
patrikhuber opened this issue Jan 21, 2020 · 0 comments
Open

Comments

@patrikhuber
Copy link
Owner

Currently, the following code (in Python) produces a "faulty" mesh:

mesh_sample = morphable_model.draw_sample(shape_coefficients=[0.5, -0.5], expression_coefficients=[0.5, 0], color_coefficients=[0, 0.5])

Because expression_coefficients needs to be a complete vector:

blendshape_coeffs = np.zeros(len(morphable_model.get_expression_model()))
blendshape_coeffs[0] = 0.6  # Raise left mouth corner
mesh_sample = morphable_model.draw_sample(shape_coefficients=[0.5, -0.5], expression_coefficients=blendshape_coeffs, color_coefficients=[0, 0.5])

We should check the input arguments more rigorously.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant