Skip to content

polyline

Benchmarks of ordito.polyline against every library that computes the same thing. Each chart shows the time of every library relative to ordito on CUDA (1x, in green): a longer bar took longer. The table under each chart lists every input the function was measured on. See Benchmarks for how to read and reproduce these numbers.

Measured on GPU: NVIDIA GeForce RTX 5090 · CPU: Intel Xeon w7-2495X

Summary

0.01x0.1x1x10x100xtrimesh: 0.75x ordito's time, geometric mean over 1 functions; slower than ordito in 0trimesh0.75x (1)ordito (CUDA): the reference, 1xordito (CUDA)1xMeshLib: 6.4x ordito's time, geometric mean over 6 functions; slower than ordito in 5MeshLib6.4x (6)PyVista: 20x ordito's time, geometric mean over 4 functions; slower than ordito in 4PyVista20x (4)
Time relative to ordito (CUDA), geometric mean over the polyline functions both implement; in parentheses, the number of functions. Log scale. Runs stopped at the time limit are left out.
Values
Library Time relative to ordito Functions compared ordito faster in
trimesh 0.75x 1 0
MeshLib 6.4x 6 5
PyVista 20x 4 4

polyline_length

0.1x1x10x100xordito (CUDA): 39.4 µs, 1x ordito's timeordito (CUDA)1x · 39.4 µsMeshLib: 216.1 µs, 5.5x ordito's timeMeshLib5.5x · 216.1 µsPyVista: 765.6 µs, 19x ordito's timePyVista19x · 765.6 µs
rim_long (131 072 faces) · time relative to ordito, log scale
Values
Library Median Relative to ordito
ordito (CUDA) 39.4 µs 1x
MeshLib 216.1 µs 5.5x
PyVista 765.6 µs 19x
All inputs
Input ordito (CUDA) MeshLib PyVista
saddle_small 32.7 µs 2.9 µs 113.7 µs
saddle 33.1 µs 3.6 µs 114.9 µs
rim_long 39.4 µs 216.1 µs 765.6 µs

polyline_downsample

0.1x1x10x100x1000xordito (CUDA): 126.2 µs, 1x ordito's timeordito (CUDA)1x · 126.2 µsMeshLib: 24.39 ms, 193x ordito's timeMeshLib193x · 24.39 ms
rim_long (131 072 faces) · time relative to ordito, log scale
Values
Library Median Relative to ordito
ordito (CUDA) 126.2 µs 1x
MeshLib 24.39 ms 193x
All inputs
Input ordito (CUDA) MeshLib
saddle_small 80.8 µs 68.9 µs
saddle 106.8 µs 195.6 µs
rim_long 126.2 µs 24.39 ms

polyline_simplify

0.1x1x10x100xordito (CUDA): 673.2 µs, 1x ordito's timeordito (CUDA)1x · 673.2 µsPyVista: 16.07 ms, 24x ordito's timePyVista24x · 16.07 msMeshLib: 29.14 ms, 43x ordito's timeMeshLib43x · 29.14 ms
rim_long (131 072 faces) · tolerance_fraction=0.001 · time relative to ordito, log scale
Values
Library Median Relative to ordito
ordito (CUDA) 673.2 µs 1x
PyVista 16.07 ms 24x
MeshLib 29.14 ms 43x
All inputs
Input ordito (CUDA) MeshLib PyVista
saddle_small tolerance_fraction=0.001 107.3 µs 121.6 µs 139.5 µs
saddle_small tolerance_fraction=0.1 103.8 µs 117.2 µs 139.6 µs
saddle tolerance_fraction=0.001 105.8 µs 205.7 µs 197.0 µs
saddle tolerance_fraction=0.1 88.8 µs 221.5 µs 194.9 µs
rim_long tolerance_fraction=0.001 673.2 µs 29.14 ms 16.07 ms
rim_long tolerance_fraction=0.1 570.6 µs 28.31 ms 16.47 ms

polyline_point_distance

0.1x1x10x100x1000x10000xordito (CUDA): 34.7 µs, 1x ordito's timeordito (CUDA)1x · 34.7 µsMeshLib: 19.61 ms, 566x ordito's timeMeshLib566x · 19.61 msPyVista: 39.69 ms, 1145x ordito's timePyVista1145x · 39.69 ms
saddle (34 848 faces) · n_queries=4096 · time relative to ordito, log scale
Values
Library Median Relative to ordito
ordito (CUDA) 34.7 µs 1x
MeshLib 19.61 ms 566x
PyVista 39.69 ms 1145x
All inputs
Input ordito (CUDA) MeshLib PyVista
saddle_small n_queries=4096 40.2 µs 19.25 ms 22.73 ms
saddle_small n_queries=65536 54.3 µs 307.08 ms 358.62 ms
saddle n_queries=4096 34.7 µs 19.61 ms 39.69 ms
saddle n_queries=65536 83.8 µs 321.03 ms 626.55 ms
rim_long n_queries=4096 455.4 µs 42.07 ms
rim_long n_queries=65536 6.64 ms 617.54 ms

polyline_triangulate

0.01x0.1x1xMeshLib: 117.9 µs, 0.65x ordito's timeMeshLib0.65x · 117.9 µsPyVista: 155.3 µs, 0.86x ordito's timePyVista0.86x · 155.3 µsordito (CUDA): 180.8 µs, 1x ordito's timeordito (CUDA)1x · 180.8 µs
sphere_small (5 120 faces) · n_vertices=64 · time relative to ordito, log scale
Values
Library Median Relative to ordito
MeshLib 117.9 µs 0.65x
PyVista 155.3 µs 0.86x
ordito (CUDA) 180.8 µs 1x
All inputs
Input ordito (CUDA) MeshLib PyVista
sphere_small n_vertices=64 180.8 µs 117.9 µs 155.3 µs
sphere_small n_vertices=1024 922.2 µs 1.59 ms 6.31 ms

triangulate_polygon

0.01x0.1x1xtrimesh: 52.4 µs, 0.29x ordito's timetrimesh0.29x · 52.4 µsordito (CUDA): 181.7 µs, 1x ordito's timeordito (CUDA)1x · 181.7 µs
ring_size=64 · time relative to ordito, log scale
Values
Library Median Relative to ordito
trimesh 52.4 µs 0.29x
ordito (CUDA) 181.7 µs 1x
All inputs
Input ordito (CUDA) trimesh
ring_size=64 181.7 µs 52.4 µs
ring_size=1024 857.9 µs 1.69 ms

polyline_upsample

0.1x1x10x100x1000xordito (CUDA): 56.6 µs, 1x ordito's timeordito (CUDA)1x · 56.6 µsMeshLib: 25.54 ms, 451x ordito's timeMeshLib451x · 25.54 ms
rim_long (131 072 faces) · time relative to ordito, log scale
Values
Library Median Relative to ordito
ordito (CUDA) 56.6 µs 1x
MeshLib 25.54 ms 451x
All inputs
Input ordito (CUDA) MeshLib
saddle_small 59.4 µs 49.4 µs
saddle 60.6 µs 99.2 µs
rim_long 56.6 µs 25.54 ms

Without a reference

No other library computes these, so they have no comparison. ordito (CUDA)'s median time on the largest input it was measured on:

Function Input ordito (CUDA)
is_closed saddle_small 33.4 µs
polyline_open saddle_small 44.8 µs
polyline_close rim_long 37.2 µs
polyline_centroid rim_long 59.5 µs
polyline_normal rim_long 57.7 µs
polyline_radius rim_long 59.4 µs
polyline_angles rim_long 25.1 µs
cumulative_arc_length rim_long 50.3 µs
polyline_smooth_upsample rim_long 65.0 µs
polyline_upsample_closed rim_long 65.1 µs
polyline_downsample_closed rim_long 135.8 µs
polyline_resample_closed rim_long 58.0 µs
polyline_point_distance_closed rim_long 467.9 µs
polyline_triangulate_from_offsets n_loops=4096 2.43 ms