pytransform3d
3D transformations for Python
What it is and what it does
pytransform3d is a Python library for working with 3D transformations—rotations and translations—in robotics, computer vision, and geometric computing. It provides a unified interface to convert between common rotation representations (quaternions, Euler angles, rotation matrices, axis-angle), compose transformations, and invert them. The core strength is the TransformManager, which maintains a graph of coordinate frames and computes transformations between any two frames automatically, eliminating manual chain multiplication.
The library couples tightly with matplotlib for visualization and can load transformation hierarchies from URDF files (robot description format) via lxml. Optional integrations include Qt-based graphical transformation editing, Open3D visualization, and graph export via pydot. It's designed for robotics workflows—specifying robot motions, learning from demonstrations, pose estimation, collision detection—but applies broadly to any domain needing 3D geometric reasoning.
Use it for:
- Specify and visualize robot arm kinematics by defining frame hierarchies and querying end-effector positions
- Convert between rotation representations (e.g., quaternion to Euler angles) for sensor fusion or animation
- Load and manipulate URDF robot models to compute forward kinematics and frame transformations
- Animate 3D geometries and transformations using matplotlib or Open3D visualization interfaces
- Build transformation chains for multi-sensor systems (e.g., camera-to-robot-to-gripper) and resolve poses
- Prototype geometric algorithms requiring coordinate frame reasoning without manual matrix algebra
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
pytransform3d provides operations, conversions, and visualizations for 3D rotations and translations, with built-in support for multiple rotation representations and a TransformManager for chaining complex transformations.
Yes. pytransform3d is actively maintained, has no known vulnerabilities, installs with low friction, and fills a clear niche in 3D geometry and robotics. Its permissive BSD license and mature API (since 2018) make it safe for production use. Install if you work with 3D transformations, robot kinematics, or multi-frame coordinate systems.
Install
pytransform3d on PyPI
pip
pip install pytransform3duv
uv add pytransform3dpoetry
poetry add pytransform3dInstalling pytransform3d
Before you install
Low friction install with a pure-Python wheel. Actively maintained with a recent release (21 days ago) and 704 repository stars. Core dependencies are standard scientific stack (numpy, scipy, matplotlib, lxml).
License in practice
Distributed under BSD-3-Clause (permissive), allowing commercial and private use with minimal restrictions beyond attribution and liability disclaimers.
Quickstart
pip install pytransform3d
import numpy as np
from pytransform3d import rotations as pr
from pytransform3d import transformations as pt
from pytransform3d.transform_manager import TransformManager
tm = TransformManager()
tm.add_transform("frame_a", "frame_b", pt.transform_from_pq(np.array([0, 0, 0, 1, 0, 0, 0])))
ee2object = tm.get_transform("frame_a", "frame_b")
Verify before relying
- Whether Open3D integration (mentioned in description) is included in base install or requires separate extras
- Support for Python 2 (listed in classifiers) status given modern ecosystem shift
Package facts
| License | BSD-3-Clause (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 4 — numpy, scipy, matplotlib, lxml |
| Maintenance | actively maintained — 21 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 353,174/month — #7,306 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pytransform3d-3.16.0-py3-none-any.whl
Tags
More Mathematics packages
NetworkX provides data structures and…
permissive · top 1,000 on PyPI
kiwisolverkiwisolver is a Python binding to a fast C++…
permissive · top 1,000 on PyPI
sympySymPy is a Python library for symbolic…
permissive · top 1,000 on PyPI
contourpyContourPy calculates contours of 2D…
permissive · top 1,000 on PyPI
torchPyTorch provides GPU-accelerated tensor…
permissive · top 1,000 on PyPI
onnxruntimeonnxruntime loads and executes Open Neural…
permissive · top 1,000 on PyPI
transforms3dConverts between different 3D geometric…
permissive · top 15,000 on PyPI
transformationsCalculates 4x4 homogeneous transformation…
permissive · top 5,000 on PyPI
pyquaternionProvides quaternion representation,…
permissive · top 5,000 on PyPI
meshcatmeshcat is a Python interface to a…
permissive · top 5,000 on PyPI
pytweeningPyTweening provides a collection of easing…
permissive · top 5,000 on PyPI
affineAffine provides a Python class for representing…
permissive · top 5,000 on PyPI
open3dOpen3D provides data structures and algorithms…
permissive · top 5,000 on PyPI
romaRoMa provides differentiable conversions…
permissive · top 15,000 on PyPI
open3d-cpuOpen3D-cpu provides CPU-based 3D data…
permissive · top 15,000 on PyPI
euclid3Provides 2D and 3D vector, matrix, quaternion,…
unclear · top 15,000 on PyPI