Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resolve_cigar2: Assertion `k < c->n_cigar' failed. #26

Closed
cjw85 opened this issue Feb 19, 2019 · 4 comments
Closed

resolve_cigar2: Assertion `k < c->n_cigar' failed. #26

cjw85 opened this issue Feb 19, 2019 · 4 comments

Comments

@cjw85
Copy link
Member

cjw85 commented Feb 19, 2019

However I got an error when running:
medaka_variant -r GRCh38_full_analysis_set_plus_decoy_hla.fa -b rel5-guppy-0.3.0-chunk10k.sorted.bam -m r94 -R chr22

The reference file and bam file are downloaded from
https://github.com/nanopore-wgs-consortium/NA12878/blob/master/nanopore-human-genome/rel5.md

[15:11:34 - Feature] Processed chr22:43999000.0-45000000.0 (median depth 34.0)
[15:11:34 - Sampler] Took 3.93s to make features.
[15:11:53 - PWorker] 46.8% Done (23.8/50.9 Mbases) in 532.3s
[15:11:54 - Sampler] Initializing sampler for consensus or region chr22:44999000-46000000.
python3.6: sam.c:1550: resolve_cigar2: Assertion `k < c->n_cigar' failed.
python/Python-3.6.3/bin/medaka_variant: line 75: 24999 Aborted (core dumped) medaka consensus ${BAM} ${PROBS} --model ${MODEL} --batch_size ${BATCH_SIZE} ${REGIONS} --threads ${THREADS} ${EXTRAOPTS}

From the error message above, it seems there are some bad cigar in the aligned bam? This problem happened to other chromosomes as well. Please let me know if I shall open a separate ticket on this. Thank you!

Originally posted by @sharon558 in #25 (comment)

@cjw85
Copy link
Member Author

cjw85 commented Feb 19, 2019

@sharon558, I've moved this to a new issue.

I do not know for sure, but this might be due to overly longer cigar strings in the BAM (samtools/hts-specs#40). I'm going to download the dataset now and investigate.

@cjw85
Copy link
Member Author

cjw85 commented Feb 19, 2019

Updating medaka to use a newer version of htslib resolves this issue. A new prerelease is available: https://pypi.org/project/medaka/0.6.0a3/.

@sharon558
Copy link

Thank you @cjw85 ! I'll try the new release!

@sharon558
Copy link

It works now, but found another error. Will create a new ticket. Thanks!

@cjw85 cjw85 closed this as completed Feb 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants