geodetic_engine.osdudb

Build a custom PROJ database from an OSDU coordinate reference catalogue.

The catalogue is a single OSDU manifest file holding reference-data--CoordinateReferenceSystem and reference-data--CoordinateTransformation records, so a build needs no credentials and no network. download_official_catalog() fetches the one OSDU publishes.

The database this produces is the same artefact the Georepository workflow in geodetic_engine.projdb produces, written by the same writer against the same frozen schema and checked by the same validator; only the source of the definitions differs.

The public surface is deliberately small: a configuration object, a build function, a validation function, and the errors they raise.

A release wheel also ships the official catalogue already built into PROJ’s database, and PROJ reads it unless another database was chosen. An installed distribution can provide a database in its place, through the entry point group geodetic_engine.proj_data. active_database() reports which database PROJ reads and why, and use_bundled_database() switches the bundled one on or off.

Functions

active_database

Report the proj.db PROJ reads and why.

build

Build an enriched proj.db from an OSDU coordinate reference catalogue.

download_official_catalog

Download the official OSDU catalogue and verify it.

load_config

Build an OsduBuildConfig from file, environment and overrides.

use_bundled_database

Switch the bundled database on or off.

Classes

ActiveDatabase

The proj.db PROJ reads, and why it is that one.

CatalogDownload

The official OSDU catalogue, downloaded and verified.

OsduBuildConfig

Resolved configuration for one proj.db build from an OSDU catalogue.

OsduCatalog

An indexed OSDU manifest.

Exceptions

CatalogDownloadError

The official OSDU catalogue could not be downloaded, or not verified.

OsduCatalogError

The OSDU catalogue file cannot be read or is not a manifest.

UnreadableDefinitionError

An OSDU record carries no WKT, or WKT that PROJ will not parse.

Supporting types

Not exported from the subpackage, but returned or accepted by something that is.

catalog.Record

One reference data record, identified the way proj.db identifies things.

Re-exported

Importable from here for convenience; documented where they are defined.