regression of mpileup performance on Nanopore

Open
#1,584 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
c

Research direction

Start with the reported v1.12 versus v1.13 mpileup comparison on Nanopore data, using the Illumina and PacBio CCS truth data and pairwise SNP-distance measurements described. Reproduce the recall and precision regression while varying the mentioned BAQ, Nanopore configuration, and genotype-likelihood parameters; done means identifying a reproducible cause or actionable configuration.

Written by the indexing model from the issue text.

Description

needs-feedback requires-test-case

I have seen some differences in recall and precision with the big changes in the mpileup command in v1.13 with Nanopore data.

The first thing to say though is v1.13 is a massive improvement in terms of both CPU and memory usage. 🔥

I'm not sure of the best place to start this discussion so I'll start with a vague description of the scenario and I can provide more details for what you feel is relevant.

I am performing some SNP calling precision and recall analysis for Mycobacterium tuberculosis samples which I have Illumina and Nanopore data for. Seven of these sample I also have PacBio CCS for so I am used the CCS assemblies as truth genomes and masking spurious locations in further analysis.

I had fine-tuned some filters for version <=1.12 that provided precision on par with Illumina and recall a few percentage points lower than Illumina. However, these filters fail miserably for v1.13 - recall drops off a cliff, but precision stays good.

In addition to the seven samples with CCS assemblies, I have another 143 samples with Illumina and Nanopore data. My proxy for comparing these is pairwise SNP distance between samples for both technologies. The distance between a pair of samples should be the same on both technologies, so any difference are technology-driven. With v1.13 I am seeing a huge drop in the pairwise distance between samples on Nanopore - i.e., recall is very bad.

I have tried playing around with almost all of the mpileup parameters I think might be useful - full BAQ, partial BAQ, I tried the nanopore config, and basically all of the genotype likelihood parameters. I basically can't find a set of filters that provide a good balance between precision and recall for v1.13.

Normally I would just ignore this and stick with v1.12. But I figured this is likely helpful for others, and v1.12 uses an insane amount of memory and takes a few hours, compared to v1.13 which uses nearly no memory and CPU time comparatively.

Apologies for the rambling nature of this issue. I'm happy to provide plots, some data, try out some parameters etc.

Dominant language
C
Stars
891
Forks
277
Avg merge
2d 23h
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from samtools/bcftools

All issues in samtools/bcftools

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.