Registry / data / spherical-geometry

spherical-geometry

JSON →
library1.4.0pypypiunverified

Python tools for spherical geometry, providing vectorized operations on the sphere using NumPy. Current version 1.4.0, released approximately monthly.

pip install spherical-geometry
INSTALL
IMPORT
SIG · SPHERICAL-GEOMETRY
S
spherical-geometry
datapythonv1.4.0
Install
5.4s avg
Import
—
Disk
128MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.9–3.13
musl
3.9–3.13
Install & Compatibility
Where this runs
tested against v1.3.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 166.6MB
glibc
py 3.10–3.95 runs
installs and imports cleanly · install 5.4s · import 0.000s · 165MB
128MB installed
● package 128MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Arc
✓ from spherical_geometry import Arc
✗ from spherical_geometry import Arc

Basic usage of Arc and GreatCircle for spherical geometry calculations.

from spherical_geometry import Arc, GreatCircle # Define two points on the sphere (longitude, latitude in radians) point_a = (0.0, 0.0) point_b = (1.0, 0.5) # Create a great circle arc arc = Arc(point_a, point_b) print(f"Arc length: {arc.length()}") # Compute intersection of two great circles gc1 = GreatCircle(point_a, point_b) gc2 = GreatCircle((0.5, 0.2), (1.2, 0.8)) intersections = gc1.intersections(gc2) print(f"Intersection points: {intersections}")
Debug
Known issues
breakingIn version 1.4.0, the import paths for Arc and GreatCircle changed. Previously they were in submodules; now they are exported at the top-level package. Code using old imports will fail.
fix
Use `from spherical_geometry import Arc, GreatCircle` instead of `from spherical_geometry.polygon import Arc` or `from spherical_geometry.great_circle import GreatCircle`.
affects: >=1.4.0
gotchaAll angular coordinates (longitude, latitude) must be in radians, not degrees. The library does not perform conversion, and passing degrees will give incorrect results.
fix
Convert degrees to radians using `math.radians()` or `numpy.radians()` before passing to functions.
affects: all
deprecatedThe `spherical_geometry.polygon` module is deprecated as of 1.4.0. Its contents have been moved to the top-level package.
fix
Use top-level imports as shown in the quickstart.
affects: 1.4.0
Upgrade
Version history
1.4.0latest on PyPI · released Mar 11, 2026
Audit
Dependencies
numpyrequiredRequired for vectorized operations on arrays of points.
Agent activity
18 hits · last 30 days
node
12
OpenAI (training)
1
Resources
spherical-geometry — pip install spherical-geometry · libregistry