Skip to main content

Pythonic interface to access data from meteorological stations

Project description

PyPI version fury.io Conda Version Documentation Status tests pre-commit.ci status codecov GitHub license Binder

Meteora

Pythonic interface to access observations from meteorological stations. Key features:

Overview

Meteora provides a set of provider-specific clients to get observations from meteorological stations. For instance, it can be used to stream data from the Global Historical Climatology Network hourly (GHCNh) into a pandas data frame:

from meteora.clients import GHCNHourlyClient

region = "Canton de Vaud, Switzerland"
variables = ["temperature", "precipitation", "wind_speed"]
start = "12-11-2021"
end = "12-12-2021"

client = GHCNHourlyClient(region)
ts_df = client.get_ts_df(variables, start, end)
ts_df.head()
[########################################] | 100% Completed | 925.68 ms
station_id time temperature precipitation wind_speed
SZI0000LSMP 2021-12-11 00:20:00 2.0 NaN 4.6
2021-12-11 00:50:00 2.0 NaN 5.1
2021-12-11 01:20:00 2.0 NaN 4.6
2021-12-11 01:50:00 2.0 NaN 3.6
2021-12-11 02:20:00 2.0 NaN 4.6

We can also get the station locations using the stations_gdf property:

import contextily as cx

ax = client.stations_gdf.assign(
    T_mean=ts_df.groupby("station_id")["temperature"].mean()
).plot(
    "T_mean",
    cmap="winter",
    legend=True,
    legend_kwds={"label": "$\overline{T} \; [\circ C]$", "shrink": 0.5},
)
cx.add_basemap(ax, crs=client.stations_gdf.crs, attribution=False)

vaud-stations-t-mean

(C) OpenStreetMap contributors, Tiles style by Humanitarian OpenStreetMap Team hosted by OpenStreetMap France

See the user guide for more details about the features of Meteora as well as the list of supported providers.

Installation

The easiest way to install Meteora is with conda/mamba:

conda install -c conda-forge meteora

Alternatively, if geopandas dependencies are installed correctly, you can install Meteora using pip:

pip install meteora

See also

Meteora intends to provide a unified way to access data from meteorological stations from multiple providers. The following libraries provide access to data from a specific provider:

Eventually these packages will be fully integrated into Meteora.

Acknowledgements

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

meteora-0.16.0.tar.gz (72.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

meteora-0.16.0-py3-none-any.whl (86.9 kB view details)

Uploaded Python 3

File details

Details for the file meteora-0.16.0.tar.gz.

File metadata

  • Download URL: meteora-0.16.0.tar.gz
  • Upload date:
  • Size: 72.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for meteora-0.16.0.tar.gz
Algorithm Hash digest
SHA256 e8c2a81f95db4cc9b4a45267ddbbe11f538b095eb009308c834099f4bc537eb0
MD5 e2807de7f298f593a4bebc7a17280423
BLAKE2b-256 72d9ed9896cc8f9efa42ba59236b6995204cb6acbe614c7516d5ab0f6bb33a19

See more details on using hashes here.

File details

Details for the file meteora-0.16.0-py3-none-any.whl.

File metadata

  • Download URL: meteora-0.16.0-py3-none-any.whl
  • Upload date:
  • Size: 86.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for meteora-0.16.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e42cdf65a8ad97a4f6d4107951ed9816ae23a4ddc02bc8525d0dbbeb478453f2
MD5 219ad9b4ae1aca5571b9ded30288dcb7
BLAKE2b-256 2eb31c3286d0d8882966c58561beb6d2e82c1c33a5eeddfdd15a4723a23581b4

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