Better HN
topnewbestaskshowjobs
Log inSign up

morishuz

14 karma · joined Jul 30, 2026 (3mo ago) · 11 submissions

computer vision · machine learning · visual localisation · 3D reconstruction
Submissions

comment 1mo ago · link · parent

thanks, good suggestion! earcut plus refine sounds like sensible comparison.

i’ve since reproduced the world dataset benchmark locally and found that polygon validation was taking about two-thirds of delaunay32’s time on the accepted inputs.

comment 1mo ago · link · parent

ok interesting, thanks for actually running the comparison! looks like it clearly favors earstrip on this workload

comment 1mo ago · link · parent

awesome. the performance improvements looks impressive!

i’m the author of Delaunay32, a constrained delaunay triangulator with polygon and hole support. it uses divide-and-conquer rather than incremental insertion, so im curious how it would compare with the delaunay baseline here.

https://github.com/morishuz/delaunay32

i havent benchmarked on your corpus yet, and our current polygon api requires simple rings with non-touching holes. thanks for publishing the datasets, they look useful for testing and comparison!

comment 3mo ago · link · parent

For one million unconstrained points on the reference Apple M1 system, eight-thread Delaunay32 completes in roughly 50 ms.

Using that as the 1.0× baseline: • Delaunay32, one thread: ~2.8× runtime. • Fade2D, automatic threads: ~4.5×. • Fade2D, one thread: ~6×. • delaunator-cpp: ~11×. • Triangle: ~11×.

comment 3mo ago · link · parent

yes, there are currently two modes for internal integer math: 64 and 128 bit. (the internal int math needs larger ranges than the inputs since we work with squares etc)

64bit integers works with an input coordinate range of 29,609. this is typically fine for raster image coordinates or floats that can allow for some quantization (only the triangles/edges are affected by this not the original points!)

if the input range is larger than 29,609, the algorithm switches to a 128bit implementation with a range of 1,940,470,527 which is close to, but still smaller than, what could theoretically be stored in an int32 value. hence that's why the input is currently only up to int32.

in theory it could be extended to 64bit input range but it comes with performance and portability trade-offs that currently don't seem worth it

comment 3mo ago · link · parent

great. and do let me know if you have any feature requests, noticed bugs etc

comment 3mo ago · link · parent

for a one million points set i measured 4x faster when using single threaded and 11x when using multi-threaded delaunay32 vs triangle (on my Apple M1)

comment 3mo ago · link · parent

very nice!

comment 3mo ago · link · parent

the repo comes with a benchmark tool that you can run on your own machine, which already compares multi vs single threading as well as delaunator-cpp (which is only single threaded)

At one million points, Delaunay32 takes about 147–150 ms with one thread versus 540–555 ms for delaunator-cpp on my machine, so roughly 3.7× faster. Automatic eight-thread mode Delaunay32 takes about 53–54 ms.

comment 3mo ago · link · parent

thanks!

(i am the author of Delaunay32)

> Are vertex insertion and deletion also supported/accelerated?

no unfortunately not, since this is currently a fast batch triangulator, so vertex insertion/deletion requires rebuilding

>What compromises are keeping this constrained to 32-bit?

it isn’t SIMD-specific. the circle test involves squared coordinates and further multiplications. therefore, 32-bit coordinates inputs can already require 128-bit temporary results internally. Supporting 64-bit exactly would require roughly 256-bit intermediates and come at the cost of speed and portability, so i think 32bit is currently a good trade-off.