Skip to main content

PHAB utilities for data processing

Reason this release was yanked:

incorrect namespace

Project description

phab-utils

Data processing tools and knowledge base of Centre for Earth Evolution and Dynamics and its successor Centre for Planetary Habitability.

Original project name was uio-exoplanet-group, which later got renamed to phab-utils (on 2025-01-29).

Installing

From PyPI

$ pip install phab-utils

If you need an older version from the original uio-exoplanet-group package, those are still available here.

From sources

$ cd /path/to/phab-utils/
$ pip install .

Add an -e argument, if you'd like to automatically update your locally installed package by pulling from the repository or/and if you intend to modify the sources:

$ pip install -e .

Building a wheel

You can also build a wheel and distribute/install that instead:

$ cd /path/to/phab-utils/
$ python -m build
$ pip install ./dist/phab_utils-*.whl

Data

Wherever you see a reference to some data files in documentation, examples, comments or anywhere else, for example some function taking a path like ./data/systems-528n.pkl, check the data folder - chances are, that file will be provided there.

Documentation

There are two different pieces of documentation.

API

Located in documentation. This is the package API documentation, which is published here.

It is generated with pdoc:

$ pip install pdoc

$ cd /path/to/phab-utils
$ rm -r ./documentation/_deploy/*

$ PHAB_PACKAGE_VERSION=$(git rev-parse --short HEAD) pdoc ./src/phab/utils ./src/phab/tasks \
    --template-directory ./documentation/_templates/ \
    --edit-url="utils=https://github.com/retifrav/phab-utils/blob/master/src/phab/utils/" \
    --edit-url="tasks=https://github.com/retifrav/phab-utils/blob/master/src/phab/tasks/" \
    --output-directory ./documentation/_deploy/
$ cp ./documentation/{favicon.ico,phab.jpg} ./documentation/_deploy/

For now it's a blunt deployment of generated HTML, but later it probably will be better to rely on GitHub Actions (if it won't spend too much of free quota) by customizing this workflow.

If you'd like to browse generated documentation locally, you can just open the main index.html from ./documentation/_deploy/ in your browser. Alternatively, you can launch a basic Python server:

$ cd ./documentation/_deploy/
$ python -m http.server 8000

and open http://localhost:8000/.

wiki

Located in wiki. This is general purpose / technical manuals, articles, notes, etc: how to install/build various tools, dependencies, how to set-up environments and so on.

It is meant to be published somewhere else, but for now it will do being a part of repository. GitHub wikis could've been an option, but those are still quite bad in terms of organizing the content.

Tests

To run tests:

$ pip install pytest

$ python -m pytest ./src/phab/tests/*[^_*].py
$ python -m pytest ./src/phab/tests/databases.py
$ python -m pytest ./src/phab/tests/databases.py -k "test_get_parameters_that_are_double_in_nasa"

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

phab_utils-0.8.0.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

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

phab_utils-0.8.0-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file phab_utils-0.8.0.tar.gz.

File metadata

  • Download URL: phab_utils-0.8.0.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for phab_utils-0.8.0.tar.gz
Algorithm Hash digest
SHA256 1f44acc9406753f9b34705341153d956a840447c9e0679575ef5da1fd919f932
MD5 9c49bb7673c58f8d9c17a9c4fbd99b14
BLAKE2b-256 3c8267bd88ebd8e4d540c3ac52b34d98c7e6e97fedfa089131ecbbd5b08e7a6d

See more details on using hashes here.

File details

Details for the file phab_utils-0.8.0-py3-none-any.whl.

File metadata

  • Download URL: phab_utils-0.8.0-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for phab_utils-0.8.0-py3-none-any.whl
Algorithm Hash digest
SHA256 79d1b11c9b36418deef1ff2c30cbaf432a1ae8c534ee672259e44cc8d8c60bab
MD5 7d90be9c4f2cdd7033bd7a90d43653f1
BLAKE2b-256 7723a55573c8b2bd24ed2bb424f6d6a5a59334388d69a4e4ac7d0c874fcbbaf0

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