Skip to main content

parallel-delaunay

Delaunay triangulation for a 2D point set. On the benchmark below this is about twice as fast as SciPy 1.18.1. Both curves have the same slope: O(n log n).

Delaunay triangulation of 32 points
from paralleldelaunay import Delaunay

tri = Delaunay(points)
tri.simplices  # (m, 3) indices into the points you passed

Points can arrive in any order. parallel=False runs one core.

The kernel is Guibas and Stolfi's divide-and-conquer algorithm, compiled with Numba. An edge is an index into integer arrays, not an object: org[e] is the origin, onext[e] is the next edge counterclockwise around that origin, and the symmetric edge is e ^ 1 because each undirected edge occupies slots 2k and 2k+1. Delaunay runs every leaf at once, then each round of independent merges, using prange.

Install

Python 3.11 or newer. From the repository root:

uv sync

Another uv project can add the package with uv add parallel-delaunay.

Tests

make test    # pytest, including a triangle check against SciPy
make format  # Ruff

Benchmark

uv run python triangulation_benchmarks.py

Each time below is the median of five runs against scipy.spatial.Delaunay. This library's column includes sorting the points. A ratio below 1 means this library was faster. parallel_benchmark.py compares the default prange path with parallel=False. The 2021 pure-Python chart is images/Figure 2021-07-02 210145.png.

Delaunay triangulation benchmarks
Points This library SciPy 1.18.1 This library / SciPy
1,000 0.9 ms 1.7 ms 0.5×
2,511 1.8 ms 4.2 ms 0.4×
6,309 4.3 ms 11.0 ms 0.4×
15,848 12.0 ms 29.8 ms 0.4×
39,810 35.3 ms 84.0 ms 0.4×
100,000 129.5 ms 261.9 ms 0.5×

Reference

Guibas, Leonidas and Stolfi, Jorge. "Primitives for the Manipulation of General Subdivisions and the Computation of Voronoi Diagrams." ACM Transactions on Graphics 4.2 (April 1985), pp. 74–123. doi:10.1145/282918.282923

Metadata

Release files for parallel-delaunay 2.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for parallel-delaunay 2.0.1
File Size Uploaded Provenance Actions
parallel_delaunay-2.0.1.tar.gz 14.1 kB Without provenance Details for parallel_delaunay-2.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for parallel-delaunay 2.0.1
File Interpreter ABI Platform Actions
parallel_delaunay-2.0.1-py3-none-any.whl Python 3 none any Details for parallel_delaunay-2.0.1-py3-none-any.whl

Total release size: 32.7 kB

Release files / parallel_delaunay-2.0.1.tar.gz

Download URL parallel_delaunay-2.0.1.tar.gz
Size 14.1 kB
Tags Source
SHA-256 checksum
How to use checksums
39d0aa981d833570e58181c0e51260102c91540da9502124dabb535967e13ce7
BLAKE2b-256 checksum
How to use checksums
e9bfcb18002be7de3abe87f89f49b220afd0f4922e1cb798ec784329ace2ad01
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.27 {"installer":{"name":"uv","version":"0.9.27","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / parallel_delaunay-2.0.1-py3-none-any.whl

Download URL parallel_delaunay-2.0.1-py3-none-any.whl
Size 18.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f86445c062a7ffe59713c61014df36dc1080eac5337145deb32d7892999a081a
BLAKE2b-256 checksum
How to use checksums
aa7a97b4501afa1cdb101a5c832f4ce9691c7d9ee35fc1ed460504e6b6e4be9b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.27 {"installer":{"name":"uv","version":"0.9.27","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for parallel-delaunay 2.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page