geodetic_engine.geodesy

Coordinate transformation with the geodetic guarantees this package exists for.

Public entry points:

Coordinate values are always ordered xy: longitude before latitude, easting before northing, then height. A CRS’s EPSG-declared axis order is reported separately, is often different, and is never silently reinterpreted. Points are passed as plain lists, tuples or 2D numpy arrays – there is no coordinate wrapper type to construct first. A result’s coordinates behaves the same way on the way out (indexing, iteration, equality), with Coordinates’s to_list(), to_numpy() and to_dataframe() added for exporting it in a specific format.

Example

>>> from geodetic_engine.geodesy import transform
>>> result = transform(
...     "EPSG:4258", "EPSG:25832", [(10.7522, 59.9139)],
...     operation="EPSG:16032",
... )
>>> result.operation.authority_code
'EPSG:16032'
>>> result.target_axes, result.coordinate_order
(('E', 'N'), 'xy')

Functions

available_operations

List every coordinate operation PROJ offers between two CRSs.

transform

Transform points between two CRSs in one call.

Classes

AppliedOperation

Which coordinate operation was applied, against which was requested.

AreaOfUse

The bounding box an operation or CRS is stated to be valid within.

AxisSpec

One axis of a CRS, exactly as the EPSG dataset declares it.

CoordinateReferenceSystem

A resolved CRS together with the axis roles and units it declares.

Coordinates

Transformed coordinate values, one tuple per point.

GridUsage

A grid file a transformation depends on.

OperationCandidate

One coordinate operation PROJ offers for a CRS pair, not yet applied.

OperationRequest

A caller's request for a particular coordinate operation.

OperationRoute

How the transformer that will be used was arrived at.

OperationStep

One substantive coordinate operation within a candidate.

StatedOperation

Something that states a coordinate operation outright.

Transformation

A resolved, reusable transformation between two CRSs.

TransformationResult

Transformed coordinates together with everything that produced them.

Exceptions

AmbiguousOperationError

No operation was requested and more than one defensible choice exists.

BallparkTransformationError

The only path between the two CRSs is a ballpark approximation.

CoordinateOutOfRangeError

An input coordinate is outside the range its axis can represent.

GeodesyError

Base class for all coordinate transformation failures.

MissingCoordinateEpochError

A time-dependent transformation was asked for without a coordinate epoch.

MissingGridError

The transformation needs a grid file that is not installed.

NotCollapsibleError

A concatenated operation cannot be reduced to a single equivalent step.

OperationNotAvailableError

The requested EPSG coordinate operation cannot be applied to this pair.

TransformationFailedError

PROJ could not produce a finite result for one or more coordinates.

UnembeddableOperationError

An operation cannot be stated in the form a bound CRS requires.

UnresolvableCRSError

A CRS could not be constructed from the given input.