Skip to content

Commit

Permalink
deploy: 178b6a6
Browse files Browse the repository at this point in the history
  • Loading branch information
stephane-caron committed Aug 27, 2024
0 parents commit d18759a
Show file tree
Hide file tree
Showing 180 changed files with 11,590 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .buildinfo
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 86c98214d0ed2b2873a705df2ef98ae0
tags: 645f666f9bcd5a90fca523b33c5a78b7
Binary file added .doctrees/barriers.doctree
Binary file not shown.
Binary file added .doctrees/developer-notes.doctree
Binary file not shown.
Binary file added .doctrees/environment.pickle
Binary file not shown.
Binary file added .doctrees/index.doctree
Binary file not shown.
Binary file added .doctrees/installation.doctree
Binary file not shown.
Binary file added .doctrees/introduction.doctree
Binary file not shown.
Binary file added .doctrees/inverse-kinematics.doctree
Binary file not shown.
Binary file added .doctrees/limits.doctree
Binary file not shown.
Binary file added .doctrees/references.doctree
Binary file not shown.
Binary file added .doctrees/tasks.doctree
Binary file not shown.
Empty file added .nojekyll
Empty file.
31 changes: 31 additions & 0 deletions _sources/barriers.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/barriers.rst

.. _Barriers:

********
Barriers
********

Definition
==========

.. automodule:: pink.barriers.barrier
:members:

Position barrier
================

.. automodule:: pink.barriers.position_barrier
:members:

Body Spherical barrier
======================

.. automodule:: pink.barriers.body_spherical_barrier
:members:

Whole Body Collision Avoidance
==============================

.. automodule:: pink.barriers.self_collision_barrier
:members:
20 changes: 20 additions & 0 deletions _sources/developer-notes.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/developer-notes.rst

***************
Developer notes
***************

This section documents internal functions and other notes shared between contributors to this project.

Design guidelines
=================

* Pink is designed for clarity before performance
* Leaky abstractions are our enemy
* WIP

Exceptions
==========

.. automodule:: pink.exceptions
:members:
27 changes: 27 additions & 0 deletions _sources/index.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/index.rst

.. title:: Table of Contents

####
Pink
####

**P**\ ython **in**\ verse **k**\ inematics for articulated robot models, based on `Pinocchio <https://github.com/stack-of-tasks/pinocchio>`_.

.. image:: https://user-images.githubusercontent.com/1189580/192318997-ed7574c3-8238-451d-9548-a769d46ec03b.png
:alt: Banner for Pink

Inverse kinematics in Pink is defined by weighted :ref:`tasks <Tasks>` and :ref:`limits <Limits>`. The library adds a :ref:`configuration <Configuration>` type to Pinocchio, a configuration being a robot model and data to which forward kinematics have been applied. Given a configuration, tasks and a time step, :func:`pink.solve_ik.solve_ik` computes joint velocities that steer the model towards fulfilling all tasks at best.

.. toctree::
:maxdepth: 1

installation.rst
introduction.rst
tasks.rst
limits.rst
barriers.rst
inverse-kinematics.rst
developer-notes.rst
references.rst

34 changes: 34 additions & 0 deletions _sources/installation.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/installation.rst

************
Installation
************

From Conda
==========

For best performance we recommended installing Pink from Conda:

.. code:: bash
conda install -c conda-forge pink
From PyPI
=========

Installation from the Python Package Index should work via:

.. code:: bash
pip install pin-pink
From source
===========

If installation from PyPI doesn't work, you can manually install `eigenpy <https://github.com/stack-of-tasks/eigenpy>`__ (required by Pinocchio) and `Pinocchio <https://github.com/stack-of-tasks/pinocchio>`__ from source. Then install Pink by:

.. code:: bash
pip install --no-deps pin-pink
Alternatively, copy or add the ``pink/`` module directory somewhere in your ``PYTHONPATH``.
54 changes: 54 additions & 0 deletions _sources/introduction.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/introduction.rst

************
Introduction
************

Inverse kinematics (IK) is the problem of computing *motions* (in Pink: velocities) that achieve a given set of *tasks*, such as putting a foot on a surface, moving the center of mass to a target location, etc.

This documentation assumes you are already familiar with task-based inverse kinematics. You can check out for instance this `post on inverse kinematics <https://scaron.info/robot-locomotion/inverse-kinematics.html>`__ for a general introduction.

Notations
=========

In Pink, we adopt the subscript right-to-left convention for transforms, and superscript notation to indicate the frame of a motion or force vector:

.. list-table::
:class: cheatsheet
:widths: 70 30

* - Quantity
- Notation
* - Affine transform from frame :math:`A` to frame :math:`B`
- :math:`T_{BA}`
* - Body angular velocity of frame :math:`A` in frame :math:`B`
- :math:`{}^A \omega_{BA}`
* - Position of frame :math:`B` in frame :math:`A`
- :math:`{}^A p_B`
* - Rotation matrix from frame :math:`A` to frame :math:`B`
- :math:`R_{BA}`
* - Spatial angular velocity of frame :math:`A` in frame :math:`B`
- :math:`{}^B \omega_{BA}`
* - World frame (inertial)
- :math:`W`

With these notations frame transforms can be read left to right, for example:

.. raw:: latex html

\begin{align}
T_{CA} & = T_{CB} T_{BA} &
{}^{B} \omega & = R_{BA} {}^{A} \omega &
{}^B p_C & = R_{BA} {}^A p_C + {}^B p_A
\end{align}

See also this `spatial algebra cheat sheet
<https://scaron.info/robot-locomotion/spatial-vector-algebra-cheat-sheet.html>`_.

.. _Configuration:

Configuration
=============

.. automodule:: pink.configuration
:members:
26 changes: 26 additions & 0 deletions _sources/inverse-kinematics.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/inverse-kinematics.rst

******************
Inverse kinematics
******************

The main function solve inverse kinematics is :func:`.solve_ik`. Here is for
instance how it appears in a closed-loop inverse kinematics:

.. code:: python
rate = RateLimiter(frequency=100.0)
while True:
# [...] <- update task targets here
velocity = solve_ik(configuration, tasks, rate.dt, solver=solver)
configuration.integrate_inplace(velocity, rate.dt)
rate.sleep()
See the ``examples/`` folder in the repository for complete use cases.

.. autofunction:: pink.solve_ik.solve_ik

It is also possible to ask Pink to only build the underlying inverse kinematics
problem via the :func:`.build_ik` function:

.. autofunction:: pink.solve_ik.build_ik
31 changes: 31 additions & 0 deletions _sources/limits.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/limits.rst

.. _Limits:

******
Limits
******

Definition
==========

.. automodule:: pink.limits.limit
:members:

Configuration limit
===================

.. automodule:: pink.limits.configuration_limit
:members:

Velocity limit
==============

.. automodule:: pink.limits.velocity_limit
:members:

Acceleration limit
==================

.. automodule:: pink.limits.acceleration_limit
:members:
15 changes: 15 additions & 0 deletions _sources/references.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/references.rst

**********
References
**********

.. [FrameTaskJacobian] `Jacobian of a kinematic task and derivatives on manifolds <https://scaron.info/robotics/jacobian-of-a-kinematic-task-and-derivatives-on-manifolds.html>`_. S. Caron. 2023.
.. [MLT] `A micro Lie theory for state estimation in robotics <https://arxiv.org/abs/1812.01537>`_. J. Solà, J. Deray, D. Atchuthan. 2018.
.. [Sugihara2011] *Solvability-Unconcerned Inverse Kinematics by the Levenberg-Marquardt Method*. T. Sugihara. IEEE transactions on robotics, 2011, vol. 27, no 5, pp. 984-991.
.. [Flacco2015] *Control of Redundant Robots Under Hard Joint Constraints: Saturation in the Null Space*. F. Flacco, A. De Luca and O. Khatib. IEEE Transactions on Robotics, 2015, vol. 31, no 3, pp. 637-654.
.. [DelPrete2018] *Joint Position and Velocity Bounds in Discrete-Time Acceleration/Torque Control of Robot Manipulators*. A. Del Prete. IEEE Robotics and Automation Letters, 2018, vol. 3, no 1, pp. 281-288.
43 changes: 43 additions & 0 deletions _sources/tasks.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
:github_url: https://github.com/stephane-caron/pink/tree/main/doc/tasks.rst

.. _Tasks:

*****
Tasks
*****

Definition
==========

.. automodule:: pink.tasks.task
:members:

Frame task
==========

.. automodule:: pink.tasks.frame_task
:members:

Relative frame task
===================

.. automodule:: pink.tasks.relative_frame_task
:members:

Joint coupling task
===================

.. automodule:: pink.tasks.joint_coupling_task
:members:

Linear holonomic task
=====================

.. automodule:: pink.tasks.linear_holonomic_task
:members:

Posture task
============

.. automodule:: pink.tasks.posture_task
:members:
Loading

0 comments on commit d18759a

Please sign in to comment.