weather.locations.coordinates

weather.locations.coordinates(locations)

Extract (latitude, longitude) pairs in order.

Parameters

Name Type Description Default
locations Sequence[WeatherLocation] The locations to read. required

Returns

Name Type Description
List[Tuple[float, float]] List[Tuple[float, float]]: One (lat, lon) pair per location, in the
List[Tuple[float, float]] same order.

Examples

from spotforecast2_safe.weather.locations import (
    coordinates,
    default_german_locations,
)

print(coordinates(default_german_locations())[:2])
[(52.52, 13.405), (53.5511, 9.9937)]