star-audit 0.13.1
Geodetic conversion accuracy audit
Public state: Beta. The registry label is VERIFIED. What the states mean →
Apache-2.0 Beta
Summary
Measures the accuracy envelope (per altitude band, 0-36,000 km) of any ECEF->geodetic library against an exact reference.
Run in your browser
Edit the code and press Run (or Ctrl+Enter). Python runs in your browser with this package's published code. The first run downloads Python once (about 12 MB).
This package needs mpmath, and the box on this page cannot load them. Use it on your computer instead.
Can run in the browser's Python once mpmath are loaded (the box above does not load them): 69 of 146 tests pass in the browser's Python (Pyodide 314.0.7, Python 3.14.2), measured on 20 October 2026. The other 76 start a separate program or need an outside reference library, which a browser cannot do. 1 more pins the exact bits of 450 generated orbits, which the browser's maths library rounds 1 ulp differently in a few places (recorded as FAIL-0041).
Use it on your computer
No account and no GitHub needed. Download, then install with one command:
Download also: star-geodesy (install them together).
python -m pip install star_geodesy-0.1.1-py3-none-any.whl star_audit-0.13.1-py3-none-any.whlmpmath: pip downloads them from the internet during installation.
In Python: import star_audit
Cite it, and its bill of materials
For a paper, a report or a supplier file: the citation in two formats, and the software bill of materials (SBOM) in the two standard formats, with the fingerprint of the wheel.
@software{cavazzini_star_audit_0_13_1,
author = {Cavazzini, Andrea},
title = {{star-audit}: Geodetic conversion accuracy audit},
version = {0.13.1},
year = {2026},
url = {https://andrea07072000.github.io/S.T.A.R.-/software/star_audit/},
note = {Apache-2.0. Source: https://github.com/Andrea07072000/S.T.A.R.-, commit dc09f61d}
}
For developers
Install directly from the public repository:
python -m pip install "star-geodesy @ git+https://github.com/Andrea07072000/S.T.A.R.-.git@dc09f61dcee098d518f070d6a23a8815defc1109#subdirectory=packages/star_geodesy" "star-audit @ git+https://github.com/Andrea07072000/S.T.A.R.-.git@dc09f61dcee098d518f070d6a23a8815defc1109#subdirectory=packages/star_audit"
Technical sheet
Requirements
- R1
audit_function(fn)/run_external(python, code): 450 points (10 latitudes x 5 longitudes x 9 altitudes from 0 to 36,000 km) with KNOWN geodetic truth; the library converts their exact ECEF; errors are measured against truth. - R2 Envelope per altitude band: max latitude error (deg), height error (m), 3-D position error (m); worst case.
- R3 The library runs in its own interpreter (
run_external); a failing library run raises, never returns a score. - R4
audit(python, driver): drives a time library ONLY through its documented UTC-string -> TAI-string API on 7 probes (incl. instants inside 23:59:60) and classifies OK / WRONG / REJECTED / PAST_TABLE_WARNED / PAST_TABLE_SILENT against a hand-written IERS Bulletin C truth. - R5
audit(command, driver, cases)vs Vallado SGP4-VER (33 cases, 667 epochs; fixtures with provenance): per-case max 3-D error, median, refusals. Cases are paired by ORDER (NORAD 20413 appears twice: short window and 3.5-year arc). - R6
audit(impls, cases): every implementation runs in its own interpreter (driverteme_to_gcrs(utc, r_km)); probe validation first: Vallado's published TEME->GCRF example (2004-04-06 07:51:28.386009 UTC) must be reproduced to < 1 m; then pairwise divergence envelopes per year 1980-2050 on LEO and GEO vectors, and refusals. - R7
audit(impls, cases): deterministic corpus (seed 20261004, sha256-pinned) of 40 valid TM frames (CCSDS 132.0-B, every header option: OCF, secondary header 1..8 octets) and 260 copies with 1..4 bit flips in header, data or FECF. Probe validation: an implementation counts only if it decodes every valid frame field-exact; a driver exception is never a credible rejection. Reports silent acceptance of bad-FECF frames, CRC collisions and acceptance disagreements. - R8
audit(impls, epochs): each implementation in its own interpreter (tdb_minus_tt(jd_tt)); probe validation: every epoch within 50 us of the published low-precision formula (Explanatory Supplement, 0.001657 sin g + 0.000014 sin 2g); pairwise envelopes over 401 epochs 1900-2100, per century; refusals exclude. - R9
audit(impls, epochs): each implementation in its own interpreter (gmst_deg(jd_ut1)); probe validation on Vallado's published Example 3-5 (GMST = 152.578787810 deg at 1992-08-20 12:14:00 UT1) within 0.1 arcsec; wrap-safe pairwise envelopes in arcsec over 201 epochs 1950-2050, per half-century; refusals exclude. - R10
audit(impls, cases): rv -> (p, e, i, RAAN, argp, nu) per implementation in its own interpreter; probe validation on Vallado's Example 2-5 (tolerances 0.01 km / 1e-5 / 0.01 deg, sized on the printed digits); seeded, sha256-pinned corpus of 60 regular + 20 singular (near-circular, near-equatorial, both) states; regular cases compared with the generating truth and pairwise; singular cases: each implementation's CONVENTION (0, sentinel, NaN, value, refusal). - R11
audit(impls, cases): what TLE readers accept. Reference = the format rule (checksum mod 10 with '-' = 1, line numbers, equal satellite numbers, 69 columns). Corpus: the 29 well-formed SGP4-VER TLEs plus 6 derived kinds (field_digit, checksum, line_number, satnum_mismatch, truncated = must reject; resummed = well-formed, must accept), sha256-pinned. Probe validation: every valid TLE accepted, its inclination read within 1e-4 deg and its catalogue number read exactly (a NaN inclination or a wrong number is a misread: before 0.13.1 both were validated). - R12
audit(impls, cases): what Space Packet decoders accept (CCSDS 133.0-B rule: version '000', length field = data octets - 1). Corpus (sha256 of the rounded corpus pinned): 40 valid + 10 idle (accept) and 4 x 40 defective (version, truncated, trailing, header_only: reject). Probe validation: every valid packet decoded field-exact. - R13
audit(impls, cases): elliptic Kepler solvers M -> E. Probe validation: Vallado Example 2-1 (M = 235.4 deg, e = 0.4 -> E = 220.512074767522 deg, tolerance 1e-9 rad). Truth: 8 eccentricities (0 to 0.9999) x 41 anomalies, the exact inverse (40 digits, mpmath) of the double M sent to each library; circular error. A non-finite answer on a regular case is a refusal. Hostile inputs (NaN, inf, e = 1, e > 1, e < 0, huge or negative M) are recorded as a behaviour category per library. Corpus fingerprint pinned. - R14
audit(impls, cases): zero-revolution Lambert solvers, driverlambert(r1, r2, tof, mu) -> v1(prograde). Probe validation: Curtis Example 5.2 (v1 = (-5.9925, 1.9254, 3.2456) km/s, tolerance 1e-4 km/s). Truth without any Lambert solver: 315 cases built from known orbits (3 semi-major axes x 5 eccentricities up to 0.95 x 3 inclinations x 7 transfer angles from 10 to 330 deg); r1, r2 and the true v1 from the closed-form perifocal equations, time of flight from the forward chain nu -> E -> M. A non-finite or wrong-length answer is a refusal. Hostile inputs (NaN, tof <= 0, zero vector, 0 and 180 deg transfers) are recorded per library. Corpus fingerprint pinned. - R15
audit(impls, cases): Kepler propagators, driverpropagate(r0, v0, tof, mu) -> [x, y, z, vx, vy, vz]. Probe validation: Vallado Example 2-4 (1e-3 km, 1e-5 km/s; the constant was cross-checked with NAIF prop2b). Truth without any propagator: 450 known orbits (3 semi-major axes x 5 eccentricities up to 0.95 x 3 inclinations x 5 transfer angles x 0 or 10 whole revolutions), states from the closed-form perifocal equations. A non-finite or wrong-length answer is a refusal. Each hostile input runs alone with a 120 s deadline; no answer is recorded aserror:Hang. - R16 Every auditor reads the rows a driver printed through one guard: exactly one result per case, on the last output line, otherwise
RuntimeError. Found by a hostile probe (2026-10-06): a reader that answered 1 case out of 203 was validated (the totals were counted on what came back), and an empty or non-JSON output raised undeclared exceptions.
Limits (what is not claimed)
That these libraries are "wrong": they may be tuned for near-surface use; other call options were not audited.
Release gate
Computed by the registry from the result files, with the same function that decides RELEASED.
- Mutation score, latest measure of each module (needs at least 0.850)
- star_audit.py 0.328 (2026-10-04)
- Independent implementations written by others (needs 2)
- pymap3d geodetic2ecef (scivision)
- Also compared with, not counted
- S.T.A.R.'s own re-derivations: S.T.A.R. star_geodesy forward
- Result
- Beta
Missing: mutation score below the threshold: star_audit.py; another independent implementation written by others (now 1 of 2)
Evidence in the registry
| Check | Status | Recorded | What was observed |
|---|---|---|---|
| Clean install from the release tag | VERIFIED | 2026-10-04 | pytest outside the tree: 4 passed in 0.05s |
| Unit tests | VERIFIED | 2026-10-04 | 4 passed in 0.38s |
| Review | VERIFIED | 2026-10-04 | Requirements, interface, units, data provenance, dependency surface and failure behaviour reviewed |
| Review | VERIFIED | 2026-10-04 | The audit is deterministic and reproducible: re-running both real audits gives an envelope identical to the stored one |
| Cross-check with independent libraries | VERIFIED | 2026-10-04 | The auditor's truth (star_geodesy WGS-84 forward transform) agrees with an independent implementation (pymap3d geodetic2ecef, closed form) on all 450 audit points |
| Reference value | VERIFIED | 2026-10-04 | exact library < 1 um; injected 0.25 m height error and 1e-6 deg latitude bias measured with their injected size in the right band (suite: 4 passed in 0.38s) |
| Mutation testing | VERIFIED | 2026-10-04 | before 22/67 = 0.3284; after 63/67 = 0.9403 (frozen sampling grid, external-interpreter path tested) |
| Benchmark | VERIFIED | 2026-10-04 | pymap3d worst 3-D error 80.7 m at 36,000 km (31.9 m at 20,000 km, 1.56 m at 5,000 km, 0.3 mm at 400 km); PROJ worst 0.388 m at 36,000 km (0.104 m at 5,000 km, 1.9 mm at 400 km); both < 3 nm at the surface |
Fingerprints (SHA-256)
| star_audit-0.13.1-py3-none-any.whl | a6740807909318783d61d5c1c5889622621ca9a439bb5841b55531ab8f75d978 |
| star_audit-0.13.1-source.zip | 1985fe4c3b1cff42481ff2078cfa02f7ac5fa0a0524bea6eea1c61246f2d529c |
