dm-robotics-transformations-0.5.0
توضیحات
A library for Rigid Body Transformations
| ویژگی | مقدار |
|---|---|
| سیستم عامل | OS Independent |
| نام فایل | dm-robotics-transformations-0.5.0 |
| نام | dm-robotics-transformations |
| نسخه کتابخانه | 0.5.0 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | DeepMind |
| ایمیل نویسنده | - |
| آدرس صفحه اصلی | https://github.com/deepmind/dm_robotics/tree/main/py/transformations |
| آدرس اینترنتی | https://pypi.org/project/dm-robotics-transformations/ |
| مجوز | Apache 2.0 |
# DeepMind Robotics Transformations
Transformations is a pure python library for rigid-body transformations
including velocities and forces.
The objectives for this library are **simplicity** and **comprehensiveness**
across all canonical representations (euler, axis-angle, quaternion,
homogeneous matrices).
## Supported conversions:
* Quaternion to Rotation matrix, Axis-angle and Euler-angle
* Axis-angle to Quaternion, Rotation matrix and Euler-angle
* Rotation matrix to Quaternion, Axis-angle and Euler-angle
* Euler-angle to Quaternion, Rotation matrix and Axis-angle
## Quaternions:
Quaternions are represented with the scalar part (w) first, e.g.
```python
identity_quaternion = np.asarray([1, 0, 0, 0]) # w, i, j, k
```
Supported quaternion operations:
* Difference
* Distance
* Multiplication
* Inverse
* Conjugate
* Logarithm and Exponent
* Slerp (spherical linear interpolation)
* Rotation of a vector by a quaternion.
## Euler-angles
All 24 from-euler orderings are supported.
7 of 24 to-euler orderings are supported.
## Transforms
This library supports force and velocity transforms.
## Usage Example
```python
from dm_robotics.transformations import transformations as tr
# Convert a pose, euler angle into a homogeneous matrix (a 4x4 matrix):
hmat = tr.poseuler_to_hmat(
np.array([x, y, z, rot_x, rot_y, rot_z]), 'XYZ')
# Convert the homogeneous matrix to a twist (a 6 vector):
twist = tr.hmat_to_twist(hmat)
```
نیازمندی
| مقدار | نام |
|---|---|
| >=20.0.2 | pip |
| >=0.9.0 | absl-py |
| >=1.16.0 | numpy |
| ==2021.11.4.15.26.3 | numpy-quaternion |
نحوه نصب
نصب پکیج whl dm-robotics-transformations-0.5.0:
pip install dm-robotics-transformations-0.5.0.whl
نصب پکیج tar.gz dm-robotics-transformations-0.5.0:
pip install dm-robotics-transformations-0.5.0.tar.gz