Skip to main content

PointCloud2 lib for non ROS environments

Project description

PointCloud2

PointCloud2 lib for non ROS environment.

PyPI version PyPI license PyPI download month

Usage

>>> import numpy as np
>>> from pointcloud2 import create_cloud, read_points, PointField
>>> fields = [
...     PointField('x', 0, PointField.FLOAT32, 1),
...     PointField('y', 4, PointField.FLOAT32, 1),
...     PointField('z', 8, PointField.FLOAT32, 1),
...     PointField('rgb', 12, PointField.UINT32, 1),
... ]
>>> points = np.array([
...     [1, 0, 0, 255],
...     [0, 1, 0, 255],
...     [0, 0, 1, 255],
... ], dtype=np.float32)
>>> cloud = create_cloud(header=None, fields=fields, points=points)
>>> cloud.height, cloud.width, cloud.point_step, cloud.row_step, len(cloud.data)
(1, 3, 16, 48, 48)
>>> read_points(cloud)
array([(1., 0., 0., 255), (0., 1., 0., 255), (0., 0., 1., 255)],
      dtype=[('x', '<f4'), ('y', '<f4'), ('z', '<f4'), ('rgb', '<u4')])

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pointcloud2-0.5.0.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pointcloud2-0.5.0-py3-none-any.whl (7.6 kB view details)

Uploaded Python 3

File details

Details for the file pointcloud2-0.5.0.tar.gz.

File metadata

  • Download URL: pointcloud2-0.5.0.tar.gz
  • Upload date:
  • Size: 6.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pointcloud2-0.5.0.tar.gz
Algorithm Hash digest
SHA256 0e9d30f956431fcdbe6cf34433d8f992e2ed021cf747e668fc48467c93e720f0
MD5 14655f88e002b3d59a5e43bf4e622237
BLAKE2b-256 284c56f2e3d59ec0ffe4c60b68b8178fc3e2a745e53a35ab8d949ad2a880781e

See more details on using hashes here.

File details

Details for the file pointcloud2-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: pointcloud2-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 7.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for pointcloud2-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c18fa453b36695cf1d753b31c688e70a7f2e437c929e5a9d33b3e3a983b46b0e
MD5 845c3c5ce52dc58700d9ccb5fdc44410
BLAKE2b-256 42b47e31804f56a99c4b6f680d92c9fe57adedfff82e7a710015023e902699c5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page