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

Compare Ungar with OCS2 #8

Open
edward9503 opened this issue Dec 20, 2023 · 1 comment
Open

Compare Ungar with OCS2 #8

edward9503 opened this issue Dec 20, 2023 · 1 comment

Comments

@edward9503
Copy link

Dear @fdevinc ,

Thanks for sharing such impressive work!

I also used the OCS2 before. Since you are in the same university but different groups, I was wondering have you ever compared the performance and computational speed with the OCS2? Is there any compelling reason why we should use Ungar instead OCS2? Many thanks!_

@fdevinc
Copy link
Owner

fdevinc commented Dec 20, 2023

Dear @edward9503,

Thank you for your appreciation! Comparing OCS2 and Ungar:

  • OCS2 boasts a longer history and numerous contributors on GitHub, whereas Ungar is a newer, individual effort. Ungar is currently evolving, with plans to improve interfaces, add solvers, and reduce compile times; upcoming updates will enhance installability and external library handling.
  • OCS2 offers multiple solvers tailored for specific problem structures. In contrast, Ungar has only one that handles general sparse problems, albeit potentially slower. Ungar's optimizer is essentially the same as OCS2's SQP, but it uses the more versatile OSQP instead of HPIPM as a back end.
  • Ungar prioritizes user-friendliness and runtime efficiency, especially for moderate-sized problems. We plan to share hardware demos in the coming months to provide more insights into Ungar's performance.

If you are accustomed to OCS2 and appreciate its interfaces, sticking with it is definitely reasonable! Unlike Ungar, OCS2 is more extensive, but it comes with a potentially steeper learning curve and demands more boilerplate code for implementation—exemplified by the available robotic examples.

Finally, there is always the option to use both at the same time: for example, you may use Ungar variable maps to prevent bugs when handling indices (see lines from 43 to 69 here). This is not the most comprehensive answer, but I hope it helps!

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

2 participants