PY3D - 3D data analysis toolkit
What is it?
py3d is a pure and lightweight Python library dedicated to 3D data structures and functions. It enables batch processing of 3D points, lines, planes, and 3D meshes. Moreover, it provides interactive visualization capabilities for these elements. It is advisable to use it in Jupyter for visualization purposes.
Main features
- Supports the reading, writing, and visualization of multiple 3D data formats such as the popular PLY, NPY, CSV, PCD, and OBJ. Demos
- Perform rotation, translation, and scaling operations on 3D geometries. Demos
- Conversion among diverse rotation representations, Demos
- Rotation matrix
- Angle - axis
- Quaternion
- Euler angle
- Rotation vector
How to install it?
pip install py3d
How to use it?
Here are some small examples:
- Visualize a pcd file in jupyter
import py3d
pcd = py3d.read_pcd("binary.pcd")
print("min", pcd.min())
print("max", pcd.max())
pcd.xyz.as_point(colormap=pcd.w)
- Visualize an image in jupyter
import py3d
py3d.image("./20220917214012.jpg")
- Visualize images with poses in jupyter
import py3d
py3d.render(
py3d.image("797.jpg") @ py3d.Transform.from_translation([0, 100, 0]),
py3d.image("971.jpg") @ py3d.Transform.from_rpy([0, 0.9, 0.2]) @ py3d.Transform.from_translation([-1000, 500, 0])
)
- Convert euler angles to rotation matrix
import py3d
py3d.Transform.from_euler("xyz", [0.4, -0.2, 0])
- Visualize a 2d matrix
import py3d
py3d.Vector([
[1,2,3],
[4,5,6],
[7,8,9]
]).as_image()
API reference
Release files for py3d 0.1.92
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| py3d-0.1.92.tar.gz | 35.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| py3d-0.1.92-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 70.2 kB
Release files / py3d-0.1.92.tar.gz
| Download URL | py3d-0.1.92.tar.gz |
|---|---|
| Size | 35.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7f8515cbbce7d729035cb1c8c9fa72f1c33083df024f352dc191160c36ede0f6
|
|
BLAKE2b-256 checksum How to use checksums |
7ce616341a2e02326a1a601f4a63ce3bd1574f556fa9adee6c44904f867855df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Release files / py3d-0.1.92-py3-none-any.whl
| Download URL | py3d-0.1.92-py3-none-any.whl |
|---|---|
| Size | 34.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c2716ff45fa7de3f8b70b449b471619e0e3176d5ec62a43c22a4e03d576d9d2a
|
|
BLAKE2b-256 checksum How to use checksums |
c15504899638c2bc6dd00562456f42eb5554295c9e335cac16777e0fc4c0ebb8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|