Skip to main content

Turbo Picard

CI PyPI DOI

Native Rust implementations of 35 Picard commands, plus 6 Turbo Picard utilities, with Picard-checked outputs, KEY=VALUE flags, and transparent fallback to upstream Picard for the remaining 86 commands.

Turbo Picard MarkDuplicates and 4x GRCh38 WGS timings and memory against Picard, Riker, FastDup, and samtools.

Documentation · Command coverage · Compare alternatives · Evaluate on your data · Bunsen


How fast is Turbo Picard?

Most bioinformatics pipelines pay a heavy tax in JVM startup, Java heap bloat, and repeated BAM/CRAM decompression passes. Turbo Picard removes the JVM on native paths, streams directly through HTSlib/libdeflate, uses bounded external sorting, and validates outputs against Picard 3.4.0 and 3.5.0 in CI.

Bold marks the #1 result in each benchmark group below.

1. Whole-genome QC vs Riker and Picard (CollectWgsMetrics)

1000 Genomes HG02675 GRCh38 alignments · Intel i7-8700 · 6 threads (Picard 1T) · cold page cache (benchmarks/wgs-coverage-2026-11-13/README.md):

Depth Tool Wall time Peak RSS Advantage vs baseline / rival Picard parity
4x WGS Turbo Picard (6 workers) 21.8–22.6 s 125 MB ~47x faster vs Picard · 1.3x faster & 4.0x less RAM vs Riker ✓ Exact
4x WGS riker wgs 0.5.0 (6 threads) 29.7 s 504 MB 35x faster vs Picard · 4.0x more RAM than Turbo Picard ✗ Differs
4x WGS Picard 3.5.0 (1 thread) 1,033.8 s 1,468 MB 1.0x reference · 11.7x more RAM than Turbo Picard ✓ Reference
15x WGS Turbo Picard (6 workers) 65.4–82.6 s 274 MB Lowest RAM (~1.9x less than Riker) Not compared
15x WGS riker wgs 0.5.0 (6 threads) 78.2–79.7 s 518 MB Competitive speed · ~1.9x more RAM ✗ Differs
30x WGS Turbo Picard (pre-PR #76) 193.5 s 412 MB Lowest RAM (19% less than Riker) Not compared
30x WGS riker wgs 0.5.0 (6 threads) 147.4 s 510 MB Fastest pre-PR #76 (fallback to 1T on capped contig) ✗ Differs
  • On the 4x genome Turbo Picard matches every metric field and histogram row of Picard 3.5.0 (the 15x and 30x genomes have no Picard output to compare); riker wgs uses simplified TSV output and documented metric differences.
  • On 30x WGS pre-PR #76, hitting LOCUS_ACCUMULATION_CAP=100,000 forced single-threaded whole-contig reprocessing; PR #76 replaced that with targeted capped-cluster reprocessing (awaiting i7-8700 rerun).
  • On the 2.1 MB gatk-na12878-mito smoke check (bench_qc_vs_riker.md): Turbo Picard ran wgs-only in 0.012 s (riker wgs 0.024 s, 2.10x faster; Picard 7.302 s, 634x faster) and wgs-bundle in 0.025 s (riker multi 0.053 s, 2.14x faster; Picard 11.801 s, 477x faster).

2. Duplicate marking vs FastDup, samtools markdup, and Picard

Linux x86_64 · 1 pinned CPU · BAM compression level 5 (benchmarks/markduplicates-competitors/):

Dataset Tool Wall time Peak RSS Speedup vs Picard RAM vs Picard Picard parity
paired-600k Turbo Picard 1.054 s 94.1 MiB 5.15x 11.2x less ✓ Exact
paired-600k FastDup 1.131 s 383.8 MiB 4.79x 2.7x less ✗ Differs
paired-600k samtools markdup 1.982 s 235.7 MiB 2.74x 4.5x less ✗ Differs
paired-600k Picard 3.4.0 5.423 s 1,052.6 MiB 1.00x 1.0x ✓ Reference
gatk-na12878-mito Turbo Picard 0.141 s 9.5 MiB 19.0x 75.9x less ✓ Exact
gatk-na12878-mito FastDup 0.201 s 356.7 MiB 13.3x 2.0x less ✗ Differs
gatk-na12878-mito Picard 3.4.0 2.678 s 721.3 MiB 1.00x 1.0x ✓ Reference

samtools markdup requires query-grouped fixmate -m and coordinate sorting, so its timer includes those preparation stages from a coordinate-sorted BAM. Only Turbo Picard matches Picard 3.4.0 on all flags, tags, metrics, and histograms.

3. Latest main core speedups (PR #76, Apple M5 vs prior main and Picard 3.4.0)

Paired warm-cache medians (1 warmup + 3 repeats) on Apple M5 comparing main against pre-PR #76 main and Picard 3.4.0, as reported in the PR. The raw runs, input hashes and exact options were not retained, so treat these as indicative until a benchmark bundle is checked in:

Command Workload Turbo Picard (main) vs pre-PR #76 main vs Picard 3.4.0
MarkDuplicates 1.2M paired BAM 0.303 s / 73.8 MiB 2.07x faster (37% less RSS) 9.06x faster · 18x less RAM
MarkDuplicates (spill) 1.2M reads, bounded 0.458 s 1.60x faster 4.21x faster
SortSam (coordinate) 1.2M reads 0.520 s 2.35x faster 4.32x faster
SortSam (queryname) 1.2M reads 0.415 s 2.64x faster 4.63x faster
MergeSamFiles (4-way) 1.2M reads 0.166 s 1.74x faster 6.58x faster (samtools -@8: 0.154 s)
CollectHsMetrics Capture panel intervals 0.546 s 1.24x faster 12.8x faster
SamToFastq 600k paired BAM 0.577 s 1.71x faster 1.92x faster
CleanSam 600k paired BAM 0.077 s 1.40x faster 9.44x faster

Quick Start

Install from PyPI (Linux x86_64, macOS Intel & Apple Silicon, or source build):

python3 -m pip install turbo-picard==0.1.20

Or run the container:

docker run --rm ghcr.io/dnncha/turbo-picard:0.1.20 --version

Or build from source:

cargo install --locked --path crates/turbo-picard-cli --bin turbo-picard --bin picard

Keep upstream Picard as automatic fallback

turbo-picard runs natively when a command and its options fall inside its documented native scope (41 commands: 12 full-scope, 29 scoped-native), and forwards the remaining 86 commands (or unsupported flags) to upstream Picard when configured:

mamba create -n turbo-picard -c conda-forge -c bioconda \
  turbo-picard picard=3.4.0 openjdk
mamba activate turbo-picard
turbo-picard doctor

With a pip install, set PICARD_JAR=/path/to/picard.jar with Java on PATH. See fallback behavior.

Installing from PyPI currently gives you both commands:

  • turbo-picard — explicit binary for evaluation and targeted pipeline steps.
  • picard — optional compatibility shim when you want existing picard calls to resolve to Turbo Picard.

Use the explicit turbo-picard command while testing. Switch a pipeline task only after verifying outputs on a representative input:

# Check environment and fallback readiness
turbo-picard doctor

# Print the exact side-by-side comparison contract before editing a workflow
turbo-picard trial MarkDuplicates I=input.bam O=marked.bam M=metrics.txt

# Enforce native execution (fail instead of delegating to Java)
TURBO_PICARD_REQUIRE_NATIVE=1 turbo-picard MarkDuplicates \
  I=input.bam O=marked.bam M=metrics.txt

Machine-readable discovery and MCP server

For Nextflow/WDL/Snakemake generators and coding agents, inspect command support and trial contracts as JSON without guessing:

turbo-picard capabilities --json --command MarkDuplicates
turbo-picard explain --json SortSam I=in.bam O=out.bam SORT_ORDER=coordinate
claude mcp add turbo-picard -- turbo-picard mcp

mcp-name: io.github.dnncha/turbo-picard. Agent integrations for Claude Code (/plugin install turbo-picard --marketplace dnncha/turbo-picard), Codex, and Cursor live in packaging/agents/.


When It Helps

  • You run MarkDuplicates, SortSam, MergeSamFiles, SamToFastq, FastqToSam, FixMateInformation, BuildBamIndex, CollectWgsMetrics, CollectHsMetrics, CollectRnaSeqMetrics, CollectSamErrorMetrics, CollectMultipleMetrics, or VCF utilities and want lower wall time and memory without rewriting pipeline syntax.
  • You need Picard-style command names, KEY=VALUE flags, and Picard-checked outputs (flags, tags, metrics text, histograms, indexes, MD5 sidecars) to stay intact.
  • You want a one-command-at-a-time rollout where unsupported commands or flags cleanly fall back to upstream Picard.
  • You want to compare outputs side by side on your own BAM/CRAM with tools/compare_real_data.py before changing anything in a shared pipeline.

When To Stay With Picard

  • You need a command or option outside the documented native scope and cannot configure upstream Picard fallback.
  • You require Picard's full R-rendered chart PDFs rather than checked metrics text (CollectBaseDistributionByCycle, CollectGcBiasMetrics, CollectInsertSizeMetrics, MeanQualityByCycle, QualityScoreDistribution emit lightweight PDF summaries).
  • You have not verified required flags, sidecars, metrics, exit codes, and downstream tools on a representative shard of your own data.

Documentation & Workflow Integration

The full docs are on Read the Docs: turbo-picard.readthedocs.io.

Run your own side-by-side comparison using the repository evaluator (local execution only, separate output directory, retains failed runs for inspection): see the real-data evaluation guide or share redacted trial reports via the trial report issue form (or thread #4). See the workflow validation protocol, compatibility contract, and production-scale benchmark format.


Saved 32-Command Small-Fixture Suite & Evidence Gates

Across the 32 parity-checked commands in the saved small-fixture suite (where JVM startup contributes materially and does not by itself predict whole-genome ratios), Turbo Picard records a 22.88x minimum, 84.52x geometric mean, 99.51x median, and 272.12x maximum speedup against Picard 3.4.0. In the saved MarkDuplicates fixture (reads=50000), median wall times were 0.075464 seconds for Turbo Picard vs 2.238986 seconds for Picard. See the benchmark guide and parity guide. Metrics-text agreement does not establish Picard-equivalent charts; Bunsen publishes broader software investigations and corrections.

Saved benchmark record

Expand all 32 small-fixture measurements, exemptions, provenance, and verification commands

The saved public benchmark suite compares native turbo-picard commands against Picard 3.4.0 and checks stable outputs before reporting speed. Current saved results report 32/32 parity checks passing, with 272.12x top speedup: NormalizeFasta, 22.88x floor speedup: SetNmMdAndUqTags, 99.51x median speedup, and 84.52x geometric mean speedup.

Summary: 32/32 PASS; 272.12x top speedup: NormalizeFasta; 22.88x floor speedup: SetNmMdAndUqTags; 99.51x median speedup; 84.52x geometric mean speedup.

Benchmark details, scope notes, real-data evidence, and reproduction commands are in the benchmark docs. The parity guide explains what the comparisons do and do not prove. For CollectBaseDistributionByCycle, CollectGcBiasMetrics, CollectInsertSizeMetrics, MeanQualityByCycle, and QualityScoreDistribution, metrics text is the parity target; chart outputs are lightweight PDF summaries, not Picard-equivalent rendered plots.

Saved benchmark run:

  • Date: 2026-08-14
  • Command: python3 tools/bench_suite.py --repeats 3 --skip-build
  • Raw log: docs/site/assets/bench-suite-output.txt
  • benchmark exceptions: AccelerationStatus, capabilities, doctor, explain, mcp, and trial are utility commands, not Picard workload comparisons. CollectHsMetrics, CollectRnaSeqMetrics, and CollectSamErrorMetrics have separate Picard parity coverage; suite-integrated small-fixture entries await representative capture/transcript/error fixtures in the automated suite.
Command Speedup Parity
NormalizeFasta 272.12x PASS
BuildBamIndex 243.53x PASS
UpdateVcfSequenceDictionary 207.52x PASS
CollectGcBiasMetrics 196.45x PASS
CreateSequenceDictionary 152.62x PASS
GatherVcfs 130.70x PASS
LiftoverVcf 127.28x PASS
CollectMultipleMetrics 122.66x PASS
CollectInsertSizeMetrics 117.34x PASS
CleanSam 115.42x PASS
MergeVcfs 112.13x PASS
MeanQualityByCycle 108.66x PASS
CollectQualityYieldMetrics 108.64x PASS
QualityScoreDistribution 107.17x PASS
ReplaceSamHeader 101.84x PASS
ValidateSamFile 99.56x PASS
IntervalListTools 99.46x PASS
CollectBaseDistributionByCycle 98.01x PASS
SortVcf 89.01x PASS
CollectAlignmentSummaryMetrics 83.49x PASS
BedToIntervalList 79.78x PASS
ViewSam 79.58x PASS
AddOrReplaceReadGroups 77.78x PASS
SamToFastq 77.74x PASS
CollectWgsMetrics 50.81x PASS
MergeSamFiles 35.49x PASS
SortSam 35.15x PASS
FixMateInformation 31.98x PASS
FastqToSam 31.29x PASS
MarkDuplicates 28.70x PASS
RevertSam 24.19x PASS
SetNmMdAndUqTags 22.88x PASS

Release evidence checks:

python3 tools/update_real_data_manifest.py
python3 tools/verify_benchmark_log_evidence.py
python3 tools/verify_benchmark_suite_coverage.py
python3 tools/verify_benchmark_thresholds.py
python3 tools/verify_real_data_evidence.py
python3 tools/verify_real_data_evidence.py --release-ready

Real-data evidence lives in benchmarks/real-data/ and records pinned input sources, command scopes, and input SHA-256 hashes. Current release-candidate dataset IDs are gatk-na12878-mito, picard-snvq, and gatk-na12878-mito-cram.


Packaging Status & Citation

  • Release: The current source release is 0.1.20 on GitHub Releases and PyPI (Linux x86_64, macOS Intel & Apple Silicon wheels, plus sdist for Linux ARM64 with a Rust toolchain). See CHANGELOG.md for release notes and website/assets/distribution-status.json for observed build checksums.
  • Bioconda: Accepted initial recipes on 4 October 2026 (0.1.15 in Bioconda indexes on 25 October; 0.1.16 main and shim updates open upstream). turbo-picard-full documents the combined turbo-picard + picard + openjdk recipe.
  • Citation: Cite the archived turbo-picard release you used via CITATION.cff (DOI 10.5281/zenodo.20541927). Cite benchmark and validation inputs separately with immutable source URLs, commits or accessions, and input SHA-256 hashes. Docs live in docs/; JOSS submission notes are in docs/joss-submission.rst.

Contributing

Bug reports, parity evidence, documentation fixes, and command-coverage contributions are welcome. See CONTRIBUTING.md, the development docs, SUPPORT.md, and SECURITY.md.

Metadata

Release files for turbo-picard 0.1.20

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

Source distribution (sdist)

Source distribution for turbo-picard 0.1.20
File Size Uploaded Provenance Actions
turbo_picard-0.1.20.tar.gz 379.3 kB Without provenance Details for turbo_picard-0.1.20.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for turbo-picard 0.1.20
File Interpreter ABI Platform Actions
turbo_picard-0.1.20-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for turbo_picard-0.1.20-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
turbo_picard-0.1.20-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for turbo_picard-0.1.20-py3-none-macosx_11_0_arm64.whl
turbo_picard-0.1.20-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details for turbo_picard-0.1.20-py3-none-macosx_10_12_x86_64.whl

Total release size: 30.8 MB

Release files / turbo_picard-0.1.20.tar.gz

Download URL turbo_picard-0.1.20.tar.gz
Size 379.3 kB
Tags Source
SHA-256 checksum
How to use checksums
5c1890ccad1110f30f1c15dc5a90dd095182758540e1c376af0c5e1e8f15617d
BLAKE2b-256 checksum
How to use checksums
3dd844fb76e0db50cbf4d7c3997f08e8d1702d541df096f902869e273af939e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.12

Release files / turbo_picard-0.1.20-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL turbo_picard-0.1.20-py3-none-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 10.4 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
b678e671ac4e416b743b4e2df41793706d61f2534b015faa31f2379e8ca8f356
BLAKE2b-256 checksum
How to use checksums
8144f1a761fe4d5005a5da7ee54a9142583c864dd4cdbf966eeb543caa70b1ec
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.12

Release files / turbo_picard-0.1.20-py3-none-macosx_11_0_arm64.whl

Download URL turbo_picard-0.1.20-py3-none-macosx_11_0_arm64.whl
Size 9.8 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
a5fb220ab6c16704bddd1de2cbac626d1881c01ab56b890d6875c728e9be659e
BLAKE2b-256 checksum
How to use checksums
9b275b84f05300204faad1ca9bd30bb2b4fc3762b357915ef4003d68ec66598d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.12

Release files / turbo_picard-0.1.20-py3-none-macosx_10_12_x86_64.whl

Download URL turbo_picard-0.1.20-py3-none-macosx_10_12_x86_64.whl
Size 10.3 MB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
9dde8880b9e571fe6478076ee600ba9b4afc84eb7d79be020f004b01cd606b92
BLAKE2b-256 checksum
How to use checksums
62d0e491302b749c1604f2bbd1d5f5dbec2f5ab3e766ffe39be738ab04edc590
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.12

Security for turbo-picard 0.1.20

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

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