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

IK performance decline #1

Open
kkevlar opened this issue Aug 6, 2018 · 0 comments
Open

IK performance decline #1

kkevlar opened this issue Aug 6, 2018 · 0 comments
Labels
bug Something isn't working complicated The fix/enhancement could take days to implement

Comments

@kkevlar
Copy link
Contributor

kkevlar commented Aug 6, 2018

It was observed that the IK solver took about 10 times longer to solve the same perturbation when moving from this commit to this commit. Next, I isolated the problem, and found that doubling the nodes in the cassie.xml file was causing the solver's performance to deteriorate.

In fact, removing all the nodes from the cassie.xml file, changing the NODECOUNT in main.h to zero and applying perturbation with Ctrl+P runs nearly twice as fast as the less slow commit. The problem has nothing to do with rendering/visualization because there are no scene updates while IK is being solved (just mj_step is called) and changing the opacity to 0 for the nodes in nodes_recolor() has no affect on the slowdown.

A potential fix is to create a separate version of the executable which does not have the nodes as part of the model file and doesn't have a OpenGL window, and have this new executable solve IK on the main program's behalf as a child process.

Another potential fix could be to somehow temporarily change the number of bodies, geoms, and joints in the MjModel structure before trying to solve IK so that the model effectively doesn't have any joints while the solver is running.

@kkevlar kkevlar added bug Something isn't working complicated The fix/enhancement could take days to implement labels Aug 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working complicated The fix/enhancement could take days to implement
Projects
None yet
Development

No branches or pull requests

1 participant