Skip to main content

fqxv (Python)

Read-only Python bindings for fqxv, a Rust toolkit for lossless FASTQ archiving.

uv pip install fqxv

The wheels are abi3 (one per platform, CPython >= 3.9) and carry the native codecs, so there is no Rust toolchain to install.

import fqxv

# Stream records (works on every layout, including reordered archives)
for rec in fqxv.open("reads.fqxv"):
    print(rec.name, rec.sequence, rec.quality)  # all bytes

# In-memory input works too
data = open("reads.fqxv", "rb").read()
n = sum(1 for _ in fqxv.open(data))

# Decode only some streams — deselected fields come back as b"" and their coded
# streams are skipped, never entropy-decoded (sequence-only measured ~12x faster
# on ONT long-read archives, ~1.3-1.6x single-threaded on short-read Illumina)
for rec in fqxv.open("reads.fqxv", streams=("seq",)):
    ...                                         # rec.name == rec.quality == b""

# FASTA out, quality skipped entirely — the CLI's `decompress --fasta` as an API
fqxv.decompress_to_path("reads.fqxv", "reads.fasta", fasta=True)

# Whole-archive convenience
fqxv.decompress_to_path("reads.fqxv", "reads.fastq")
raw = fqxv.decompress_to_bytes("reads.fqxv")
info = fqxv.inspect("reads.fqxv")
print(info.reads, info.format_version, info.platform)

# Column projection / random access (plain layout only)
idx = fqxv.open_index("reads.fqxv")
seqs = fqxv.read_sequences("reads.fqxv")        # list[bytes], skips quality
ids = fqxv.read_names("reads.fqxv", groups=[0]) # just the first row group
block0 = fqxv.read_block("reads.fqxv", 0)       # list[Record]

# Read over the network (fqxv.remote, standard-library HTTP). Streaming decodes the
# whole archive on the fly; projection fetches only the column you ask for via HTTP
# byte-range requests.
import fqxv.remote as remote
for rec in remote.stream("https://host/reads.fqxv"):   # or a presigned S3 URL
    ...                                                # streams; no full download
arc = remote.open_index("https://host/reads.fqxv")     # 1 tail GET → footer index
names = arc.names()                                    # ~1% of the file, CRC-checked
print(arc.bytes_fetched, "of", arc.size)
n = remote.download("https://host/reads.fqxv", "reads.fastq")  # → FASTQ on disk

# Any file-like works, so an AWS SDK response streams straight in — no fqxv HTTP:
import boto3
body = boto3.client("s3").get_object(Bucket=b, Key=k)["Body"]
for rec in fqxv.open(body):
    ...
# For concurrent async range fetches, drive fqxv.parse_index_suffix /
# Index.stream_range / fqxv.decode_*_bytes with your own httpx/aiohttp session
# (see fqxv.remote's module docstring).

# Integrity check — raises fqxv.FqxvError on a corrupt archive
fqxv.verify("reads.fqxv")

# Project the archive size/ratio from a FASTQ *without* compressing (gzip/BGZF ok)
est = fqxv.estimate("reads.fastq.gz", level=5)  # also: quality_binning=, sample_reads=
print(est.ratio, est.archive_bytes, est.exhausted)

# Paired mates (or 10x R1/R2/I1/I2) compress into one archive — pass a list and
# their sample sizes are summed. A str/bytes source stays a single input.
est = fqxv.estimate(["R1.fastq.gz", "R2.fastq.gz"])

The on-disk .fqxv format is stable at 1.0 (a version independent of this package's), so archives written today stay readable by later releases — and an archive this build cannot read is refused with an error, never misread.

Projection and open_index are unavailable for globally-reordered archives (--order any, --max, --order shuffle), whose streams are mutually dependent; use fqxv.open() to iterate those — streams= selection works on every layout. Two selection caveats: long-read archives code quality against the bases, so selecting quality still decodes the sequence internally; and a skipped stream's integrity digest cannot be checked (run fqxv.verify() for a full check). Everything here is read-only: verify and estimate only measure — neither writes an archive — and full compression stays in the CLI.

Full API reference: https://rnabioco.github.io/fqxv/python/.

Build from source

uv pip install maturin
maturin develop            # from crates/fqxv-python/

Download files

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

Source Distribution

fqxv-0.7.0.tar.gz (956.2 kB view details)

Uploaded Source

Built Distributions

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

fqxv-0.7.0-cp39-abi3-win_amd64.whl (462.1 kB view details)

Uploaded CPython 3.9+Windows x86-64

fqxv-0.7.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (577.8 kB view details)

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

fqxv-0.7.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (544.1 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

fqxv-0.7.0-cp39-abi3-macosx_11_0_arm64.whl (497.9 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

fqxv-0.7.0-cp39-abi3-macosx_10_12_x86_64.whl (538.2 kB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file fqxv-0.7.0.tar.gz.

File metadata

  • Download URL: fqxv-0.7.0.tar.gz
  • Upload date:
  • Size: 956.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fqxv-0.7.0.tar.gz
Algorithm Hash digest
SHA256 c34f3e0492d581c45434bc7a83d529bf15f3d7c7faaa6cebeca6d5a8186f67e9
MD5 8e8fc6935cbca353edb1af4c1c9aa6c3
BLAKE2b-256 1d4c11c776c2c2703a265f0cbb41fe402fed774c2c4e6fdc151170603def1cb0

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0.tar.gz:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fqxv-0.7.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: fqxv-0.7.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 462.1 kB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fqxv-0.7.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 0dc23a0479f0258721049261ed338bfa82fe929b88422c8fa67667c717d0babf
MD5 0986d2fbb74b1ca817f38b399da50f02
BLAKE2b-256 63f26207e6bdc0c349478759dd60a9705b2283d301fad90f3fd65375e59175d0

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0-cp39-abi3-win_amd64.whl:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fqxv-0.7.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fqxv-0.7.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6533ee2b809c969fcfebe0ad6377222a04c415ed684d9d60c0af124850de9509
MD5 42b50a01822820faca53b61c7c2892e5
BLAKE2b-256 b42ffad258da1a55ff8346200189d1e77e923d48771df61c22941b715c2a1fbe

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fqxv-0.7.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for fqxv-0.7.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 5c7a0e3bca624100800dd311e734d2a81e7785233a00a9f69559d5b614ac9d07
MD5 b03b379efff36cc4fee4ffaeb1322a23
BLAKE2b-256 0d7db15e4b0186d5e93e2b3a25919ea9b7b21b531c64a17b0fbe67ef7d3d3073

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fqxv-0.7.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

  • Download URL: fqxv-0.7.0-cp39-abi3-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 497.9 kB
  • Tags: CPython 3.9+, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fqxv-0.7.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 070ac2a207179f7304bc91a0ebe3a4c64d45b69f7d09c077fb569bf5ad2e56ca
MD5 7c6357af29082b59232a1426d5a106c3
BLAKE2b-256 09f040c8c6ec2cc971f23f0c91c552b0b1922e1f978e6dfc1b4704deb84ccdf5

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fqxv-0.7.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

  • Download URL: fqxv-0.7.0-cp39-abi3-macosx_10_12_x86_64.whl
  • Upload date:
  • Size: 538.2 kB
  • Tags: CPython 3.9+, macOS 10.12+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fqxv-0.7.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 4818332d58cec8d960f598a05dd872432590644c4b7a51e0b799257b19d841fc
MD5 a1d7aa68cf0ce21b1337d8a0ca2334f2
BLAKE2b-256 9b5d482b4788734d57db7675d774c010e6f570f11f7df5b2b44601a04869b459

See more details on using hashes here.

Provenance

The following attestation bundles were made for fqxv-0.7.0-cp39-abi3-macosx_10_12_x86_64.whl:

Publisher: wheels.yml on rnabioco/fqxv

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.7.0 This release

6 files

0.6.2

6 files

0.6.1

6 files

0.6.0

6 files

0.5.2

6 files

0.5.1

6 files

0.5.0

6 files

0.4.0

6 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page