forked from hypermodeinc/dgraph
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replaced s2 contains point methods with go-geom (hypermodeinc#5023)
Leads to significantly higher performance. ``` goos: linux goarch: amd64 BenchmarkMatchesFilterContainsPoint-8 3902 312904 ns/op BenchmarkMatchesFilterContainsPoint_Before-8 31 35054224 ns/op PASS ok command-line-arguments 2.636s ``` From my testing while working on a project of my own I found that while using s2 types is very fast, converting to them is very slow, so if you're converting each time it's much faster to just use the go-geom types directly. This PR just changes this for contains point queries.
- Loading branch information
Showing
2 changed files
with
42 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters