Earth Hologenome Initiative Toolkit
Project description
EHItk
The Earth Hologenome Initiative ToolKit (EHItk) is a Python package and command-line tool for finding, summarizing, exporting, and downloading EHI specimens, hologenomes, and metagenome-assembled genomes.
Installation
pip install ehitk
Example
ehitk specimens query --host-species "Podarcis muralis" --limit 5
ehitk hologenomes query --biome ENVO:01000175 --limit 5
ehitk hologenomes fields
ehitk hologenomes values --field country --limit 10
ehitk mags stats --quality high --species "Escherichia coli"
ehitk mags query --quality high --csv | head
ehitk specimens values --field sex --csv --output-file specimen-sex-values.csv
Python API:
import ehitk
with ehitk.Database() as ehidb:
mags = ehidb.mags.query(quality="high", host_taxid=40674, limit=5)
for mag in mags:
print(
mag.mag_id,
mag.quality,
mag.host_taxid,
mag.host_species,
mag.mag_family,
mag.mag_genus,
)
Documentation
Full installation instructions, command reference, examples, output formats, identifier namespaces, download guidance, and Python API examples are available at:
Use the built-in help for local command details:
ehitk --help
ehitk specimens --help
ehitk hologenomes fetch --help
ehitk mags query --help
Bundled database and versioning
EHItk ships with a bundled SQLite EHI database, which is the default database used by the command-line interface and Python API. Updating the Python package may therefore also update the default EHI database.
Use ehitk database to inspect the catalog currently in use, including its
path, source, size, SHA256 checksum, and its data_version / schema_version
(unknown for older catalogs built before this metadata existed). EHItk
validates schema_version when it opens a catalog and reports a clear error if
the catalog is too new or too old for the installed package.
Database updates are paired with documented EHI data releases. Each release
produces a standalone ehitk-database-<data_version>.sqlite artifact and
checksum file for GitHub Releases and Zenodo, while the same SQLite file remains
bundled inside the matching Python package for convenience. The citable Zenodo
database record is available at https://doi.org/10.5281/zenodo.20430293. Older
database files can be used to rerun analyses against the same database version by
passing the file with --db or by opening it with
ehitk.Database("/path/to/ehitk.sqlite").
Published database versions (generated from Zenodo by
scripts/update_db_list.py):
No published database versions found.
The public package does not rebuild the curated EHI metadata catalog from
upstream sources; that is done by the separate
ehitk-build generator, which
publishes each catalog to Zenodo. Fresh catalogs are obtained by upgrading EHItk
or by downloading a versioned database artifact.
EHItk package versions follow Semantic Versioning for the software interface.
Database updates that break the SQLite schema contract bump the catalog's
schema_version and require a coordinated (major) EHItk release; non-breaking
database additions or metadata corrections bump the data_version only and are
released as minor or patch versions. All are documented in the changelog and
associated data release notes.
Testing and continuous integration
EHItk includes a pytest-based unit test suite in the tests/ directory. The
repository also uses GitHub Actions continuous integration to run the test suite,
build source and wheel distributions, and perform CLI smoke tests across Python
3.10, 3.11, 3.12, 3.13, and 3.14.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ehitk-1.2.1.tar.gz.
File metadata
- Download URL: ehitk-1.2.1.tar.gz
- Upload date:
- Size: 1.2 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9e5c49d2d0042ed5077db27df7285e7be5f67b5e20b89ac0911103c3b00cf37a
|
|
| MD5 |
d15d016a02c88340215fffba049ea30d
|
|
| BLAKE2b-256 |
f6b2f73ff909968246c1e9313a3ad9379b8ef0573fc565502543030bba459e5b
|
Provenance
The following attestation bundles were made for ehitk-1.2.1.tar.gz:
Publisher:
release.yml on earthhologenome/ehitk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ehitk-1.2.1.tar.gz -
Subject digest:
9e5c49d2d0042ed5077db27df7285e7be5f67b5e20b89ac0911103c3b00cf37a - Sigstore transparency entry: 1990598955
- Sigstore integration time:
-
Permalink:
earthhologenome/ehitk@6fd1038c3076b26eabdba92282a24d3cac0aefe8 -
Branch / Tag:
refs/tags/v1.2.1 - Owner: https://github.com/earthhologenome
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6fd1038c3076b26eabdba92282a24d3cac0aefe8 -
Trigger Event:
push
-
Statement type:
File details
Details for the file ehitk-1.2.1-py3-none-any.whl.
File metadata
- Download URL: ehitk-1.2.1-py3-none-any.whl
- Upload date:
- Size: 1.2 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cb8bdbc93f1ad173880d7f5743c5eb549ada2c3df2c35c627386ec60e4410ba6
|
|
| MD5 |
441b915b939912bb916018169f492e59
|
|
| BLAKE2b-256 |
da33edc55bff72b5025c02d6d7fae41c4d4008c3478d709cbec6c8fc0d449f43
|
Provenance
The following attestation bundles were made for ehitk-1.2.1-py3-none-any.whl:
Publisher:
release.yml on earthhologenome/ehitk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ehitk-1.2.1-py3-none-any.whl -
Subject digest:
cb8bdbc93f1ad173880d7f5743c5eb549ada2c3df2c35c627386ec60e4410ba6 - Sigstore transparency entry: 1990599059
- Sigstore integration time:
-
Permalink:
earthhologenome/ehitk@6fd1038c3076b26eabdba92282a24d3cac0aefe8 -
Branch / Tag:
refs/tags/v1.2.1 - Owner: https://github.com/earthhologenome
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6fd1038c3076b26eabdba92282a24d3cac0aefe8 -
Trigger Event:
push
-
Statement type: