Skip to main content

Hestia's utils library

Project description

Hestia Utils

Install

  1. Install the module:
pip install hestia_earth.utils

Usage

  1. To download a file from the Hestia API:
from hestia_earth.schema import SchemaType
from hestia_earth.utils.api import download_hestia

cycle = download_hestia('cycleId', SchemaType.CYCLE)
sandContent = download_hestia('sandContent', SchemaType.TERM)
  1. To search for a specific Node on Hestia:
from hestia_earth.schema import SchemaType
from hestia_earth.utils.api import find_node_exact

source = find_node_exact(SchemaType.SOURCE, {'bibliography.title': 'My Bibliography'})
  1. To get a lookup table from local file system:
from hestia_earth.schema import SchemaType
from hestia_earth.utils.lookup import load_lookup

df = load_lookup('path/to/my/lookup.csv')
  1. To get a lookup table from Hestia:
from hestia_earth.schema import SchemaType
from hestia_earth.utils.lookup import download_lookup

df = download_lookup('crop.csv')

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hestia_earth.utils-0.1.4.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

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

hestia_earth.utils-0.1.4-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file hestia_earth.utils-0.1.4.tar.gz.

File metadata

  • Download URL: hestia_earth.utils-0.1.4.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.12

File hashes

Hashes for hestia_earth.utils-0.1.4.tar.gz
Algorithm Hash digest
SHA256 ef674bde1f5ac315832c842ed62e4ac9996a688369054edcfad0d81034461784
MD5 3a5fb95f116dce844d0fd9f4ea023af4
BLAKE2b-256 b6f98e40934ec2211eb2a681367a41824eb6f1960cf649157ac56ae5cb9ff855

See more details on using hashes here.

File details

Details for the file hestia_earth.utils-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: hestia_earth.utils-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 7.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.12

File hashes

Hashes for hestia_earth.utils-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 5c0fea4192bd3182b504f4a0808ab596cdbd9a5bc15c7ba781759ac67765c004
MD5 6aa4db5ab86f06bbbcfc4967a6298021
BLAKE2b-256 371dfaf158135d24b962acb837bc684795959daaded7dae4460aef02c9d5723f

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