Skip to main content

Python bindings for the Sidereon GNSS positioning engine (SP3 loading and SPP/RTK/PPP solves)

Project description

sidereon

GNSS and astrodynamics for Python: propagate satellites, predict passes, solve precise positions (SPP / RTK / PPP), and convert between coordinate frames and time scales — checked against the references the field trusts (Vallado, Skyfield, IGS, IERS).

Under the hood it's a Rust engine compiled into the wheel, so it's fast and the only runtime dependency is numpy. You just pip install sidereon.

Install

pip install sidereon
import sidereon
print(sidereon.__version__)

Quickstart: when does the ISS fly over you?

No data files, no setup — give it a two-line element set and a ground station, and ask when the satellite is above the horizon.

import sidereon
from datetime import datetime, timedelta, timezone

# Real orbital elements (grab fresh ones from CelesTrak any time).
iss = sidereon.Tle(
    "1 25544U 98067A   26178.50947090  .00006280  00000+0  12016-3 0  9996",
    "2 25544  51.6322 248.9966 0004278 238.4942 121.5629 15.49454046573359",
)

# A ground station: latitude, longitude in degrees (altitude in metres, optional).
berkeley = sidereon.GroundStation(37.87, -122.27)

# Every pass above 10° over the next 24 hours.
now = datetime.now(timezone.utc)
us = lambda t: int(t.timestamp() * 1_000_000)  # epochs are UTC unix microseconds
passes = iss.find_passes(
    berkeley, us(now), us(now + timedelta(days=1)), elevation_mask_deg=10.0
)

for p in passes:
    rise = datetime.fromtimestamp(p.aos_unix_us / 1e6, timezone.utc)
    print(f"{rise:%H:%M} UTC · {p.duration_s / 60:4.1f} min · peak {p.max_elevation_deg:2.0f}°")

Tle also gives you propagate() (TEME state arcs as numpy arrays) and look_angles() (azimuth/elevation/range over a time grid). Everything that takes time takes UTC unix microseconds and returns numpy arrays.

Precise positioning

The positioning engine is the other half of the library: feed it pseudoranges and a precise-ephemeris product and it returns a least-squares fix.

import sidereon

sp3 = sidereon.load_sp3(open("igs_product.sp3", "rb").read())

config = sidereon.SppConfig(
    observations=[
        sidereon.SppObservation("G01", 21_000_123.4),  # PRN, pseudorange (m)
        sidereon.SppObservation("G08", 22_517_889.1),
        # ...more satellites
    ],
    t_rx_j2000_s=...,          # receiver time
    t_rx_second_of_day_s=...,
    day_of_year=...,
    initial_guess=[0.0, 0.0, 0.0, 0.0],
    corrections=sidereon.SppCorrections(ionosphere=True, troposphere=True),
    with_geodetic=True,
)

fix = sidereon.solve_spp(sp3, config)
print(fix.position)   # numpy [x, y, z] ECEF metres
print(fix.geodetic)   # (lat_rad, lon_rad, height_m)
print(fix.used_sats)  # satellites that contributed

solve_rtk_float, solve_rtk_fixed, solve_ppp_float, and solve_ppp_fixed follow the same shape — typed config in, a result object with numpy positions, scalar attributes, and enum statuses out. Need the products? sidereon.data fetches and caches SP3, RINEX, and IONEX from the public archives.

What's in the box

  • Orbits — SGP4/TLE and OMM, numerical propagation, passes, look angles, visibility
  • Frames & time — TEME ↔ GCRS ↔ ITRS, GMST/GAST, geodetic ↔ ECEF, UTC/TT/TDB/UT1
  • Bodies — Sun/Moon positions, eclipse, plus JPL SPK (DAF/.bsp) kernels
  • Positioning — SPP, RTK (float/fixed), PPP (float/fixed), DOP, velocity
  • GNSS data — SP3, RINEX (obs/nav/clock), CRINEX, ANTEX, IONEX, broadcast ephemeris
  • Space situational awareness — conjunction/TCA screening, collision probability, CDM, covariance
  • RF — link budget (FSPL, EIRP, C/N0, antenna gain)

The binding adds no modeling of its own: every result is exactly what the engine computes, returned as numpy arrays, typed objects, and real Python exceptions (sidereon.SidereonError and friends). Full signatures live in the bundled type stubs (sidereon/__init__.pyi).

Other languages

sidereon is one validated engine with first-class interfaces in Rust, Python, C, Elixir, and WebAssembly — same numbers everywhere. See the live demo and docs at sidereon.dev.

How it's validated

The SGP4 propagator is a Rust port of David Vallado's reference implementation, bit-exact to it. Frames and time are checked against Skyfield and IERS; the positioning stack is checked against IGS products. The wheel links the Rust sidereon-core engine statically, so there's no separate native install.

Building from source (for contributors): pip install maturin, then maturin develop from the repo. Tests: pytest.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sidereon-0.9.0.tar.gz (950.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

sidereon-0.9.0-cp39-abi3-win_amd64.whl (3.5 MB view details)

Uploaded CPython 3.9+Windows x86-64

sidereon-0.9.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

sidereon-0.9.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (3.9 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

sidereon-0.9.0-cp39-abi3-macosx_11_0_arm64.whl (3.7 MB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

sidereon-0.9.0-cp39-abi3-macosx_10_12_x86_64.whl (3.9 MB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file sidereon-0.9.0.tar.gz.

File metadata

  • Download URL: sidereon-0.9.0.tar.gz
  • Upload date:
  • Size: 950.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for sidereon-0.9.0.tar.gz
Algorithm Hash digest
SHA256 f060f8a994d1c7bbd3a2f773838f8426385f733dabb905ef76be6ab84019cfc0
MD5 41dffdffbc026bb18098016e6d211bc4
BLAKE2b-256 fd67cc2681278ee03353107b11820e8163697826206c10085f3caa7a5996c9fe

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0.tar.gz:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sidereon-0.9.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: sidereon-0.9.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 3.5 MB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for sidereon-0.9.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 ec2794dacfa352d8e285047ee2aed60059ef49d09504490841fcaf21d508919b
MD5 79fa5db124c8e763270a4826259d8e41
BLAKE2b-256 6158d657232bac4f00828260aaf97557a711ff474cfc3bc6db2688b81bce0b3b

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0-cp39-abi3-win_amd64.whl:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sidereon-0.9.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for sidereon-0.9.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e87cc4167aad3bef1b17366cab5c120dba9973fc3db9f47e2113869d6d0fa4cd
MD5 aae8b39bc002d1c6cb354b5aa8e6e52c
BLAKE2b-256 6cca5174244cf9f88181c2322c52a35c7a87fe55a9a85dc37a1918db6afbeb71

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sidereon-0.9.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for sidereon-0.9.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 04451427d075046c47ae98ecce4999204b6a5920ea16772c153ec088e7cf7c6d
MD5 66766308861b21d185aa9244a44aea3c
BLAKE2b-256 16177cbdf6dd8b2f42e3c99137635dd219b0d45ea69edf2fe1d532ece83d6b8c

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sidereon-0.9.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for sidereon-0.9.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 91992a47545f4caae2c056136aa2b7468082d156f03e485238190104b6946505
MD5 394505b16438a20201f322b861c12c25
BLAKE2b-256 5072c782405cb5bd8499c4a482a6e782d989f094a45e9debc40fe09860a06275

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sidereon-0.9.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for sidereon-0.9.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 1208c000e968062a263fa208104e73ebecfdd05fad70aabf6cb59a02d55d3cac
MD5 9b9396a8058ce4497077d916dcce5f34
BLAKE2b-256 8ce6fcccf90cad6f60273f6e6ac6367f26789bd3a5428647483d7134fd223da4

See more details on using hashes here.

Provenance

The following attestation bundles were made for sidereon-0.9.0-cp39-abi3-macosx_10_12_x86_64.whl:

Publisher: release.yml on neilberkman/sidereon-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page