Skip to main content

Efficient great circle computation and projection library with access to EPSG dataset public API

Project description

Python epsglide package

This package aims to perform simple requests to EPSG GeoRepository API and use associated geodesic computation or map projections.

EPSG dataset requests and projection

epslide provides several dataset classes to manage parameters and populate the toplevel class ProjectedCoordRefSystem. This toplevel class allow projection and contains other dataset classes to perform geodetic computations.

>>> import math, epsglide
>>> crs = epsglide.ProjectedCoordRefSystem(26730)
>>> crs
<ProjectedCoordRefSystem 26730: NAD27 / Alabama West>
>>> point = epsglide.Geodetic(math.degrees(crs.lambda0), math.degrees(crs.phi0))
>>> crs(point)
<US survey foot:3.281[X=152400.305 Y=0.000] alt=0.000>
>>> crs(crs(point))
<lon=-087d18m0.00000s lat=+030d00m0.00000s alt=0.0>

EPSG dataset conversion

>>> osgb36 = epsglide.ProjectedCoordRefSystem(27700)
>>> lla = osgb36(epsglide.Geographic(400000, -100000, 0))                       
>>> osgb36.GeodeticCoordRefSystem.to_wgs84(lla)
<lon=-002d00m0.00000s lat=+049d00m2.50812s alt=-529.126>
>>> lla
<lon=-002d00m0.00000s lat=+049d00m0.00000s alt=0.0>

Great circle computation

>>> wgs84 = epsglide.dataset.Ellipsoid(7030)
>>> dublin = epsglide.Geodetic(-6.272877, 53.344606, 105.)
>>> london = epsglide.Geodetic(-0.127005, 51.518602, 0.)
>>> dist = wgs84.distance(dublin, london) 
>>> dist
<464.572km initial bearing=113.5° final bearing=118.3°>
>>> wgs84.destination(dublin, dist) 
<lon=-000d07m37.21798s lat=+051d31m6.96719s end bearing=118.3°>
>>> london
<lon=-000d07m37.21800s lat=+051d31m6.96720s alt=0.0>

Support this project

Paypal me Bitcoin

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

EPSGlide-0.2.2.tar.gz (24.8 kB view details)

Uploaded Source

File details

Details for the file EPSGlide-0.2.2.tar.gz.

File metadata

  • Download URL: EPSGlide-0.2.2.tar.gz
  • Upload date:
  • Size: 24.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for EPSGlide-0.2.2.tar.gz
Algorithm Hash digest
SHA256 a192593cc40c94c73b5a6af5ff23d56bdc8df16e53b5058ef529312c5e8358cd
MD5 80e2ce5065b5c75d8d77d91f953bd425
BLAKE2b-256 b8b8bb44a7a3b64e35c2aa688fc64a8ad1d675c42deaef3d7f9ce94153e4d435

See more details on using hashes here.

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