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.15.0.tar.gz (65.5 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.15.0-py3-none-any.whl (79.6 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: meteora-0.15.0.tar.gz
  • Upload date:
  • Size: 65.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","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.15.0.tar.gz
Algorithm Hash digest
SHA256 32b92cf3ae7b628221f531cc0a996dd25504c6a1e5b85469a8478f7948f03bfa
MD5 b2b4632c1bbc0d221de7b416fbb2eba5
BLAKE2b-256 67378b14164509eca79aee8394e4a3311d6082ee55ffb2be9961851b46ed084a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: meteora-0.15.0-py3-none-any.whl
  • Upload date:
  • Size: 79.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.16 {"installer":{"name":"uv","version":"0.11.16","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.15.0-py3-none-any.whl
Algorithm Hash digest
SHA256 358f5e0dcad9fa7c4b79748004e55a384a30802207ca8d5d1b16bfb3e8cc36e0
MD5 e73bfecf959ae2be9353a6c67f35016a
BLAKE2b-256 b6c95443437a303ecbc304dd80fb8ba7b5ab64083b78eb2e8dff3b5b8db62b97

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