• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

uber / h3-go / 27735272019
100%
master: 100%

Build:
Build:
LAST BUILD BRANCH: justinhwang/forward-gnomonic-opt
DEFAULT BRANCH: master
Ran 18 Jun 2026 03:47AM UTC
Jobs 1
Files 18
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

18 Jun 2026 03:44AM UTC coverage: 99.765%. First build
27735272019

push

github

justinhwang
perf: fold toVec3 inverse projection into precomputed trig + one sqrt

toVec3 (the inverse gnomonic projection behind CellToLatLng, CellToBoundary,
CellArea*, EdgeLength*, vertex/edge boundaries, and the polygon paths) computed
atan2 + atan + two sin/cos pairs per call. Replace them with algebra:
  - cos/sin of the in-plane angle taken directly from the vector (no atan2);
  - per-face azimuth and the Class III rotation folded in via angle-addition
    against precomputed cos/sin tables;
  - the inverse gnomonic via cos(atan r)=1/sqrt(1+r^2), sin(atan r)=r/sqrt(1+r^2)
    (one sqrt, no atan/sin/cos), dropping posAngleRads since only sin/cos are used.

Five transcendental calls become one sqrt. The transform is algebraically
exact; output differs from C only at the ULP level, well within the parity
suite's 1e-5 relative tolerance. toLatLng is left as-is (its asin/atan2 are the
returned angles). All white-box and parity tests pass.

benchstat, pure-Go before -> after (Apple M3 Max, count=10, benchtime=100ms):

                              │    sec/op    │   sec/op     vs base                │
CellToLatLng-16                  160.4n ± 2%   126.4n ± 1%  -21.20% (p=0.000 n=10)
CellLatLng-16                    160.6n ± 0%   126.4n ± 2%  -21.35% (p=0.000 n=10)
CellToBoundary-16                648.1n ± 1%   438.9n ± 2%  -32.28% (p=0.000 n=10)
CellBoundary-16                  647.2n ± 1%   463.8n ± 3%  -28.35% (p=0.000 n=10)
CellAreaRads2-16                 813.8n ± 0%   631.3n ± 3%  -22.43% (p=0.000 n=10)
CellAreaKm2-16                   814.5n ± 1%   612.9n ± 2%  -24.76% (p=0.000 n=10)
CellAreaM2-16                    823.4n ± 3%   610.4n ± 1%  -25.87% (p=0.000 n=10)
EdgeLengthRads-16                394.0n ± 1%   329.4n ± 3%  -16.38% (p=0.000 n=10)
EdgeLengthKm-16                  395.2n ± 3%   327.1n ± 3%  -17.22% (p=0.000 n=10)
EdgeLengthM-16                   397.2n ± 1%   331.0n ± 1%  -16.66% (p=0.000 n=10)
HexagonEdgeLengthAvgKm-16        7.874n ± 2%   ... (continued)

26 of 26 new or added lines in 1 file covered. (100.0%)

4247 of 4257 relevant lines covered (99.77%)

3180241.19 hits per line

Jobs
ID Job ID Ran Files Coverage
1 Go- - 27735272019.1 18 Jun 2026 03:47AM UTC 18
99.77
GitHub Action Run
Source Files on build 27735272019
  • Tree
  • List 18
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 60e55104 on github
  • Prev Build on justinhwang/paritytest-benchmarks (#27734636814)
  • Next Build on justinhwang/tovec3-projection-opt (#27736352283)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc