Skip to main content

Location Oriented Observed Meteorology (LOOM)

Project description

metloom

https://img.shields.io/pypi/v/metloom.svg Testing Status Documentation Status Code Coverage

Location Oriented Observed Meteorology

metloom is a python library created with the goal of consistent, simple sampling of meteorology and snow related point measurments from a variety of datasources across the Western US.

Warning - This software is provided as is (see the license), so use at your own risk. This is an opensource package with the goal of making data wrangling easier. We make no guarantees about the quality or accuracy of the data and any interpretation of the meaning of the data is up to you.

  • Free software: BSD license

Features

  • Sampling of daily, hourly, and snow course data

  • Searching for stations from a datasource within a shapefile

  • Current data sources:

Requirements

python >= 3.7

Install

python3 -m pip install metloom

Local install for dev

The recommendation is to use virtualenv, but other local python environment isolation tools will work (pipenv, conda) .. code-block:: bash

python3 -m pip install –upgrade pip python3 -m pip install -r requirements_dev python3 -m pip install .

Testing

pytest

If contributing to the codebase, code coverage should not decrease from the contributions. Make sure to check code coverage before opening a pull request.

pytest --cov=metloom

Documentation

readthedocs coming soon

https://metloom.readthedocs.io.

Usage Notes

See usage documentation https://metloom.readthedocs.io/en/latest/usage.html

NOTES: PointData methods that get point data return a GeoDataFrame indexed on both datetime and station code. To reset the index simply run df.reset_index(inplace=True)

Extending classes for your own variables

Not all of the available variables for each datasource are implemented within this package. It is easy to extend the classes to add more variables

from datetime import datetime
from metloom.variables import CDECStationVariables:
from metloom.pointdata import CDECPointData


class MyVariables(CDEcStationVariables):
    DEWPT = SensorDescription("36", "Dew Point", "TEMPERATURE, DEW POINT")


class MyCDECPointData(CDECPointData):
    ALLOWED_VARIABLES = MyVariables


MyCDECPointData("TNY", "Tenaya Lake").get_daily_data(
    datetime(2020, 1, 3), datetime(2020, 1, 7), [MyVariables.DEWPT]
)

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.1.0 (2021-09-17)

  • First release on PyPI.

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

metloom-0.1.2.tar.gz (28.3 kB view details)

Uploaded Source

Built Distribution

metloom-0.1.2-py2.py3-none-any.whl (19.6 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file metloom-0.1.2.tar.gz.

File metadata

  • Download URL: metloom-0.1.2.tar.gz
  • Upload date:
  • Size: 28.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for metloom-0.1.2.tar.gz
Algorithm Hash digest
SHA256 2c98f1ebfde830069bd06e61416a3b0712f3e6e53a85e4d0aefc37647b909b17
MD5 fb65c12d998ecad17c98f60f7221efc9
BLAKE2b-256 79ba6a212b13b1d5a49279ef2550b5f0a70385461a326e7ec21eaae7ed23544b

See more details on using hashes here.

File details

Details for the file metloom-0.1.2-py2.py3-none-any.whl.

File metadata

  • Download URL: metloom-0.1.2-py2.py3-none-any.whl
  • Upload date:
  • Size: 19.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for metloom-0.1.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 5be2e746c632b2b238713904ad0dc4c84ad289f28436b776568324cda3add735
MD5 6eedac3aa3b3c566cb2769d0738a056a
BLAKE2b-256 c81aa065ac1d9dc45aca033c544e5d02815de725f28d5b0ffbca67e52501f2d0

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page