Skip to main content

nanocheck

nanocheck is a read-only inspector for Oxford Nanopore run data. It checks that files are intact and mutually consistent, describes BAM contents, inventories cohorts, and creates verifiable handover manifests.

nanocheck
├── check       integrity and cross-file consistency
├── summary     descriptive QC for one BAM
├── cohort      many BAMs as one table
├── manifest    file inventory and optional checksums
└── verify      verify a saved manifest

nanocheck never changes, indexes, or rewrites sequencing data.

Installation

python -m pip install ".[pod5]"

POD5 support is optional. For BAM/FASTQ-only use:

python -m pip install .

Check

nanocheck check /data/my_run
nanocheck check /data/my_run --json
nanocheck check /data/my_run --strict

check streams BAM, FASTQ, and POD5 files; detects malformed data, mixed run IDs and flow cells, duplicate reads, invalid read-group references, incomplete MM/ML pairs, and sample-sheet problems; and reconciles POD5 read IDs against BAM or FASTQ source IDs. It understands the pi/parent_read_id relationship from read splitting.

Read-ID storage defaults to auto: inputs below 10 GiB use memory and larger inputs use a temporary SQLite database. The exact backend can be selected when needed:

nanocheck check run/ --id-store memory
nanocheck check run/ --id-store disk

The disk database is deleted when the command finishes.

Summary

nanocheck summary sample.bam
nanocheck summary sample.bam --quick
nanocheck summary sample.bam --json
nanocheck summary sample.bam --timeline --timeline-output timeline.tsv

summary reports read and alignment counts, yield, length N50, Q-score, MAPQ, MM/ML presence, index and sort status, the exact reference-dictionary fingerprint, and ONT run, flow-cell, sample, barcode, basecaller, basecalling model, and modified-base model metadata. When st is available it also reports the first and last reads, run duration, and per-minute yield.

Full mode is the default. Quick mode reads at most the first 100,000 records and checks the BAM header and EOF marker. Sampled output is marked as incomplete.

Reference labels are conservative hints based on canonical chromosome lengths: GRCh37, GRCh38, T2T-CHM13v2.0, or unknown/custom. Cohort comparisons use the complete ordered @SQ name/length dictionary, not the hint or filename.

Cohort

nanocheck cohort /data/brain_tumors/*.bam
nanocheck cohort /data/bams --recursive --output cohort.tsv
nanocheck cohort /data/bams --recursive --csv
nanocheck cohort /data/bams --recursive --jsonl > cohort.jsonl

TSV, CSV, JSON, and JSONL exports include paths, file sizes, ONT metadata, reference, alignment counts, yield and length statistics, mapping metrics, MM/ML fractions, index status, errors, and warnings. Terminal output highlights mixed reference dictionaries and mixed basecalling configurations. Use --quick to sample each BAM.

Manifest and verification

nanocheck manifest /data/project > manifest.tsv
nanocheck manifest /data/project --checksum sha256 -o manifest.json
nanocheck verify manifest.json

Manifests recursively inventory all files. BAM, FASTQ, and POD5 entries also include available read and ONT metadata. JSON or TSV is selected from the output filename or explicitly with --json/--tsv. Verification always checks file sizes and checks hashes when the manifest contains them.

Exit status

Commands return 1 for errors. check --strict also returns 1 for warnings. cohort returns 1 for unreadable BAMs, an empty selection, or mixed reference dictionaries.

Development

python -m pip install -e ".[test,pod5]"
pytest

nanocheck is independent of Oxford Nanopore Technologie.

Metadata

Release files for nanocheck 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nanocheck 0.3.0
File Size Uploaded Provenance Actions
nanocheck-0.3.0.tar.gz 23.4 kB With provenance Details for nanocheck-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nanocheck 0.3.0
File Interpreter ABI Platform Actions
nanocheck-0.3.0-py3-none-any.whl Python 3 none any Details for nanocheck-0.3.0-py3-none-any.whl

Total release size: 48.7 kB

Release files / nanocheck-0.3.0.tar.gz

Download URL nanocheck-0.3.0.tar.gz
Size 23.4 kB
Tags Source
SHA-256 checksum
How to use checksums
db9bf4f1d17739c4c796505abfb4a0b776a8f69560436c879fb1e9d4cc5f3f91
BLAKE2b-256 checksum
How to use checksums
0f8523bd5119c284fc5aceccdf50d31eaf5222222e5cf8cad84e009e39ec0503
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 3, 2026.

Transparency log

Release files / nanocheck-0.3.0-py3-none-any.whl

Download URL nanocheck-0.3.0-py3-none-any.whl
Size 25.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
641e5c306a73e047bc543c15310ca5b2bbbdc0c3c0d7230dcc85c73f24d9800d
BLAKE2b-256 checksum
How to use checksums
5991331416bcef3507673a02e6b9747f712811385237984c88ea69f80e34561c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 3, 2026.

Transparency log

Security for nanocheck 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for nanocheck-0.3.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 3, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files Full provenance

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