Skip to content

ZhiyeTang/octree-builder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

octree-builder

A CUDA-implemented octree-builder module.

Dependencies

This code has only been built and tested under Ubuntu-20.04 with RTX 3090 GPU. Other dependencies:

python                    3.7.16
pytorch                   1.12.1

Note that other versions of Python and PyTorch are also likely to run octree-builder well.

Installation

$ git clone https://github.com/ZhiyeTang/octree-builder.git
$ cd octree-builder
$ pip install .

Usage

from octree_builder._C import buildOctree

tree = buildOctree(grid_coord, level)

in which grid_coord is the spatial indices of all nodes within the octree, with a shape like [N, 3], while level is the levels of each node with a shape like [N, 1] or [N].

The output tree is a [N] shape tensor, with the i-th element indicating the parent node of the i-th node is the tree[i]-th node. If no parent node of node i matches, tree[i] is set to be -1.

About

A CUDA-implemented octree-builder module.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published