mappymatch.utils.geo

mappymatch.utils.geo#

Functions

coord_to_coord_dist(a, b)

Compute the distance between two coordinates.

latlon_to_xy(lat, lon)

Tramsform lat,lon coordinates to x and y.

xy_to_latlon(x, y)

Tramsform x,y coordinates to lat and lon

mappymatch.utils.geo.xy_to_latlon(x, y)[source]#

Tramsform x,y coordinates to lat and lon

Return type:

Tuple[float, float]

Parameters:
  • x (float)

  • y (float)

Args:

x: X. y: Y.

Returns:

Transformed lat and lon as lat, lon.

mappymatch.utils.geo.latlon_to_xy(lat, lon)[source]#

Tramsform lat,lon coordinates to x and y.

Return type:

Tuple[float, float]

Parameters:
  • lat (float)

  • lon (float)

Args:

lat: The latitude. lon: The longitude.

Returns:

Transformed x and y as x, y.

mappymatch.utils.geo.coord_to_coord_dist(a, b)[source]#

Compute the distance between two coordinates.

Return type:

float

Parameters:
Args:

a: The first coordinate b: The second coordinate

Returns:

The distance in meters