Skip to content

Installation

Package

pip install torch-pointcloud

This installs the library together with torch and torch-geometric.

PyTorch and CUDA extensions

Select a package manager, torch version, compute platform, and the extras you need; the command below updates accordingly. Options without a matching wheel are grayed out. flash-attn, mamba, and the PyG extensions install as prebuilt wheels, from the Astral GPU indexes and the PyG wheel index.

Dependencies Required by
pyg-lib FPS, kNN, and scatter pooling (torch-scatter, torch-cluster, ...); needed by nearly every model
flash-attn Point Transformer V3, Sonata, Concerto, Utonia
mamba Point-Mamba, Voxel-Mamba, LION
spconv SpUNet, SPFormer-UNet, voxel-based detectors
ocnn OctFormer (installed together with dwconv)
torchsparse SPVCNN
sptr SphereFormer
lightning The Lightning training modules
Package manager
PyTorch
Compute
Extras
# torch-pointcloud + torch 2.10.0 + CUDA 12.8
uv pip install torch-pointcloud
uv pip install torch==2.10.0 \
  --index-url https://download.pytorch.org/whl/cu128
# PyG extensions (torch-scatter, torch-cluster, ...)
uv pip install \
  pyg-lib torch-scatter torch-sparse torch-cluster \
  -f https://data.pyg.org/whl/torch-2.10.0+cu128.html

The combination tested in CI and used for the benchmark results is torch==2.10.0 with CUDA 12.8. Other torch or CUDA versions and exact wheel pins are listed on the Astral GPU indexes and the PyG wheel index.

Development

To work on the library, clone it and set up the environment with uv:

git clone https://github.com/arthurdjn/pytorch-pointcloud.git
cd pytorch-pointcloud
uv sync

For the test and docs tooling, install the dev group and all extras:

uv sync --all-extras --dev

As above, install the extra dependencies for your machine (CUDA 12.8, torch 2.10.0, and so on).

Common commands:

make test   # Run the test suite
make format # Format the code
make lint   # Lint the code
make type   # Type check the code
make clean  # Clean the build artifacts
make docs   # Build the documentation
make serve  # Serve the documentation locally

Compatibility

  • Python: 3.10+
  • PyTorch: torch>=2.8. CI runs the test suite on the lowest supported version (torch==2.8.0). The benchmark results use torch==2.10.0 with CUDA 12.8.
  • PyG kernels: the PyG wheel index has deprecated torch-cluster in favor of pyg-lib. From torch-geometric>=2.8, sampling and neighbor search need pyg-lib>=0.6, which is built for torch>=2.8 only.
  • CUDA: optional for the point-based families (PointNet, PointNet++, DGCNN, PointNeXt, PointMLP, PointConv, PointCNN, RandLA-Net, and similar), which run inference and training on CPU. The sparse-voxel and flash-attention families (Point Transformer V3, Sonata, Concerto, Utonia, SpUNet, SPVCNN, OctFormer, and the voxel-based detectors) require a CUDA device and their optional dependencies (spconv, torchsparse, ocnn, flash-attn).