Skip to main content

Another Genome Conversion Tool: Python frontend to Rust chainfile crate

Project description

agct: Another Genome Conversion Tool

image image image Actions status

Lift over positions between genomic reference assemblies, using the St. Jude's chainfile crate.

Enables significantly faster chainfile loading from cold start (see analysis/).

Installation

Install from PyPI:

python3 -m pip install agct

Usage

Initialize a class instance:

from agct import Converter, Assembly, Strand

c = Converter(Assembly.HG19, Assembly.HG38)

If a chainfile is unavailable locally, it's downloaded from UCSC and saved using the wags-tails package -- see the wags-tails configuration instructions for information on how to designate a non-default storage location.

Call convert_coordinate():

c.convert_coordinate("chr7", 140453136, 140453137, Strand.POSITIVE)
# returns [LiftoverResult(chrom='chr7', start=140753336, end=140753337, strand=<Strand.POSITIVE: '+'>)]

Development

The Rust toolchain must be installed.

Create a virtual environment and install developer dependencies:

python3 -m virtualenv venv
source venv/bin/activate
python3 -m pip install -e '.[dev,tests]'

This installs Python code as editable, but after any changes to Rust code, run maturin develop to rebuild the Rust binary:

maturin develop

Be sure to install pre-commit hooks:

pre-commit install

Check Python style with ruff:

python3 -m ruff format . && python3 -m ruff check --fix .

Use cargo fmt to check Rust style (must be run from within the rust/ subdirectory):

cd rust/
cargo fmt

Run tests with pytest:

pytest

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

agct-0.2.0.tar.gz (13.8 kB view details)

Uploaded Source

Built Distributions

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

agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl (349.2 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ s390x

agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (456.3 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ppc64le

agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (331.0 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ARMv7l

agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (320.9 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ARM64

agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl (350.6 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ s390x

agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (458.3 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ppc64le

agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (333.6 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ARMv7l

agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (321.4 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ ARM64

agct-0.2.0-cp310-abi3-win_amd64.whl (179.1 kB view details)

Uploaded CPython 3.10+Windows x86-64

agct-0.2.0-cp310-abi3-win32.whl (174.9 kB view details)

Uploaded CPython 3.10+Windows x86

agct-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (328.4 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

agct-0.2.0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl (349.6 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ s390x

agct-0.2.0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (456.1 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ppc64le

agct-0.2.0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (331.9 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARMv7l

agct-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (321.5 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARM64

agct-0.2.0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl (354.0 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.5+ i686

agct-0.2.0-cp310-abi3-macosx_11_0_arm64.whl (289.1 kB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

agct-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl (293.1 kB view details)

Uploaded CPython 3.10+macOS 10.12+ x86-64

File details

Details for the file agct-0.2.0.tar.gz.

File metadata

  • Download URL: agct-0.2.0.tar.gz
  • Upload date:
  • Size: 13.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: maturin/1.10.2

File hashes

Hashes for agct-0.2.0.tar.gz
Algorithm Hash digest
SHA256 7ccde14edde297cadb6e7a8410b5c4801a30e23655b4d55cd408d3943146968f
MD5 85f877bf2f81cbbfce83491093ebcb2f
BLAKE2b-256 c81cb2c716dd53de970539f043ccfc12be6b471781aa8d63154eff5e783d6e41

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 b3a3685d93c860713f5e1582161c764b156eb4e8bd7fcd74bae77adcc4f52e9f
MD5 e123aa83d2eba17317b6d294e89de8ea
BLAKE2b-256 e9c3e6401ebea6c9aa585a42b435070b3bec71759eb4edef055ad7061bfb87f0

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 a31e237bb6cd88d920159dd6951181127e0089145a89ffd685cfea7e73991523
MD5 8599f688b20409fe7df47a473f5aab34
BLAKE2b-256 f41705b2685e465c7318655e56c002326b51f4b40194ad79a709d5e8e919ecd7

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 b500be5399415b11322f68baaaa8ce4518af1a32dc97efd5f7e198b80484b9f7
MD5 8df079a0b91851c7a65bdb19032c538c
BLAKE2b-256 121ba45da3e9d7dfa75bf56c6bb8b8650f2d7ec36d5c5706bc9824a228ff6ae2

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 7db2f2625c9a463146b65b70eab884fac7b5dce270d1585c541dcf55fff34a60
MD5 39795700a384a7b0356f3f04e3d1bcd0
BLAKE2b-256 36de88ea595de5bd382be1d82a783ac322d0dd19ec9dd555989350eb56205c59

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 2a922222f993e1427ceb367d661ba8425cfaff3a76b61d3d30881f9b431e7a51
MD5 fc0ad8cf2f434f15db3686804080bc26
BLAKE2b-256 869c4bbec0f6c8cc52cf009f35c7e2c7833fd5461d75e8dd5f8c69ae93e52a13

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 a2ad499b3ae7b57487ff7e5ba4d242cbeebc8808fc1b24de5aa802d86398ae02
MD5 aca6aee8ebd5199a2109dc252f9038c3
BLAKE2b-256 80c8debbecbeb5e50c25c25c44b374106ad86ac7ec1b461f6a448819f6ab9d77

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 9a83765f4b4f3076746fea7cb036fd196de2b597b212cafe856b8058b73de8a4
MD5 281050679b310984218ad79588050126
BLAKE2b-256 8cc29e36c865dc352029e1af6c4e7d72de6414c1556f84726487307fab431f8d

See more details on using hashes here.

File details

Details for the file agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 5c369f5830cfd6f0ab67b86eaf985b76429e7ab73c36be7c0beda9d7f328a98c
MD5 72b718f74353267a2ff0539644aaea38
BLAKE2b-256 a948200e4281b2531e2117a91bf4ecbba5f31ad90edf0fcccd63632e2f95613b

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: agct-0.2.0-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 179.1 kB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: maturin/1.10.2

File hashes

Hashes for agct-0.2.0-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 c32a8bb92aa5bd4f30e96612c87470cab77d2ec5804bd932612a073d2487224e
MD5 ff19e866ddaeab680df633ac698ee380
BLAKE2b-256 e66bfc2cea8629e1f34a75827ad391503ce90626e1d41fea16f3887131089e0e

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-win32.whl.

File metadata

  • Download URL: agct-0.2.0-cp310-abi3-win32.whl
  • Upload date:
  • Size: 174.9 kB
  • Tags: CPython 3.10+, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: maturin/1.10.2

File hashes

Hashes for agct-0.2.0-cp310-abi3-win32.whl
Algorithm Hash digest
SHA256 85dc8fa5a06ca8b3b91f3114d6090c3dbf9a9ae8527f762ab677c4ea9a5105f2
MD5 ea4b239b2446b33dfd9a721cfc6364b0
BLAKE2b-256 c19b31c7d817ccd0a2f9b444d670f36f01865f534c6282b99a7e43c88a7bc93d

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b03a18160432eb93647440ebcdca365eb40febe73d58a0264213b6e0a6aa8e1d
MD5 38edc0705d372992fd009e458798f870
BLAKE2b-256 6a24510b7f388a5a07b7a82024d4b86831e0c69cdef6cc4d5864412eb3b2c362

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 de3ac7d7c178b584a24264d9ccba40d288bf605de0c4a6f93b1958e3a27f8023
MD5 819ffae0d9f47dd673aae8e71d9585ac
BLAKE2b-256 dbf6137c9bf7914f41eeb79f1d578543a6616cb5a4c1a03074b3fa5739efca16

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 baa0f8d06f455e3c38d3ad0550c0ad2ccad8b73f07c439cc2c70b5c9651a654e
MD5 cf2f0ff9de47d49eee626e1aac98d6df
BLAKE2b-256 de7bd5d47b31836da9896867cd29f004fbcc58a016ffa98bda2209a11a8288d5

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 60fda2f0b51c59de0e84ed2a015cda3b2e67e111baaa3af175ac5eff16f896db
MD5 cde7cec4bd7aefeba8e705c701f2586c
BLAKE2b-256 01d0b0e24ca9f16f84b23fb72d2375ffba0df18f764113073dbe943b57820a10

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 16957817947b838413a1ecbfb9b1f7bf4621b0adf1fa9e340d9d94b05d5d5d2e
MD5 d2b0934f039150a375ad1b866e36a9bc
BLAKE2b-256 9a38e1cc4c5cce9456067784614325bac37ecb40f5d068fcaf1ad91e5e7f000f

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl
Algorithm Hash digest
SHA256 7b52a128efbf6a3476d36cc73be7ce5d55e6c7c472cba363a74767d6c468f626
MD5 e077c121a556e965256da0a4cbed6d02
BLAKE2b-256 90fd8a31db2c6dfce6f9c27837951cea5d444848c994a8514102461642c0df63

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1668b37542e93acb3af89afd38dd87e09c43bf4927f385ad9f405221e07fa7f2
MD5 70089bc18a7e2e7ee1e9318d1c8f1197
BLAKE2b-256 2b49c12d579152fa849e1712c6173337131995226c41894047984e6e8c72861a

See more details on using hashes here.

File details

Details for the file agct-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for agct-0.2.0-cp310-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 b9574c109885ff3cffe3f86cf131da19e659363cc8c7f4593312b20aa6210389
MD5 5d76c42719a3435649f9b8bd39d976af
BLAKE2b-256 ff234b690637cdc16a8b19e0b0d936db4afcc7111a2a61fd0d4f468fb90b961f

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