pinocchio

A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives

https://github.com/stack-of-tasks/pinocchio

Science Score: 64.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
    Links to: scholar.google
  • Committers with academic emails
    19 of 94 committers (20.2%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (15.3%) to scientific vocabulary

Keywords

analytical-derivatives automatic-differentiation c-plus-plus casadi code-generation conda cppad dynamics fcl kinematics motion-planning pinocchio python rigid-body-dynamics robotics ros urdf

Keywords from Contributors

quadratic-programming eigen3 nonlinear-optimization proximal-algorithms optimal-control modular mathematics nonlinear energy-system-model derivatives
Last synced: 4 months ago · JSON representation ·

Repository

A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives

Basic Info
Statistics
  • Stars: 2,637
  • Watchers: 64
  • Forks: 458
  • Open Issues: 101
  • Releases: 87
Topics
analytical-derivatives automatic-differentiation c-plus-plus casadi code-generation conda cppad dynamics fcl kinematics motion-planning pinocchio python rigid-body-dynamics robotics ros urdf
Created about 11 years ago · Last pushed 4 months ago
Metadata Files
Readme Changelog License Citation

README.md

Pinocchio Logo

License Documentation Coverage Report Conda Downloads Conda Version PyPI version pre-commit.ci status

Pinocchio instantiates the state-of-the-art Rigid Body Algorithms for poly-articulated systems based on revisited Roy Featherstone's algorithms. Besides, Pinocchio provides the analytical derivatives of the main Rigid-Body Algorithms, such as the Recursive Newton-Euler Algorithm or the Articulated-Body Algorithm.

Pinocchio was first tailored for robotics applications, but it can be used in other contexts (biomechanics, computer graphics, vision, etc.). It is built upon Eigen for linear algebra and FCL for collision detection. Pinocchio comes with a Python interface for fast code prototyping, directly accessible through Conda.

Pinocchio is now at the heart of various robotics software as Crocoddyl, an open-source and efficient Differential Dynamic Programming solver for robotics, the Stack-of-Tasks, an open-source and versatile hierarchical controller framework or the Humanoid Path Planner, open-source software for Motion and Manipulation Planning.

If you want to learn more about Pinocchio internal behaviors and main features, we invite you to read the related paper and the online documentation.

If you want to dive into Pinocchio directly, only one single line is sufficient (assuming you have Conda):

conda install pinocchio -c conda-forge

or via pip (currently only available on Linux):

pip install pin

Table of contents

Pinocchio main features

Pinocchio is fast:

  • C++ template library,
  • cache friendly,
  • support custom scalar type.

Pinocchio is versatile, implementing basic and more advanced rigid body dynamics algorithms:

  • forward kinematics and its analytical derivatives,
  • forward/inverse dynamics and their analytical derivatives,
  • centroidal dynamics and its analytical derivatives,
  • computations of kinematic and dynamic regressors for system identification and more,
  • full support of closed-loop mechanisms,
  • state-of-the-art frictional contact solvers,
  • low-complexity constrained articulated body algorithms,
  • sparse constrained dynamics and its analytical derivatives,
  • full support of multiple-precision floating-point (MPFR) in Python and C++,
  • support of modern and open-source Automatic Differentiation frameworks like CppAD or CasADi,
  • automatic code generation support is available via CppADCodeGen.

Pinocchio can create Multi-body system from:

  • URDF file,
  • SDF file,
  • MJCF file,
  • SRDF file to add frame and contact.

Pinocchio is flexible:

  • header only,
  • C++ 11/14/17/20 compliant.

Pinocchio is extensible. Pinocchio is multi-thread friendly. Pinocchio is reliable and extensively tested (unit tests, simulations, and real-world robotics applications). Pinocchio is supported and tested on Windows, Mac OS X, Unix, and Linux (see build status here).

Documentation

The online Pinocchio documentation of the last release is available here. A cheat sheet pdf with the main functions and algorithms can be found here.

Examples

In the examples directory, we provide some basic examples of using Pinocchio in Python. Additional examples introducing Pinocchio are also available in the documentation.

Tutorials

Pinocchio comes with a large bunch of tutorials aiming at introducing the basic tools for robot control. Tutorial and training documents are listed here. You can also consider the interactive Jupyter notebook set of tutorials developed by Nicolas Mansard and Yann de Mont-Marin.

Pinocchio continuous integrations

Pinocchio is constantly tested for several platforms and distributions, as reported below:

<!-- -->
Continuous Integration
CI on ROS ROS
CI on Linux via APT linux
CI on macOS and Windows via Pixi mac
CI on Linux via Robotpkg Pipeline Status

Performances

Pinocchio exploits, at best, the sparsity induced by the kinematic tree of robotics systems. Thanks to modern programming language paradigms, Pinocchio can unroll most of the computations directly at compile time, allowing to achieve impressive performances for an extensive range of robots, as illustrated by the plot below, obtained on a standard laptop equipped with an Intel Core i7 CPU @ 2.4 GHz.

Pinocchio Logo

For other benchmarks, and mainly the capacity of Pinocchio to exploit, at best, your CPU capacities using advanced code generation techniques, we refer to the technical paper. In addition, the introspection may also help you to understand and compare the performances of the modern rigid body dynamics libraries.

Ongoing developments

If you want to follow the current developments, you can refer to the devel branch. The devel branch only contains the latest release. Any new Pull Request should be submitted on the devel branch.

Installation

Pinocchio can be easily installed on various Linux (Ubuntu, Fedora, etc.) and Unix distributions (Mac OS X, BSD, etc.). Please refer to the installation procedure.

Conda

You simply need this simple line:

bash conda install pinocchio -c conda-forge

ROS

Pinocchio is also deployed on ROS. You may follow its deployment status below.

If you're interested in using Pinocchio on systems and/or with packages that integrate with the ROS ecosystem, we recommend the installation of Pinocchio via the binaries distributed via the ROS PPA. Here, you can install Pinocchio using:

sudo apt install ros-$ROS_DISTRO-pinocchio

This installs Pinocchio with Coal support for collision checking and with Python bindings. You can then use Pinocchio in your ROS packages by:

  • Depending on Pinocchio in your package.xml config (<depend>pinocchio</depend>)
  • Including Pinocchio via CMake (find_package(pinocchio REQUIRED)) and linking against Pinocchio (target_link_libraries(my_library pinocchio::pinocchio))

We include support and hooks to discover the package for ROS build systems. A ROS 2 example can be found in this repository.

Please note that we always advise including the pinocchio/fwd.hpp header as the first include to avoid compilation errors from differing Boost-variant sizes.

| ROS 2 Distro | Build Status | | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Humble | | | Jazzy | | | Kilted | | | Rolling | |

Visualization

Pinocchio provides support for many open-source and free visualizers:

  • Gepetto Viewer: a C++ viewer based on OpenSceneGraph with Python bindings and Blender export. See here for a C++ example on mixing Pinocchio and Gepetto Viewer.
  • Meshcat: supporting visualization in Python and which can be embedded inside any browser.
  • Panda3d: supporting visualization in Python and which can be embedded inside any browser.
  • RViz: supporting visualization in Python and which can interact with other ROS packages.
  • Viser: supporting browser-based visualization in Python, with support for widgets such as sliders and interactive markers.

Many external viewers can also be integrated. For more information, see the example here.

Citing Pinocchio

To cite Pinocchio in your academic research, please consider citing the software paper and use the following BibTeX entry: bibtex @inproceedings{carpentier2019pinocchio, title={The Pinocchio C++ library -- A fast and flexible implementation of rigid body dynamics algorithms and their analytical derivatives}, author={Carpentier, Justin and Saurel, Guilhem and Buondonno, Gabriele and Mirabel, Joseph and Lamiraux, Florent and Stasse, Olivier and Mansard, Nicolas}, booktitle={IEEE International Symposium on System Integrations (SII)}, year={2019} } And the following one for the link to the GitHub codebase: bibtex @misc{pinocchioweb, author = {Justin Carpentier and Florian Valenza and Nicolas Mansard and others}, title = {Pinocchio: fast forward and inverse dynamics for poly-articulated systems}, howpublished = {https://stack-of-tasks.github.io/pinocchio}, year = {2015--2021} }

Citing specific algorithmic contributions

Pinocchio goes beyond implementing the standard rigid-body dynamics algorithms and results from active research on simulation, learning, and control. Pinocchio provides state-of-the-art algorithms for handling constraints, differentiating forward and inverse dynamics, etc. If you use these algorithms, please consider citing them in your research articles.

Questions and Issues

Do you have a question or an issue? You may either directly open a new question or a new issue or, directly contact us via the mailing list pinocchio@inria.fr.

Core-dev team

The currently active core developers of Pinocchio are:

Credits

In addition to the core dev team, the following people have also been involved in the development of Pinocchio and are warmly thanked for their contributions:

If you have participated in the development of Pinocchio, please add your name and contribution to this list.

Open-source projects relying on Pinocchio

  • Crocoddyl: A software to realize model predictive control for complex robotics platforms.
  • TSID: A software that implements a Task Space Inverse Dynamics QP.
  • HPP: A SDK that implements motion planners for humanoids and other robots.
  • Jiminy: A simulator based on Pinocchio.
  • ocs2: A toolbox for Optimal Control for Switched Systems (OCS2)
  • TriFingerSimulation: TriFinger Robot Simulation (a Robot to perform RL on manipulation).
  • CasadiKinDyn: IIT Package for generation of symbolic (SX) expressions of robot kinematics and dynamics.
  • PyRoboPlan: An educational Python library for manipulator motion planning using the Pinocchio Python bindings.
  • ProxSuite-NLP: A primal-dual augmented Lagrangian solver for nonlinear programming on manifolds.
  • Aligator: A versatile and efficient framework for constrained trajectory optimization.
  • Simple: The Simple Simulator: Simulation Made Simple.
  • LoIK: Low-Complexity Inverse Kinematics.

Acknowledgments

The development of Pinocchio is actively supported by the Gepetto team @LAAS-CNRS and the Willow team @INRIA.

Owner

  • Name: Stack Of Tasks development team
  • Login: stack-of-tasks
  • Kind: organization

One implementation of the Stack of Tasks framework

Citation (CITATION.bib)

@inproceedings{carpentier:hal-01866228,
  TITLE = {{The Pinocchio C++ library -- A fast and flexible implementation of rigid body dynamics algorithms and their analytical derivatives}},
  AUTHOR = {Carpentier, Justin and Saurel, Guilhem and Buondonno, Gabriele and Mirabel, Joseph and Lamiraux, Florent and Stasse, Olivier and Mansard, Nicolas},
  URL = {https://hal.laas.fr/hal-01866228},
  BOOKTITLE = {{SII 2019 - International Symposium on System Integrations}},
  ADDRESS = {Paris, France},
  HAL_LOCAL_REFERENCE = {Rapport LAAS n{\textdegree} 18288},
  YEAR = {2019},
  MONTH = Jan,
  PDF = {https://hal.laas.fr/hal-01866228v2/file/19-sii-pinocchio.pdf},
  HAL_ID = {hal-01866228},
  HAL_VERSION = {v2},
}

Committers

Last synced: 7 months ago

All Time
  • Total Commits: 8,317
  • Total Committers: 94
  • Avg Commits per committer: 88.479
  • Development Distribution Score (DDS): 0.403
Past Year
  • Commits: 759
  • Committers: 25
  • Avg Commits per committer: 30.36
  • Development Distribution Score (DDS): 0.643
Top Committers
Name Email Commits
Justin Carpentier j****r@i****r 4,967
Rohan Budhiraja p****n 612
Joris Vaillant j****t@i****r 475
Gabriele Buondonno g****n@l****r 305
Joseph Mirabel j****l@l****r 284
Valenza Florian f****a@l****r 233
Mansard n****d@l****r 202
Guilhem Saurel g****l@l****r 165
ManifoldFR w****t@p****g 130
fabinsch 5****h 128
Megane Millan m****n@i****r 120
Wolfgang Merkt w****t@g****m 66
Ajay Sathya a****a@i****r 48
dependabot[bot] 4****] 39
Stéphane Caron s****n@i****r 39
Olivier Stasse o****e@g****m 31
Florent Lamiraux f****t@l****r 30
pre-commit-ci[bot] 6****] 29
Guilhem Saurel g****l@g****m 28
Olivier Stasse o****e@l****r 26
Antonio El Khoury a****y@w****u 25
Mégane Millan 3****l 19
simeon s****d@g****m 18
Lev Kozlov k****0@g****m 17
Florian Valenza f****a@l****r 14
shubhamsingh91 s****1@g****m 14
Francois Keith f****h@c****r 14
Etienne Arlaud e****d@p****1 13
EtienneAr e****d@g****m 11
Carlos Mastalli c****i@g****m 11
and 64 more...

Issues and Pull Requests

Last synced: 4 months ago

All Time
  • Total issues: 364
  • Total pull requests: 432
  • Average time to close issues: 25 days
  • Average time to close pull requests: 12 days
  • Total issue authors: 219
  • Total pull request authors: 43
  • Average comments per issue: 3.53
  • Average comments per pull request: 1.18
  • Merged pull requests: 340
  • Bot issues: 0
  • Bot pull requests: 100
Past Year
  • Issues: 129
  • Pull requests: 223
  • Average time to close issues: 11 days
  • Average time to close pull requests: 7 days
  • Issue authors: 77
  • Pull request authors: 26
  • Average comments per issue: 2.28
  • Average comments per pull request: 0.87
  • Merged pull requests: 165
  • Bot issues: 0
  • Bot pull requests: 66
Top Authors
Issue Authors
  • stephane-caron (21)
  • jorisv (19)
  • MegMll (9)
  • jcarpent (8)
  • joao-pm-santos96 (7)
  • Cfather (7)
  • sancelot (5)
  • arjung128 (5)
  • bhtxy0525 (5)
  • ManifoldFR (5)
  • nim65s (5)
  • Mr-Red331 (4)
  • matheecs (4)
  • qiyuanchn (4)
  • Zionshang (4)
Pull Request Authors
  • jcarpent (77)
  • dependabot[bot] (68)
  • jorisv (67)
  • nim65s (60)
  • MegMll (43)
  • stephane-caron (41)
  • pre-commit-ci[bot] (33)
  • ManifoldFR (18)
  • update-pixi-lockfile[bot] (17)
  • fabinsch (17)
  • abussy-aldebaran (13)
  • JafarAbdi (11)
  • sea-bass (9)
  • cmastalli (8)
  • florent-lamiraux (8)
Top Labels
Issue Labels
c++ (8) feature request (7) bug (4) question (3) Installation issue (3) ci (3) help wanted (2) documentation (1) suggestion (1) binding (1) rendering (1) known-bug-wont-fix (1) python (1) no changelog (1)
Pull Request Labels
no changelog (198) dependencies (67) build_all (38) github_actions (28) pixi (17) build_collision (15) pr status wip (15) pr status to review (14) build_casadi (6) build_accelerate (4) build_codegen (4) pr status ready (4) build_autodiff (2) priority (2) need modifications (2) documentation (2) rendering (2) build_sdf (2) bug (2) suggestion (1)

Packages

  • Total packages: 6
  • Total downloads:
    • pypi 115,396 last-month
    • homebrew 76 last-month
  • Total docker downloads: 29
  • Total dependent packages: 27
    (may contain duplicates)
  • Total dependent repositories: 71
    (may contain duplicates)
  • Total versions: 166
  • Total maintainers: 1
pypi.org: pin

A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives

  • Versions: 18
  • Dependent Packages: 19
  • Dependent Repositories: 67
  • Downloads: 115,270 Last month
  • Docker Downloads: 0
Rankings
Dependent packages count: 0.7%
Dependent repos count: 1.8%
Stargazers count: 1.9%
Average: 2.5%
Forks count: 3.0%
Downloads: 3.1%
Docker downloads count: 4.3%
Maintainers (1)
Last synced: 4 months ago
proxy.golang.org: github.com/stack-of-tasks/pinocchio
  • Versions: 90
  • Dependent Packages: 0
  • Dependent Repositories: 0
Rankings
Dependent packages count: 6.4%
Average: 6.7%
Dependent repos count: 6.9%
Last synced: 4 months ago
pypi.org: pin3-slam

TEMPORARY RELEASE A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives

  • Versions: 2
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 74 Last month
  • Docker Downloads: 29
Rankings
Stargazers count: 1.9%
Forks count: 3.0%
Dependent packages count: 6.6%
Average: 11.5%
Downloads: 15.4%
Dependent repos count: 30.6%
Maintainers (1)
Last synced: 4 months ago
conda-forge.org: pinocchio
  • Versions: 37
  • Dependent Packages: 7
  • Dependent Repositories: 4
Rankings
Dependent packages count: 8.0%
Forks count: 10.6%
Average: 11.9%
Stargazers count: 12.8%
Dependent repos count: 16.2%
Last synced: 4 months ago
pypi.org: pin3x-jnrh2023

A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives - TEMPORARY PACKAGE

  • Versions: 1
  • Dependent Packages: 1
  • Dependent Repositories: 0
  • Downloads: 52 Last month
Rankings
Stargazers count: 1.9%
Forks count: 3.0%
Dependent packages count: 7.5%
Average: 23.3%
Downloads: 34.4%
Dependent repos count: 69.8%
Maintainers (1)
Last synced: 4 months ago
formulae.brew.sh: pinocchio

Efficient and fast C++ library implementing Rigid Body Dynamics algorithms

  • Versions: 18
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 76 Last month
Rankings
Forks count: 9.3%
Stargazers count: 16.5%
Dependent packages count: 19.0%
Average: 36.0%
Dependent repos count: 50.7%
Downloads: 84.3%
Last synced: 4 months ago

Dependencies

.github/workflows/linux.yml actions
  • actions/cache v3 composite
  • actions/checkout v3 composite
.github/workflows/macos-linux-conda.yml actions
  • actions/checkout v3 composite
  • conda-incubator/setup-miniconda v2 composite
  • hendrikmuhs/ccache-action v1 composite
.github/workflows/ros-ci.yml actions
  • actions/cache v3 composite
  • actions/checkout v3 composite
  • ros-industrial/industrial_ci master composite
.github/workflows/windows-conda-clang.yml actions
  • actions/checkout v3 composite
  • goanpeca/setup-miniconda v2 composite
.github/workflows/windows-conda-v142.yml actions
  • actions/checkout v3 composite
  • goanpeca/setup-miniconda v2 composite