skytracker.utils.geographic#

Geographic utilities

Functions

country_code_validator([code])

Validate whether a string is a valid ISO 3166-1 A-2 country code

distance_between_points(lat1, lon1, lat2, lon2)

Calculate the distance between two points described by coordinates

is_country_code(text)

Check whether a code is a valid ISO 3166-1 A-2 country code

normalize_longitude_bbox(lon_min, lon_max)

Get bounding boxes in the range [-180, 180] that are equivalent to the specified range

shift_longitude_into_range(lon, lon_min, lon_max)

Shift a longitude from the range [-180, 180] into the specified range [lon_min, lon_max]