Comments (10)
There are none. The efficiency of the library comes from the
template-based programming, mostly implemented in the joint classes.
Maybe you mismatch with Metapod (the beta version of Pinocchio). I think
you will find Pinocchio more comfortable to use, while the performances
are quite similar to Metapod.
On 04/07/2016 05:30 PM, lengagne wrote:
Hi,
I succeed to make the benchmark work.
Is it possible to have access to the optimized code that is generated
by pinocchio
(not the generated library, but the c/c++ code that is generated) ?I cannot find any *.c or *.cpp files that are generated.
Thanks
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#146
from pinocchio.
To be more consistent, Pinocchio exploits metaprograming and implements similar tricks than Eigen (but with maybe less grace). For further details, there is a paper (https://hal.archives-ouvertes.fr/hal-01122475) explaining the way Metapod works (and in some points, Pinocchio).
And, if you install EigenPy (a binding between Eigen and Numpy - https://github.com/stack-of-tasks/eigenpy), you can also use Pinocchio with Python. You have also tutorials to learn the API:
- Build a robot: http://homepages.laas.fr/nmansard/teach/robotics2015/1-build-your-robot.html
- Graps an object: http://homepages.laas.fr/nmansard/teach/robotics2015/2-grasp-an-object.html
- Static walk: http://homepages.laas.fr/nmansard/teach/robotics2015/3-static-walk.html
- Dynamic walk: http://homepages.laas.fr/nmansard/teach/robotics2015/4-dynamic-walk.html
Finally, in the build directory, you can do make doc
to produce the current documentation (which is only partial but will be updated in the near future).
from pinocchio.
On rather new CPU pinocchio is faster than Metapod (this is why I decided to stop development on Metapod), The gain on CPU such as ATOMs than you can find in Romeo is marginal compare to the overall cost, and the rigidity of Metapod,
The biggest advantage of Pinocchio over Metapod is the fact that you can change your model on line.
Metaprogramming has been kept only in the relevant part by @nmansard . Code generated automatically may impact the performances by preloading data and code from the memory (as specified by Featherstone in his book). I believe Pinocchio is currently the best solution that we have tried so far.
from pinocchio.
Ok, so
If I want to have optimized code (not optimized execution time), do I have to use at Metapod ?
Does pinocchio is able to deal wth template for variables q,qdot, ..., in order to consider other type than double ?
Thank you for your help.
from pinocchio.
Currently, double is the default Scalar type. A future PR will be proposed by @fvalenza to define a scalar_t which can be either float, double, etc. This will be very useful for Romeo or Nao because of Atom processors.
What do you mean by optimised code? What is your purpose?
from pinocchio.
The point is that pinocchio has been optimized for nowadays CPU (typically Intel(R) Core(TM) i7-4710MQ CPU @ 2.50GHz with 6Mo of L2 cache) .
As I said before loops may be much more efficient that loop unrolling due to the time taken to fetch data and code from the memory.
It is a codesign approach: the code fits the hardware it is running on.
from pinocchio.
"the code fits the hardware it is running on."
indeed my first goal is to do the same but with different hardware (shh it is secret).
So we would like to have access to the matrix and vector of the inverse dynamic model.
My second goal is to use pinocchio with automatic differentiation and interval classes.
from pinocchio.
Metapod is generating code to describe the robot, not dedicated code for
the algorithms. It will not be more useful to you than Pinocchio.
For automatic generation of algo loops, you have to dive inside the old
versions of JRL-dynamics and Humans by PBW.
Pinocchio has two parts. The first one implements the spatial algebra of
Featherstone. The second part implements the robot model and the
algorithms to compute model values, using the first part.
The first part is templated, and should be able to handle automatic
differencing, although it has been hardly tested exept for double (and
maybe float). However, you have some strong unittests that you can
extend to automatic differenciation.
The second part is not templated but only works for double. It would be
useful to template it. However, we do not have the manpower yet to do
so. We would be happy to support your team if you volunteer to do so.
Moving from double to float should not be a big effort. Possibly, moving
to more exotic types, like complex for automatic differencing, may be
more tedious.
With respect to your final objective of finite differencing, I would
suggest to start from the spacial algebra implemented in Pinocchio, and
implement a dedicated version of RNEA. This is not a long term solution,
but is doubtlessly the simplest to implement. I can guide you to
re-implement RNEA is need be.
On 04/08/2016 10:35 AM, lengagne wrote:
Ok, so
If I want to have optimized code (not optimized execution time), do I
have to use at Metapod ?Does pinocchio is able to deal wth template for variables q,qdot, ...,
in order to consider other type than double ?Thank you for your help.
—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#146 (comment)
from pinocchio.
Hi,
I am interested to add template to pinocchio. I am not sure I have the abilities but it is something interesting in the future.
For the moment I will have a look at humans and compare pinocchio with my template implementation of robotics algorithm (modified from the work of Martin Felis)
from pinocchio.
@jcarpent is about to push a cleaner version of spatial algebra, where it should be possible to do automatic derivation. We are not planning to template the joint yet.
from pinocchio.
Related Issues (20)
- Error while running the rviz-viewer.py HOT 1
- Calculation issue of `getFrameJacobianTimeVariation` HOT 10
- Installing via Linux fails from today (2024.01.31.) HOT 5
- getJointJacobian() error HOT 2
- Compilation Issues with Pinocchio Headers on Windows Using MSVC and Clang HOT 9
- Meshcat visualizer error when collision model is undefined HOT 1
- Failed to install Pinocchio on Jetson Orin HOT 5
- pin.constraintDynamics and data.lambda_c HOT 2
- compilation error for C++ casadi pinocchio::difference HOT 3
- Compatibility with older Boost versions on Windows HOT 4
- `getJointJacobian` works weirdly for independent robots HOT 1
- Call non-static member function isNormalized() in static function integrate_impl() HOT 4
- computecollisions() missing from ros humble installation HOT 7
- VS Tools installation bug HOT 1
- Parent frame of GeometryObject changes after calling BuildReducedModel HOT 7
- ImportError: cannot import name 'casadi' from 'pinocchio' HOT 2
- Create model with uncertainty (unkown paramters that can be updated online)
- Incomplete Function Auto-Completion and highlight in VSCode after Installing Pinocchio via Conda HOT 10
- Add arm64 macOS wheels to releases HOT 4
- Possible unnecessary computation in computeMinverse HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pinocchio.