diff --git a/404.html b/404.html index 37a47e8..c231ef7 100755 --- a/404.html +++ b/404.html @@ -41,6 +41,9 @@ + +

+

__call__

+
def __call__(
+    element: typing.Union[Geodetic, Geographic]
+) -> typing.Union[Geodetic, Geographic]
+
+

+

transform

+
def transform(element: typing.Union[Geodetic, Geographic],
+              dest_crs) -> Geographic
+
diff --git a/geodesy/index.html b/geodesy/index.html index 286134a..a320382 100755 --- a/geodesy/index.html +++ b/geodesy/index.html @@ -41,6 +41,9 @@ + @@ -98,7 +109,7 @@

Python epsglide package

-

This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection.

+

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

EPSG dataset requests and projection

>>> import math, epsglide
 >>> crs = epsglide.ProjectedCoordRefSystem(26730)
@@ -110,6 +121,14 @@ 

EPSG dataset requests and projecti >>> 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.Geodesic(-6.272877, 53.344606, 105.)
@@ -121,7 +140,11 @@ 

Great circle computation

<lon=-000d07m37.21798s lat=+051d31m6.96719s end bearing=118.3°> >>> london <lon=-000d07m37.21800s lat=+051d31m6.96720s alt=0.0> -
+ +

Support this project

+

Liberapay receiving +Paypal me +Bitcoin

@@ -205,5 +228,5 @@ diff --git a/search/search_index.json b/search/search_index.json index 0be8a62..8316eb6 100755 --- a/search/search_index.json +++ b/search/search_index.json @@ -1 +1 @@ -{"config":{"indexing":"full","lang":["en"],"min_search_length":3,"prebuild_index":false,"separator":"[\\s\\-]+"},"docs":[{"location":"","text":"Python epsglide package This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection. EPSG dataset requests and projection >>> import math, epsglide >>> crs = epsglide.ProjectedCoordRefSystem(26730) >>> crs >>> point = epsglide.Geodesic(math.degrees(crs.lambda0), math.degrees(crs.phi0)) >>> crs(point) >>> crs(crs(point)) Great circle computation >>> wgs84 = epsglide.dataset.Ellipsoid(7030) >>> dublin = epsglide.Geodesic(-6.272877, 53.344606, 105.) >>> london = epsglide.Geodesic(-0.127005, 51.518602, 0.) >>> dist = wgs84.distance(dublin, london) >>> dist <464.572km initial bearing=113.5\u00b0 final bearing118.3\u00b0> >>> wgs84.destination(dublin, dist) >>> london ","title":"Home"},{"location":"#python-epsglide-package","text":"This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection.","title":"Python epsglide package"},{"location":"#epsg-dataset-requests-and-projection","text":">>> import math, epsglide >>> crs = epsglide.ProjectedCoordRefSystem(26730) >>> crs >>> point = epsglide.Geodesic(math.degrees(crs.lambda0), math.degrees(crs.phi0)) >>> crs(point) >>> crs(crs(point)) ","title":"EPSG dataset requests and projection"},{"location":"#great-circle-computation","text":">>> wgs84 = epsglide.dataset.Ellipsoid(7030) >>> dublin = epsglide.Geodesic(-6.272877, 53.344606, 105.) >>> london = epsglide.Geodesic(-0.127005, 51.518602, 0.) >>> dist = wgs84.distance(dublin, london) >>> dist <464.572km initial bearing=113.5\u00b0 final bearing118.3\u00b0> >>> wgs84.destination(dublin, dist) >>> london ","title":"Great circle computation"},{"location":"epsglide/","text":"epsglide This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection. ProjectedCoordRefSystem Objects class ProjectedCoordRefSystem(dataset.EpsgElement) Coordinate reference system object allowing projection of geodetic coordinates to flat map (geographic coordinates). >>> import epsglide >>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> london = epsglide.Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> osgb36(london) >>> osgb36.Projection {'Code': 19916, 'Name': 'British National Grid', 'href': 'https://apps.epsg.org/api/v1/Conversion/19916'} Attributes : Datum dataset.GeodeticCoordRefSystem - geodetic reference system. Conversion dataset.Conversion - projection method and parameters. CoordOperationMethod dataset.CoordOperationMethod - projection description. CoordSystem dataset.CoordSystem - 2D coordinate system and units. parameters list - list of dataset.CoordOperationParameter .","title":"EPSGlide"},{"location":"epsglide/#epsglide","text":"This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection.","title":"epsglide"},{"location":"epsglide/#projectedcoordrefsystem-objects","text":"class ProjectedCoordRefSystem(dataset.EpsgElement) Coordinate reference system object allowing projection of geodetic coordinates to flat map (geographic coordinates). >>> import epsglide >>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> london = epsglide.Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> osgb36(london) >>> osgb36.Projection {'Code': 19916, 'Name': 'British National Grid', 'href': 'https://apps.epsg.org/api/v1/Conversion/19916'} Attributes : Datum dataset.GeodeticCoordRefSystem - geodetic reference system. Conversion dataset.Conversion - projection method and parameters. CoordOperationMethod dataset.CoordOperationMethod - projection description. CoordSystem dataset.CoordSystem - 2D coordinate system and units. parameters list - list of dataset.CoordOperationParameter .","title":"ProjectedCoordRefSystem Objects"},{"location":"geodesy/","text":"epsglide.geodesy Module for handling geodetic coordinates and their representations. This module provides functionality for working with geodetic coordinates, allowing for different representations and initialization methods. Supported representations: Maidenhead Geohash Georef GARS Even if angular value are stored in radians, initialisation and representation are done using degrees. Geodetic class can be imported from geodesy package module: >>> from epsglide.geodesy import Geodetic >>> dublin = Geodetic(-6.272877, 53.344606, 105.) # use degrees >>> london = Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> dublin # show degrees in dms format >>> london # show degrees in dms format >>> london.longitude # value is stored in radians -0.002216655416495398 Geodetic Objects class Geodetic(ctypes.Structure) ctypes structure for geodetic coordinates. This class also provides various standart initialization from various representation such as maidenhead , georef , geohash . The associated GARS area (5minx5min tile) can also be provided. >>> Geodetic.from_maidenhead('IO91wm44sl21gl14kb51om') # london >>> epsglide.Geodetic.from_georef('MKQG52883162') # london >>> Geodeis.from_geohash('gcpvj4et8e6pwdj0ft1k', center=True) # london >>> london.gars() '360MV46' Attributes : longitude float - longitude value of geodetic coordinates in radians. latitude float - latitude value of geodetic coordinates in radians. altitude float - elevation of the geodetic coordinates in meters. maidenhead def maidenhead(level: int = 4) -> str Convert coordinates to maidenhead representation. Precision can be set using level parameter. >>> dublin.maidenhead() 'IO63ui72gq' >>> dublin.maidenhead(level=6) 'IO63ui72gq19dh' Arguments : level int - precision level of maidenhead. Returns : str - Maidenhead string. from_maidenhead @staticmethod def from_maidenhead(maidenhead: str) Return Geodetic object from maidenhead string. Arguments : maidenhead str - maidenhead representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> Geodetic.from_maidenhead('IO63ui72gq').precision (0.00015624999999999998, 0.00015624999999999998) >>> Geodetic.from_maidenhead('IO63ui72gq19dh').precision (6.510416666666665e-07, 6.510416666666665e-07) georef def georef(digit: int = 8) -> str Convert coordinates to georef. Best precision can be set with a maximul of 8 digit (default). With this level, the precision is about 8.3e-05 degrees in longitude and latitude. >>> dublin.georef() 'MKJJ43322037' >>> dublin.georef(digit=6) 'MKJJ433203' Arguments : digit int - digit number of georef (can be 4, 6 or 8). Returns : str - georef representation. from_georef @staticmethod def from_georef(georef: str) Return Geodetic object from georef. >>> Geodetic.from_georef('MKJJ433220') >>> Geodetic.from_georef('MKJJ43322037') Arguments : georef str - georef representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_georef('MKJJ433220').precision (0.0008333333333333333, 0.0008333333333333333) >>> Geodetic.from_georef('MKJJ43322037').precision (8.333333333333333e-05, 8.333333333333333e-05) gars def gars() -> str Get the associated GARS Area (5minx5min tile). >>> dublin.gars() '348MY16' from_gars @staticmethod def from_gars(gars: str, anchor: str = \"\") Return Geodetic object from gars. Optional anchor value to define where to handle 5minx5min tile. >>> Geodetic.from_gars('348MY16', anchor=\"nw\") >>> epsg.Geodetic.from_gars('348MY16') Arguments : gars str - gars representation. anchor str - tile anchor using n , e , s or w . Returns : epsglide.Geodetic - geodetic coordinates. Global precision of centered GARS coordinates is about 0.0833 degrees in longitude ad latitude. geohash def geohash(digit: int = 10, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\") -> str Convert coordinates to geohash. Precision can be set using digit parameter. >>> london.geohash() 'gcpvj4et8e' Arguments : digit int - digit number of geohash [default: 10]. base str - a 32-sized string of unique caracter. Same base should be used to decode correctly the geohash. Returns : str - geohash representation. from_geohash @staticmethod def from_geohash(geohash: str, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\", center: bool = True) Return Geodetic object from geohash. >>> Geodetic.from_geohash('gcpvj4et8e') Arguments : base str - a 32-sized string of unique caracter used to encode the geodetic coordinates. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_geohash('gcpvj4et8e').precision (2.682209014892578e-06, 1.341104507446289e-06) url_load_location def url_load_location(url, **kwargs) Return a static map image data from map provider. >>> # below a mapbox-static-map url centered on [lon, lat] with a red >>> # pin, width, height and zoom to be specified on call >>> url = \"https://api.mapbox.com/styles/v1/mapbox/outdoors-v11/static\" ... \"/pin-s+f74e4e(%(lon)f,%(lat)f)/%(lon)f,%(lat)f,%(zoom)d,0\" ... \"/%(width)dx%(height)d?access_token=%(token)s\" >>> data = dublin.url_load_location( ... url, zoom=15, width=600, height=400, token=\"xx-xxxxxx-xx\" ... ) >>> # see `epsg.geodesy.Geodetic.dump_location` >>> with io.open(\"dump.png\", \"wb\") as f: ... f.write(data) Arguments : url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude in the proper unit according to map provider. **kwargs dict - key-value pairs to match entries in url according to python string formatting. Returns : Image data as bytes (py3) or str (py2). dump_location def dump_location(name, url, **kwargs) Dump a static map image from map provider into filesystem. Arguments : name str - a valid filepath. url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude found in GPS data. **kwargs dict - key-value pairs to match entries in url according to python string formatting.","title":"Geodesy"},{"location":"geodesy/#epsglidegeodesy","text":"Module for handling geodetic coordinates and their representations. This module provides functionality for working with geodetic coordinates, allowing for different representations and initialization methods. Supported representations: Maidenhead Geohash Georef GARS Even if angular value are stored in radians, initialisation and representation are done using degrees. Geodetic class can be imported from geodesy package module: >>> from epsglide.geodesy import Geodetic >>> dublin = Geodetic(-6.272877, 53.344606, 105.) # use degrees >>> london = Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> dublin # show degrees in dms format >>> london # show degrees in dms format >>> london.longitude # value is stored in radians -0.002216655416495398","title":"epsglide.geodesy"},{"location":"geodesy/#geodetic-objects","text":"class Geodetic(ctypes.Structure) ctypes structure for geodetic coordinates. This class also provides various standart initialization from various representation such as maidenhead , georef , geohash . The associated GARS area (5minx5min tile) can also be provided. >>> Geodetic.from_maidenhead('IO91wm44sl21gl14kb51om') # london >>> epsglide.Geodetic.from_georef('MKQG52883162') # london >>> Geodeis.from_geohash('gcpvj4et8e6pwdj0ft1k', center=True) # london >>> london.gars() '360MV46' Attributes : longitude float - longitude value of geodetic coordinates in radians. latitude float - latitude value of geodetic coordinates in radians. altitude float - elevation of the geodetic coordinates in meters.","title":"Geodetic Objects"},{"location":"geodesy/#maidenhead","text":"def maidenhead(level: int = 4) -> str Convert coordinates to maidenhead representation. Precision can be set using level parameter. >>> dublin.maidenhead() 'IO63ui72gq' >>> dublin.maidenhead(level=6) 'IO63ui72gq19dh' Arguments : level int - precision level of maidenhead. Returns : str - Maidenhead string.","title":"maidenhead"},{"location":"geodesy/#from_maidenhead","text":"@staticmethod def from_maidenhead(maidenhead: str) Return Geodetic object from maidenhead string. Arguments : maidenhead str - maidenhead representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> Geodetic.from_maidenhead('IO63ui72gq').precision (0.00015624999999999998, 0.00015624999999999998) >>> Geodetic.from_maidenhead('IO63ui72gq19dh').precision (6.510416666666665e-07, 6.510416666666665e-07)","title":"from_maidenhead"},{"location":"geodesy/#georef","text":"def georef(digit: int = 8) -> str Convert coordinates to georef. Best precision can be set with a maximul of 8 digit (default). With this level, the precision is about 8.3e-05 degrees in longitude and latitude. >>> dublin.georef() 'MKJJ43322037' >>> dublin.georef(digit=6) 'MKJJ433203' Arguments : digit int - digit number of georef (can be 4, 6 or 8). Returns : str - georef representation.","title":"georef"},{"location":"geodesy/#from_georef","text":"@staticmethod def from_georef(georef: str) Return Geodetic object from georef. >>> Geodetic.from_georef('MKJJ433220') >>> Geodetic.from_georef('MKJJ43322037') Arguments : georef str - georef representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_georef('MKJJ433220').precision (0.0008333333333333333, 0.0008333333333333333) >>> Geodetic.from_georef('MKJJ43322037').precision (8.333333333333333e-05, 8.333333333333333e-05)","title":"from_georef"},{"location":"geodesy/#gars","text":"def gars() -> str Get the associated GARS Area (5minx5min tile). >>> dublin.gars() '348MY16'","title":"gars"},{"location":"geodesy/#from_gars","text":"@staticmethod def from_gars(gars: str, anchor: str = \"\") Return Geodetic object from gars. Optional anchor value to define where to handle 5minx5min tile. >>> Geodetic.from_gars('348MY16', anchor=\"nw\") >>> epsg.Geodetic.from_gars('348MY16') Arguments : gars str - gars representation. anchor str - tile anchor using n , e , s or w . Returns : epsglide.Geodetic - geodetic coordinates. Global precision of centered GARS coordinates is about 0.0833 degrees in longitude ad latitude.","title":"from_gars"},{"location":"geodesy/#geohash","text":"def geohash(digit: int = 10, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\") -> str Convert coordinates to geohash. Precision can be set using digit parameter. >>> london.geohash() 'gcpvj4et8e' Arguments : digit int - digit number of geohash [default: 10]. base str - a 32-sized string of unique caracter. Same base should be used to decode correctly the geohash. Returns : str - geohash representation.","title":"geohash"},{"location":"geodesy/#from_geohash","text":"@staticmethod def from_geohash(geohash: str, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\", center: bool = True) Return Geodetic object from geohash. >>> Geodetic.from_geohash('gcpvj4et8e') Arguments : base str - a 32-sized string of unique caracter used to encode the geodetic coordinates. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_geohash('gcpvj4et8e').precision (2.682209014892578e-06, 1.341104507446289e-06)","title":"from_geohash"},{"location":"geodesy/#url_load_location","text":"def url_load_location(url, **kwargs) Return a static map image data from map provider. >>> # below a mapbox-static-map url centered on [lon, lat] with a red >>> # pin, width, height and zoom to be specified on call >>> url = \"https://api.mapbox.com/styles/v1/mapbox/outdoors-v11/static\" ... \"/pin-s+f74e4e(%(lon)f,%(lat)f)/%(lon)f,%(lat)f,%(zoom)d,0\" ... \"/%(width)dx%(height)d?access_token=%(token)s\" >>> data = dublin.url_load_location( ... url, zoom=15, width=600, height=400, token=\"xx-xxxxxx-xx\" ... ) >>> # see `epsg.geodesy.Geodetic.dump_location` >>> with io.open(\"dump.png\", \"wb\") as f: ... f.write(data) Arguments : url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude in the proper unit according to map provider. **kwargs dict - key-value pairs to match entries in url according to python string formatting. Returns : Image data as bytes (py3) or str (py2).","title":"url_load_location"},{"location":"geodesy/#dump_location","text":"def dump_location(name, url, **kwargs) Dump a static map image from map provider into filesystem. Arguments : name str - a valid filepath. url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude found in GPS data. **kwargs dict - key-value pairs to match entries in url according to python string formatting.","title":"dump_location"}]} \ No newline at end of file +{"config":{"indexing":"full","lang":["en"],"min_search_length":3,"prebuild_index":false,"separator":"[\\s\\-]+"},"docs":[{"location":"","text":"Python epsglide package This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projections. EPSG dataset requests and projection >>> import math, epsglide >>> crs = epsglide.ProjectedCoordRefSystem(26730) >>> crs >>> point = epsglide.Geodesic(math.degrees(crs.lambda0), math.degrees(crs.phi0)) >>> crs(point) >>> crs(crs(point)) EPSG dataset conversion >>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> lla = osgb36(epsglide.Geographic(400000, -100000, 0)) >>> osgb36.GeodeticCoordRefSystem.to_wgs84(lla) >>> lla Great circle computation >>> wgs84 = epsglide.dataset.Ellipsoid(7030) >>> dublin = epsglide.Geodesic(-6.272877, 53.344606, 105.) >>> london = epsglide.Geodesic(-0.127005, 51.518602, 0.) >>> dist = wgs84.distance(dublin, london) >>> dist <464.572km initial bearing=113.5\u00b0 final bearing118.3\u00b0> >>> wgs84.destination(dublin, dist) >>> london Support this project","title":"Home"},{"location":"#python-epsglide-package","text":"This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projections.","title":"Python epsglide package"},{"location":"#epsg-dataset-requests-and-projection","text":">>> import math, epsglide >>> crs = epsglide.ProjectedCoordRefSystem(26730) >>> crs >>> point = epsglide.Geodesic(math.degrees(crs.lambda0), math.degrees(crs.phi0)) >>> crs(point) >>> crs(crs(point)) ","title":"EPSG dataset requests and projection"},{"location":"#epsg-dataset-conversion","text":">>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> lla = osgb36(epsglide.Geographic(400000, -100000, 0)) >>> osgb36.GeodeticCoordRefSystem.to_wgs84(lla) >>> lla ","title":"EPSG dataset conversion"},{"location":"#great-circle-computation","text":">>> wgs84 = epsglide.dataset.Ellipsoid(7030) >>> dublin = epsglide.Geodesic(-6.272877, 53.344606, 105.) >>> london = epsglide.Geodesic(-0.127005, 51.518602, 0.) >>> dist = wgs84.distance(dublin, london) >>> dist <464.572km initial bearing=113.5\u00b0 final bearing118.3\u00b0> >>> wgs84.destination(dublin, dist) >>> london ","title":"Great circle computation"},{"location":"#support-this-project","text":"","title":"Support this project"},{"location":"dataset/","text":"epsglide.dataset EpsgElement Objects class EpsgElement(object) Represents an EPSG dataset element. Attributes : _struct_ ctypes.Structure - object representing the structure of the equivalant C element. Arguments : code int - the EPSG code of the element. name str - the name of the element. Raises : DatasetIdentificationError - if either EPSG code or name is not provided. NotImplementedError - if searching by keyword is attempted (not implemented yet). __repr__ def __repr__() Return a string representation of the EpsgElement object. Returns : str - a string representation of the object in the format . populate def populate() Populate the EPSG dataset element. This method is meant to be overridden by subclasses. to_target def to_target(value: Union[int, float]) -> float Convert a value to the target unit, if applicable, ie: the EpsgElement must contain a Unit class as attribute. Arguments : value int|float - the value to be converted. Returns : float|None - the converted value, or None if no conversion is possible. from_target def from_target(value: Union[int, float]) -> float Convert a value from the target unit, if applicable, ie: the EpsgElement must contain a Unit class as attribute. Arguments : value int|float - the value to be converted. Returns : float|None - the converted value, or None if no conversion is possible. Ellipsoid Objects class Ellipsoid(EpsgElement) Represents an ellipsoid model used in geodetic coordinate reference systems. Methods : populate - Populate the Ellipsoid object with necessary data, including parameters related to its shape and size. populate def populate() Populate the Ellipsoid object with necessary data. This method initializes the internal structure ( _struct_ ) of the Ellipsoid object with information about its semi-major axis, semi-minor axis, flattening, eccentricity, and other related parameters. The initialization process depends on whether the ellipsoid\u2019s inverse flattening is provided or calculated from its semi-major and semi-minor axes. GeodeticCoordRefSystem Objects class GeodeticCoordRefSystem(EpsgElement) Represents a geodetic coordinate reference system. Methods : populate - Populate the GeodeticCoordRefSystem object with necessary data, including datum and transformation parameters. populate def populate() Populate the GeodeticCoordRefSystem object with necessary data. This method initializes the internal structure ( _struct_ ) of the GeodeticCoordRefSystem object with information about the datum, ellipsoid, prime meridian, and transformation parameters. Raises : DatasetNotFound - If no transformation is found for the given coordinate reference system (CRS) code. DatumInitializationError - If an unmanageable transformation parameter is encountered during initialization.","title":"Dataset"},{"location":"dataset/#epsglidedataset","text":"","title":"epsglide.dataset"},{"location":"dataset/#epsgelement-objects","text":"class EpsgElement(object) Represents an EPSG dataset element. Attributes : _struct_ ctypes.Structure - object representing the structure of the equivalant C element. Arguments : code int - the EPSG code of the element. name str - the name of the element. Raises : DatasetIdentificationError - if either EPSG code or name is not provided. NotImplementedError - if searching by keyword is attempted (not implemented yet).","title":"EpsgElement Objects"},{"location":"dataset/#__repr__","text":"def __repr__() Return a string representation of the EpsgElement object. Returns : str - a string representation of the object in the format .","title":"__repr__"},{"location":"dataset/#populate","text":"def populate() Populate the EPSG dataset element. This method is meant to be overridden by subclasses.","title":"populate"},{"location":"dataset/#to_target","text":"def to_target(value: Union[int, float]) -> float Convert a value to the target unit, if applicable, ie: the EpsgElement must contain a Unit class as attribute. Arguments : value int|float - the value to be converted. Returns : float|None - the converted value, or None if no conversion is possible.","title":"to_target"},{"location":"dataset/#from_target","text":"def from_target(value: Union[int, float]) -> float Convert a value from the target unit, if applicable, ie: the EpsgElement must contain a Unit class as attribute. Arguments : value int|float - the value to be converted. Returns : float|None - the converted value, or None if no conversion is possible.","title":"from_target"},{"location":"dataset/#ellipsoid-objects","text":"class Ellipsoid(EpsgElement) Represents an ellipsoid model used in geodetic coordinate reference systems. Methods : populate - Populate the Ellipsoid object with necessary data, including parameters related to its shape and size.","title":"Ellipsoid Objects"},{"location":"dataset/#populate_1","text":"def populate() Populate the Ellipsoid object with necessary data. This method initializes the internal structure ( _struct_ ) of the Ellipsoid object with information about its semi-major axis, semi-minor axis, flattening, eccentricity, and other related parameters. The initialization process depends on whether the ellipsoid\u2019s inverse flattening is provided or calculated from its semi-major and semi-minor axes.","title":"populate"},{"location":"dataset/#geodeticcoordrefsystem-objects","text":"class GeodeticCoordRefSystem(EpsgElement) Represents a geodetic coordinate reference system. Methods : populate - Populate the GeodeticCoordRefSystem object with necessary data, including datum and transformation parameters.","title":"GeodeticCoordRefSystem Objects"},{"location":"dataset/#populate_2","text":"def populate() Populate the GeodeticCoordRefSystem object with necessary data. This method initializes the internal structure ( _struct_ ) of the GeodeticCoordRefSystem object with information about the datum, ellipsoid, prime meridian, and transformation parameters. Raises : DatasetNotFound - If no transformation is found for the given coordinate reference system (CRS) code. DatumInitializationError - If an unmanageable transformation parameter is encountered during initialization.","title":"populate"},{"location":"epsglide/","text":"epsglide This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection. ProjectedCoordRefSystem Objects class ProjectedCoordRefSystem(dataset.EpsgElement) Coordinate reference system object allowing projection of geodetic coordinates to flat map (geographic coordinates). >>> import epsglide >>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> london = epsglide.Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> osgb36(london) >>> osgb36.Projection {'Code': 19916, 'Name': 'British National Grid', 'href': 'https://apps.epsg.org/api/v1/Conversion/19916'} Attributes : GeodeticCoordRefSystem dataset.GeodeticCoordRefSystem - geodetic reference system. Conversion dataset.Conversion - projection method and parameters. CoordOperationMethod dataset.CoordOperationMethod - projection description. CoordSystem dataset.CoordSystem - 2D coordinate system and units. parameters list - list of dataset.CoordOperationParameter . __call__ def __call__( element: typing.Union[Geodetic, Geographic] ) -> typing.Union[Geodetic, Geographic] transform def transform(element: typing.Union[Geodetic, Geographic], dest_crs) -> Geographic","title":"EPSGlide"},{"location":"epsglide/#epsglide","text":"This package aims to perform simple requests to EPSG GeoRepository API and provides associated geodesic computation and map projection.","title":"epsglide"},{"location":"epsglide/#projectedcoordrefsystem-objects","text":"class ProjectedCoordRefSystem(dataset.EpsgElement) Coordinate reference system object allowing projection of geodetic coordinates to flat map (geographic coordinates). >>> import epsglide >>> osgb36 = epsglide.ProjectedCoordRefSystem(27700) >>> london = epsglide.Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> osgb36(london) >>> osgb36.Projection {'Code': 19916, 'Name': 'British National Grid', 'href': 'https://apps.epsg.org/api/v1/Conversion/19916'} Attributes : GeodeticCoordRefSystem dataset.GeodeticCoordRefSystem - geodetic reference system. Conversion dataset.Conversion - projection method and parameters. CoordOperationMethod dataset.CoordOperationMethod - projection description. CoordSystem dataset.CoordSystem - 2D coordinate system and units. parameters list - list of dataset.CoordOperationParameter .","title":"ProjectedCoordRefSystem Objects"},{"location":"epsglide/#__call__","text":"def __call__( element: typing.Union[Geodetic, Geographic] ) -> typing.Union[Geodetic, Geographic]","title":"__call__"},{"location":"epsglide/#transform","text":"def transform(element: typing.Union[Geodetic, Geographic], dest_crs) -> Geographic","title":"transform"},{"location":"geodesy/","text":"epsglide.geodesy Module for handling geodetic coordinates and their representations. This module provides functionality for working with geodetic coordinates, allowing for different representations and initialization methods. Supported representations: Maidenhead Geohash Georef GARS Even if angular value are stored in radians, initialisation and representation are done using degrees. Geodetic class can be imported from geodesy package module: >>> from epsglide.geodesy import Geodetic >>> dublin = Geodetic(-6.272877, 53.344606, 105.) # use degrees >>> london = Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> dublin # show degrees in dms format >>> london # show degrees in dms format >>> london.longitude # value is stored in radians -0.002216655416495398 Geodetic Objects class Geodetic(ctypes.Structure) ctypes structure for geodetic coordinates. This class also provides various standart initialization from various representation such as maidenhead , georef , geohash . The associated GARS area (5minx5min tile) can also be provided. >>> Geodetic.from_maidenhead('IO91wm44sl21gl14kb51om') # london >>> epsglide.Geodetic.from_georef('MKQG52883162') # london >>> Geodeis.from_geohash('gcpvj4et8e6pwdj0ft1k', center=True) # london >>> london.gars() '360MV46' Attributes : longitude float - longitude value of geodetic coordinates in radians. latitude float - latitude value of geodetic coordinates in radians. altitude float - elevation of the geodetic coordinates in meters. maidenhead def maidenhead(level: int = 4) -> str Convert coordinates to maidenhead representation. Precision can be set using level parameter. >>> dublin.maidenhead() 'IO63ui72gq' >>> dublin.maidenhead(level=6) 'IO63ui72gq19dh' Arguments : level int - precision level of maidenhead. Returns : str - Maidenhead string. from_maidenhead @staticmethod def from_maidenhead(maidenhead: str) Return Geodetic object from maidenhead string. Arguments : maidenhead str - maidenhead representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> Geodetic.from_maidenhead('IO63ui72gq').precision (0.00015624999999999998, 0.00015624999999999998) >>> Geodetic.from_maidenhead('IO63ui72gq19dh').precision (6.510416666666665e-07, 6.510416666666665e-07) georef def georef(digit: int = 8) -> str Convert coordinates to georef. Best precision can be set with a maximul of 8 digit (default). With this level, the precision is about 8.3e-05 degrees in longitude and latitude. >>> dublin.georef() 'MKJJ43322037' >>> dublin.georef(digit=6) 'MKJJ433203' Arguments : digit int - digit number of georef (can be 4, 6 or 8). Returns : str - georef representation. from_georef @staticmethod def from_georef(georef: str) Return Geodetic object from georef. >>> Geodetic.from_georef('MKJJ433220') >>> Geodetic.from_georef('MKJJ43322037') Arguments : georef str - georef representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_georef('MKJJ433220').precision (0.0008333333333333333, 0.0008333333333333333) >>> Geodetic.from_georef('MKJJ43322037').precision (8.333333333333333e-05, 8.333333333333333e-05) gars def gars() -> str Get the associated GARS Area (5minx5min tile). >>> dublin.gars() '348MY16' from_gars @staticmethod def from_gars(gars: str, anchor: str = \"\") Return Geodetic object from gars. Optional anchor value to define where to handle 5minx5min tile. >>> Geodetic.from_gars('348MY16', anchor=\"nw\") >>> epsg.Geodetic.from_gars('348MY16') Arguments : gars str - gars representation. anchor str - tile anchor using n , e , s or w . Returns : epsglide.Geodetic - geodetic coordinates. Global precision of centered GARS coordinates is about 0.0833 degrees in longitude ad latitude. geohash def geohash(digit: int = 10, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\") -> str Convert coordinates to geohash. Precision can be set using digit parameter. >>> london.geohash() 'gcpvj4et8e' Arguments : digit int - digit number of geohash [default: 10]. base str - a 32-sized string of unique caracter. Same base should be used to decode correctly the geohash. Returns : str - geohash representation. from_geohash @staticmethod def from_geohash(geohash: str, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\", center: bool = True) Return Geodetic object from geohash. >>> Geodetic.from_geohash('gcpvj4et8e') Arguments : base str - a 32-sized string of unique caracter used to encode the geodetic coordinates. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_geohash('gcpvj4et8e').precision (2.682209014892578e-06, 1.341104507446289e-06) url_load_location def url_load_location(url, **kwargs) Return a static map image data from map provider. >>> # below a mapbox-static-map url centered on [lon, lat] with a red >>> # pin, width, height and zoom to be specified on call >>> url = \"https://api.mapbox.com/styles/v1/mapbox/outdoors-v11/static\" ... \"/pin-s+f74e4e(%(lon)f,%(lat)f)/%(lon)f,%(lat)f,%(zoom)d,0\" ... \"/%(width)dx%(height)d?access_token=%(token)s\" >>> data = dublin.url_load_location( ... url, zoom=15, width=600, height=400, token=\"xx-xxxxxx-xx\" ... ) >>> # see `epsg.geodesy.Geodetic.dump_location` >>> with io.open(\"dump.png\", \"wb\") as f: ... f.write(data) Arguments : url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude in the proper unit according to map provider. **kwargs dict - key-value pairs to match entries in url according to python string formatting. Returns : Image data as bytes (py3) or str (py2). dump_location def dump_location(name, url, **kwargs) Dump a static map image from map provider into filesystem. Arguments : name str - a valid filepath. url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude found in GPS data. **kwargs dict - key-value pairs to match entries in url according to python string formatting.","title":"Geodesy"},{"location":"geodesy/#epsglidegeodesy","text":"Module for handling geodetic coordinates and their representations. This module provides functionality for working with geodetic coordinates, allowing for different representations and initialization methods. Supported representations: Maidenhead Geohash Georef GARS Even if angular value are stored in radians, initialisation and representation are done using degrees. Geodetic class can be imported from geodesy package module: >>> from epsglide.geodesy import Geodetic >>> dublin = Geodetic(-6.272877, 53.344606, 105.) # use degrees >>> london = Geodetic(-0.127005, 51.518602, 0.) # use degrees >>> dublin # show degrees in dms format >>> london # show degrees in dms format >>> london.longitude # value is stored in radians -0.002216655416495398","title":"epsglide.geodesy"},{"location":"geodesy/#geodetic-objects","text":"class Geodetic(ctypes.Structure) ctypes structure for geodetic coordinates. This class also provides various standart initialization from various representation such as maidenhead , georef , geohash . The associated GARS area (5minx5min tile) can also be provided. >>> Geodetic.from_maidenhead('IO91wm44sl21gl14kb51om') # london >>> epsglide.Geodetic.from_georef('MKQG52883162') # london >>> Geodeis.from_geohash('gcpvj4et8e6pwdj0ft1k', center=True) # london >>> london.gars() '360MV46' Attributes : longitude float - longitude value of geodetic coordinates in radians. latitude float - latitude value of geodetic coordinates in radians. altitude float - elevation of the geodetic coordinates in meters.","title":"Geodetic Objects"},{"location":"geodesy/#maidenhead","text":"def maidenhead(level: int = 4) -> str Convert coordinates to maidenhead representation. Precision can be set using level parameter. >>> dublin.maidenhead() 'IO63ui72gq' >>> dublin.maidenhead(level=6) 'IO63ui72gq19dh' Arguments : level int - precision level of maidenhead. Returns : str - Maidenhead string.","title":"maidenhead"},{"location":"geodesy/#from_maidenhead","text":"@staticmethod def from_maidenhead(maidenhead: str) Return Geodetic object from maidenhead string. Arguments : maidenhead str - maidenhead representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> Geodetic.from_maidenhead('IO63ui72gq').precision (0.00015624999999999998, 0.00015624999999999998) >>> Geodetic.from_maidenhead('IO63ui72gq19dh').precision (6.510416666666665e-07, 6.510416666666665e-07)","title":"from_maidenhead"},{"location":"geodesy/#georef","text":"def georef(digit: int = 8) -> str Convert coordinates to georef. Best precision can be set with a maximul of 8 digit (default). With this level, the precision is about 8.3e-05 degrees in longitude and latitude. >>> dublin.georef() 'MKJJ43322037' >>> dublin.georef(digit=6) 'MKJJ433203' Arguments : digit int - digit number of georef (can be 4, 6 or 8). Returns : str - georef representation.","title":"georef"},{"location":"geodesy/#from_georef","text":"@staticmethod def from_georef(georef: str) Return Geodetic object from georef. >>> Geodetic.from_georef('MKJJ433220') >>> Geodetic.from_georef('MKJJ43322037') Arguments : georef str - georef representation. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_georef('MKJJ433220').precision (0.0008333333333333333, 0.0008333333333333333) >>> Geodetic.from_georef('MKJJ43322037').precision (8.333333333333333e-05, 8.333333333333333e-05)","title":"from_georef"},{"location":"geodesy/#gars","text":"def gars() -> str Get the associated GARS Area (5minx5min tile). >>> dublin.gars() '348MY16'","title":"gars"},{"location":"geodesy/#from_gars","text":"@staticmethod def from_gars(gars: str, anchor: str = \"\") Return Geodetic object from gars. Optional anchor value to define where to handle 5minx5min tile. >>> Geodetic.from_gars('348MY16', anchor=\"nw\") >>> epsg.Geodetic.from_gars('348MY16') Arguments : gars str - gars representation. anchor str - tile anchor using n , e , s or w . Returns : epsglide.Geodetic - geodetic coordinates. Global precision of centered GARS coordinates is about 0.0833 degrees in longitude ad latitude.","title":"from_gars"},{"location":"geodesy/#geohash","text":"def geohash(digit: int = 10, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\") -> str Convert coordinates to geohash. Precision can be set using digit parameter. >>> london.geohash() 'gcpvj4et8e' Arguments : digit int - digit number of geohash [default: 10]. base str - a 32-sized string of unique caracter. Same base should be used to decode correctly the geohash. Returns : str - geohash representation.","title":"geohash"},{"location":"geodesy/#from_geohash","text":"@staticmethod def from_geohash(geohash: str, base: str = \"0123456789bcdefghjkmnpqrstuvwxyz\", center: bool = True) Return Geodetic object from geohash. >>> Geodetic.from_geohash('gcpvj4et8e') Arguments : base str - a 32-sized string of unique caracter used to encode the geodetic coordinates. Returns : epsglide.Geodetic - geodetic coordinates. A precision tuple (longitude, latitude) in degrees is added as class attribute. >>> epsglide.Geodetic.from_geohash('gcpvj4et8e').precision (2.682209014892578e-06, 1.341104507446289e-06)","title":"from_geohash"},{"location":"geodesy/#url_load_location","text":"def url_load_location(url, **kwargs) Return a static map image data from map provider. >>> # below a mapbox-static-map url centered on [lon, lat] with a red >>> # pin, width, height and zoom to be specified on call >>> url = \"https://api.mapbox.com/styles/v1/mapbox/outdoors-v11/static\" ... \"/pin-s+f74e4e(%(lon)f,%(lat)f)/%(lon)f,%(lat)f,%(zoom)d,0\" ... \"/%(width)dx%(height)d?access_token=%(token)s\" >>> data = dublin.url_load_location( ... url, zoom=15, width=600, height=400, token=\"xx-xxxxxx-xx\" ... ) >>> # see `epsg.geodesy.Geodetic.dump_location` >>> with io.open(\"dump.png\", \"wb\") as f: ... f.write(data) Arguments : url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude in the proper unit according to map provider. **kwargs dict - key-value pairs to match entries in url according to python string formatting. Returns : Image data as bytes (py3) or str (py2).","title":"url_load_location"},{"location":"geodesy/#dump_location","text":"def dump_location(name, url, **kwargs) Dump a static map image from map provider into filesystem. Arguments : name str - a valid filepath. url str - map provider url containing %(lon)f and %(lat)f format expression to be replaced by longitude and latitude found in GPS data. **kwargs dict - key-value pairs to match entries in url according to python string formatting.","title":"dump_location"}]} \ No newline at end of file diff --git a/sitemap.xml.gz b/sitemap.xml.gz index 6236dfc..c53d30d 100755 Binary files a/sitemap.xml.gz and b/sitemap.xml.gz differ