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

Speed Improvements #13

Open
alberthli opened this issue Oct 25, 2024 · 0 comments
Open

Speed Improvements #13

alberthli opened this issue Oct 25, 2024 · 0 comments

Comments

@alberthli
Copy link
Collaborator

As per discussion, there are a number of possible speed improvements we can make to hydrax to move towards deploying on hardware. Here are a few things (list is living, can be updated any time):

  • use XLA_FLAGS=--xla_gpu_triton_gemm_any=true. We can set this using os in the __init__.py file of hydrax to just always have it on
  • the get_action call, which simply queries the control spline at a certain time, actually has a measurable effect on the speed of the planning loop. we should consider doing all the spline querying on CPU and just moving the nominal spline knots from GPU to CPU, which should incur a low device transfer cost
    • moreover, when deploying online, the spline querying should not happen on the hydrax side anyway, so this is a low prio fix that should only affect the runtime of the sim loop
  • the replace call has a small but measurable effect on the runtime. this is probably unavoidable, however.
  • the majority of the speed improvements should come from messing with the internals of the controller.optimize function.
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

1 participant