crocoddyl icon indicating copy to clipboard operation
crocoddyl copied to clipboard

selfadjointView may be a bottle neck

Open jcarpent opened this issue 4 years ago • 3 comments

https://github.com/loco-3d/crocoddyl/blob/d59b9be9f6c3f90b07dda12e5c14d8889cdc2214/src/multibody/actions/impulse-fwddyn.cpp#L122

From my knowledge of Eigen, selfadjointView may lead to slow computations. It may be better to fill the entire mass matrix M and then performing the dense computations.

jcarpent avatar Dec 03 '19 08:12 jcarpent

Thanks for the feedback. I will benchmark it asap!

cmastalli avatar Dec 03 '19 10:12 cmastalli

@proyan you might want to handle this issue.

cmastalli avatar Apr 02 '20 15:04 cmastalli

@jcarpent --- could I ask you (in your experience) when we should use selfadjointview (i.e., with which matrix dimension)?

As described here (https://stackoverflow.com/questions/39606224/does-eigen-have-self-transpose-multiply-optimization-like-h-transposeh), selfadjointview is not useful for small matrices. But it is not clear (in this post) what matrix dimensions are considered small

cmastalli avatar Sep 07 '21 10:09 cmastalli