Git Product home page Git Product logo

arm_clouds's Introduction

arm_clouds

A simple module for convenient usage of both NumPy and PyTorch point clouds. Functionality includes:

  • Visualization in Plotly, Open3D, and Rerun with one function call.
  • Tracks and enforces consistency between XYZ and (optional) RGB PyTorch data type and device.
  • Methods for (un)normalization of RGB values.

Installation

To install arm_clouds, clone the repository and install with pip install -e ..

Usage

This repo includes classes for both single point clouds (PointCloud) and point cloud lists (PointCloudList).

PointCloud Usage

An example PointCloud:

# Your XYZ and RGB data
xyz = torch.rand(3, 100)
rgb = torch.rand(3, 100)  # optional

pc = PointCloud(xyz, rgb)

# One-call-visualization. Can also visualize in rerun and open3d.
pc.visualize_plotly()

PointCloudList Usage

You can initialize a PointCloudList from a NumPy array or PyTorch tensor of all point clouds:

xyz = np.random.rand(100, 3, 25)
pcl = PointCloudList(xyz)
pcl.visualize_plotly()

Or if you're dealing with point clouds with different numbers of points:

pcl = PointCloudList()

# If you haven't already created a `PointCloud` from the raw data:
for xyz, rgb in zip(xyzs, rgbs):
    pcl.append_create_cloud(xyz, rgb)

# If you already have your data in the `PointCloud` format, you can do:
for pc in point_cloud_python_list:
    pcl.append(pc)
# But if you already have multiple `PointCloud` objects in a raw Python list,
# you can directly initialize the `PointCloudList`:
pcl = PointCloudList(point_cloud_python_list)

For further usage examples, look at the test functions.

arm_clouds's People

Contributors

dcolli23 avatar

Stargazers

 avatar

Watchers

 avatar Andrew Price avatar Calder Phillips-Grafflin avatar Yu-Chi Lin avatar Sheng Zhong (Johnson) avatar Mark Van der Merwe avatar Brad Saund avatar Glen Chou avatar Tom Power avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.