uwgraphics / relaxed_ik

RelaxedIK Solver
MIT License
186 stars 50 forks source link

System performance and speed #6

Closed supsensei closed 5 years ago

supsensei commented 5 years ago

Hi - I am working on a 2-arm robot and running through the process. All seems to be working, but having speed issues. I am running on 12-core Intel Xeon 3.6GHz that runs all cores about 40%. I am only getting update rates around 5-10Hz. I notice when I turn down the max iterations on the solve function in relaxed_ik.py I get performance boost to ~50Hz (soln suffers a bit). I see the same issue running the sample.py or my custom config using the relaxed_ik node with pub/subscribe.

On your default config with ur5. I get about 40hz (which is inline with your posted #s) on /relaxed_ik/ee_pose_goals and then drop the max iterations to 2 and get 110 Hz. How did you select 11 iterations?

I am not seeing the results you published in your paper on speed for a 2 arm config. Other things I could check here.

djrakita commented 5 years ago

Hi, Your reported frequencies are definitely consistent with what I've seen on our computer with similar specs. The 11 iterations isn't really a magic number, it was just the sweet spot I found between good quality and good performance when doing tests.

The relatively slow performance with two chains (~10Hz like you mentioned) and even slower with more chains in the system was what pushed us to rewrite things in Julia rather than Python.

The Julia version of the solver (which will be pushed to the main branch within the next couple weeks) gets about 350-400Hz on a single arm system, about 125-150Hz on a two-arm system, and close to 2000Hz if it's used as a "standard" IK solver (i.e., taking out collision avoidance and other feasibility considerations). And these were tested on an HP Pavilion laptop with a 2.6 GHz i7-6700HQ CPU with 32 GB RAM, so these times should be faster on a more capable workstation.

I'll keep you posted on here when the new version goes live! I think it'll work much better for the 2-arm system you are working with. Just let me know if you have any questions in the meantime!

supsensei commented 5 years ago

Thanks for the info and look forward to the update - keep at it!