Skip to content

feat(vortex-spatial): add convex hull scalar function - #9219

Open
HarukiMoriarty wants to merge 3 commits into
nemo/geo-collectfrom
nemo/geo-convex-hull
Open

feat(vortex-spatial): add convex hull scalar function#9219
HarukiMoriarty wants to merge 3 commits into
nemo/geo-collectfrom
nemo/geo-convex-hull

Conversation

@HarukiMoriarty

@HarukiMoriarty HarukiMoriarty commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add a strict native MultiPoint to Polygon convex-hull scalar function
  • delegate planar hull computation directly to geo::ConvexHull
  • preserve CRS and outer nullability while materializing native 2-D Polygon storage
  • use shared unary dispatch for constants and strict null propagation
  • cover empty, one-point, collinear, nullable, constant, and Q5-style collect-to-hull-to-area execution
  • add a dedicated convex-hull microbenchmark

Semantics

The return dtype is always native Polygon, including empty and degenerate hulls. Consistent with the current geometry-kernel policy, coordinate finiteness is unchecked unless validation is explicitly enabled; this function does not add per-call NaN validation.

@codspeed-hq

codspeed-hq Bot commented Aug 6, 2026

Copy link
Copy Markdown

Merging this PR will regress 1 benchmark

⚡ 23 improved benchmarks
❌ 1 regressed benchmark
✅ 1925 untouched benchmarks
🆕 18 new benchmarks
⏩ 85 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
Simulation cast_i32_to_u32[65536] 1.8 ms 2.8 ms -35.51%
Simulation decompress[u64, (1000, 16)] 133.4 µs 65 µs ×2.1
Simulation polygons 211.9 µs 167.2 µs +26.74%
Simulation linestrings 211.3 µs 167.1 µs +26.49%
Simulation points 208.2 µs 164.7 µs +26.4%
Simulation list_sum_small 280.4 µs 237.2 µs +18.21%
Simulation multipolygon_random_nulls 941.5 µs 811.9 µs +15.97%
Simulation nullable_points 396.6 µs 344.7 µs +15.05%
Simulation envelope_of_collected_points 559.4 µs 487.7 µs +14.7%
Simulation multipolygon_mixed_validity 1.2 ms 1.1 ms +12.81%
Simulation take_filter_list_slice_mask_sequential_indices[768, 50] 237.7 µs 211.2 µs +12.55%
Simulation multipolygon_non_nullable 1.2 ms 1.1 ms +12.38%
Simulation take_filter_list_random_mask_sequential_indices[768, 50] 233.4 µs 207.8 µs +12.33%
Simulation take_filter_list_small_random_mask_random_indices[256, 10] 232.5 µs 208.3 µs +11.61%
Simulation take_filter_list_slice_mask_sequential_indices[256, 50] 237.5 µs 213.1 µs +11.47%
Simulation take_filter_list_small_uncached_random_mask_random_indices[256, 10] 232.8 µs 209 µs +11.42%
Simulation take_filter_list_random_mask_sequential_indices[256, 50] 238.4 µs 214.1 µs +11.34%
Simulation take_filter_list_slice_mask_random_indices[256, 50] 236.1 µs 212.4 µs +11.14%
Simulation take_filter_list_nullable_random_mask_random_indices[256, 50] 256.8 µs 231.2 µs +11.07%
Simulation take_filter_list_small_uncached_random_mask_random_indices[768, 10] 240.6 µs 216.6 µs +11.06%
... ... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing nemo/geo-convex-hull (4045fa5) with nemo/geo-collect (1f9f067)2

Open in CodSpeed

Footnotes

  1. 85 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

  2. No successful run was found on nemo/geo-collect (de907e5) during the generation of this report, so 64e3381 was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@HarukiMoriarty
HarukiMoriarty force-pushed the nemo/geo-convex-hull branch 2 times, most recently from 302bc8f to ddf9146 Compare August 6, 2026 20:15
@HarukiMoriarty HarukiMoriarty changed the title feat(vortex-geo): add convex hull scalar function feat(vortex-spatial): add convex hull scalar function Aug 7, 2026
Signed-off-by: Nemo Yu <zyu379@wisc.edu>
Signed-off-by: Nemo Yu <zyu379@wisc.edu>
Signed-off-by: Nemo Yu <zyu379@wisc.edu>

@connortsui20 connortsui20 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/feature A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants