Skip to main content
Yanked

This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Consider using release 1.1.0 instead.
Reason given by maintainers: Please upgrade to 0.3.0 for critical bug fixes and new features

OctopuSV: Advanced structural variant analysis toolkit 🐙

PyPI version License: MIT

OctopuSV is a high-performance structural variant (SV) analysis toolkit designed to standardize ambiguous SV annotations (e.g., BNDs), flexibly integrate multiple callers across samples or platforms, and benchmark results against trusted truth sets. With support for both single-sample and multi-sample workflows, OctopuSV enables robust and scalable SV comparison, correction, and visualization in real or simulated genomic datasets.

Key Features

  • BND Correction: Converts ambiguous breakend (BND) records into canonical SV types (DEL, INV, DUP, TRA), with translocation subtype classification
  • Flexible Multi-sample Merging: Boolean logic-based merge of SVs across multiple samples or callers
  • Multi-caller & Multi-platform Integration: Works seamlessly across Illumina, PacBio, ONT callers like Manta, LUMPY, SvABA, DELLY, PBSV, Sniffles, etc.
  • Benchmarking: Compare SVs to truth sets with precision/recall/F1 metrics using GIAB-style evaluation
  • Statistical Summaries: Profile SV distribution, quality, and size
  • Publication-ready Visualizations: Output interactive HTML reports and static plots

Installation

pip install octopusv

Quick Start

1. Correct Ambiguous BND Annotations

# Basic correction
octopusv correct input.vcf output.vcf

# With position tolerance control
octopusv correct -i input.vcf -o output.vcf --pos-tolerance 5

# Apply quality filters
octopusv correct -i input.vcf -o output.vcf --min-svlen 50 --max-svlen 100000 --filter-pass

2. Merge SV Calls (Multi-caller or Multi-sample)

# Merge across callers from same sample
octopusv merge -i manta.svcf lumpy.svcf -o merged.svcf --mode caller --caller-names Manta,LUMPY --intersect

# Merge across samples
octopusv merge -i sample1.svcf sample2.svcf sample3.svcf \
  --mode sample --sample-names HG001,HG002,HG003 \
  --min-support 2 -o shared.svcf

# Complex logic: A AND B but not C
octopusv merge -i A.svcf B.svcf C.svcf \
  --expression "(A AND B) AND NOT C" -o result.svcf

# Generate UpSet plot
octopusv merge -i a.svcf b.svcf c.svcf -o merged.svcf --intersect --upsetr --upsetr-output intersection.png

3. Benchmark Against Truth Sets

octopusv benchmark truth.vcf calls.svcf \
  -o benchmark_results \
  --reference-distance 500 \
  --size-similarity 0.7 \
  --reciprocal-overlap 0.0 \
  --size-min 50 --size-max 50000

4. Generate Statistics and Visualizations

# Basic stat collection
octopusv stat -i input.svcf -o stats.txt

# Add HTML report
octopusv stat -i input.svcf -o stats.txt --report

# Plot figures from stats
octopusv plot stats.txt -o figure_prefix

The --report flag outputs an interactive HTML report:

  • SV type and size distributions
  • Chromosome breakdowns
  • Quality score summaries
  • Genotype and depth features

5. Format Conversion

# To BED
octopusv svcf2bed -i input.svcf -o output.bed

# To BEDPE
octopusv svcf2bedpe -i input.svcf -o output.bedpe

# To standard VCF
octopusv svcf2vcf -i input.svcf -o output.vcf

Example Visualizations

OctopusV generates publication-ready visualizations:

Chromosome Distribution

SV Type Distribution

SV Size Distribution


Application Scenarios

OctopuSV was developed to address several practical needs in SV research:

  • Standardizing SVs with ambiguous BND notations
  • Enabling precise cohort-level comparisons (multi-sample mode)
  • Supporting accurate benchmarking with real/simulated truth sets
  • Integrating and comparing SVs across platforms (e.g., Illumina + ONT)
  • Automating large-scale SV analysis workflows (via TentacleSV)

See the companion pipeline: TentacleSV


🧪 Citation

If you use OctopuSV, please cite:

Guo Q, Li Y, Wang T, Ramakrishnan A, Yang R. OctopuSV and TentacleSV: a one-stop toolkit for multi-sample, cross-platform structural variant comparison and analysis. bioRxiv. 2025. doi: 10.1101/2025.03.24.645012

@article{guo2025octopusv,
  title={OctopuSV and TentacleSV: a one-stop toolkit for multi-sample, cross-platform structural variant comparison and analysis},
  author={Guo, Qingxiang and Li, Yangyang and Wang, Tingyou and Ramakrishnan, Abhi and Yang, Rendong},
  journal={bioRxiv},
  year={2025},
  publisher={Cold Spring Harbor Laboratory},
  doi={10.1101/2025.03.24.645012},
  url={https://www.biorxiv.org/content/10.1101/2025.03.24.645012v1}
}

Contributing

We welcome issues, suggestions, and pull requests!

git clone https://github.com/ylab-hi/OctopuSV.git
cd OctopuSV
poetry install
pre-commit run -a

Contact

Metadata

Release files for OctopuSV 0.2.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 OctopuSV 0.2.0
File Size Uploaded Provenance Actions
octopusv-0.2.0.tar.gz 247.1 kB Without provenance Details for octopusv-0.2.0.tar.gz

Built distribution (wheel)

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

Total release size: 517.0 kB

Release files / octopusv-0.2.0.tar.gz

Download URL octopusv-0.2.0.tar.gz
Size 247.1 kB
Tags Source
SHA-256 checksum
How to use checksums
8f03417b69634678bf33660e50097f1b09c1f1b170580dc67e55e56167f0a592
BLAKE2b-256 checksum
How to use checksums
225d74e6e6fb7f3ecbc445dd5ac823354486cd34efd70e6d70fd761469ee14d3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.10.8 Darwin/23.6.0

Release files / octopusv-0.2.0-py3-none-any.whl

Download URL octopusv-0.2.0-py3-none-any.whl
Size 269.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0283a5a3eab5759d5455b5ff6f317303c7598fc708ae0cefaa74e053f57943f4
BLAKE2b-256 checksum
How to use checksums
e29b2f66766cf8e7136e55c8ab7472f12b68ef3c9fbc528c72c3320ed3aa9bba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.10.8 Darwin/23.6.0

Security for OctopuSV 0.2.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.

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.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files No 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