nmandery/h3ron

FYI: HexSet

JayKickliter opened this issue · 6 comments

This is not an issue. I just want to share a crate that uses h3ron and may be of interest to you and your users: HexSet.

TLDR: we wanted a way to check if points lay in large H3 polyfills which is faster than our current linear search. Hit testing went from the order of 50 uS down to one or two digit nS on my sludgy 2013 Mac Pro.

Nice, thank you for the link. The library looks very interesting - I already had a few times where I could have used something like this.

Have you thought about publishing it on crates.io?

Yep. Planning on it. I just need to nuke git history and make some documentation tweaks.

Fun observation: creating a large HexSet is about 20 times faster than h3's compaction algorithm. HexSet automatically compacts, implying it could be useful for compaction alone. This would depend on a not-yet-implemented iterator for all elements in the set which will have overhead.

Sounds great! With how many cells did you make this observation?

BTW: In case you do not want to maintain your library as its own crate, you can also create a PR in this repo here. I can also make you a collaborator.

I love the idea of handing it off. We're still working on it, and just converted it to be a HexMap (still h3 aware and still compacts when children have the same value). As long as it makes to, I will definitely open a PR when it stabilizes.

Perfect - looking forward to it.