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

Failed to find alternate path #293

Open
mbhall88 opened this issue Jul 15, 2022 · 4 comments
Open

Failed to find alternate path #293

mbhall88 opened this issue Jul 15, 2022 · 4 comments

Comments

@mbhall88
Copy link
Member

mbhall88 commented Jul 15, 2022

https://github.com/rmcolq/pandora/blob/565c1572f2c535db20c45062d359055d04a7659a/src/localPRG.cpp#L1406-L1407

I've triggered this error and don't really know why/how? Any suggestions on how to get to the bottom of this @leoisl?

I have created a minimal dataset to reproduce this in /hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map

Inside that directory, if you run pandora (v0.9.1 prebuilt binary - /hps/nobackup/iqbal/mbhall/drprg/src/ext/pandora) like so, you will get the error

cd /hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map
/hps/nobackup/iqbal/mbhall/drprg/src/ext/pandora map -k 15 -w 15 --genotype -v -o . -g 4.4m --vcf-refs gyrA.fa -t 1 gyrA.prg mada_118.sub.fq.gz

And the log

[2022-07-15 05:17:04.163752] [0x0000000000e32940] [info]    Loading Index and LocalPRGs from file...
[2022-07-15 05:17:04.163765] [0x0000000000e32940] [debug]   Loading index
[2022-07-15 05:17:04.163771] [0x0000000000e32940] [debug]   File is "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/gyrA.prg.k15.w15.idx"
[2022-07-15 05:17:04.166459] [0x0000000000e32940] [debug]   Finished loading file. Index now contains 472 entries
[2022-07-15 05:17:04.166468] [0x0000000000e32940] [debug]   Loading PRGs from file "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/gyrA.prg"
[2022-07-15 05:17:04.169743] [0x0000000000e32940] [debug]   Number of LocalPRGs read: 1
[2022-07-15 05:17:04.169751] [0x0000000000e32940] [debug]   Loading kmer_prgs from files
[2022-07-15 05:17:04.178086] [0x0000000000e32940] [info]    Constructing pangenome::Graph from read file (this will take a while)...
[2022-07-15 05:17:12.736064] [0x0000000000e32940] [info]    Processed 23726 reads
[2022-07-15 05:17:12.736083] [0x0000000000e32940] [debug]   Pangraph has 1 nodes
[2022-07-15 05:17:12.736086] [0x0000000000e32940] [debug]   Estimated coverage: 20
[2022-07-15 05:17:12.736110] [0x0000000000e32940] [info]    Writing pangenome::Graph to file "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/./pandora.pangraph.gfa"
[2022-07-15 05:17:12.742746] [0x0000000000e32940] [debug]   added node 0
[2022-07-15 05:17:12.744506] [0x0000000000e32940] [info]    Updating local PRGs with hits...
[2022-07-15 05:17:12.744926] [0x0000000000e32940] [debug]   Added 1645 hits in the forward direction and 2216 hits in the reverse
[2022-07-15 05:17:12.744931] [0x0000000000e32940] [info]    Estimating parameters for kmer graph model...
[2022-07-15 05:17:12.744940] [0x0000000000e32940] [info]    Collect kmer coverage distribution
[2022-07-15 05:17:12.744973] [0x0000000000e32940] [info]    Writing kmer coverage distribution to "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/./kmer_covgs.txt"
[2022-07-15 05:17:12.751193] [0x0000000000e32940] [debug]   Found mean 10.9093
[2022-07-15 05:17:12.751202] [0x0000000000e32940] [debug]   Found variance 13.7255
[2022-07-15 05:17:12.751207] [0x0000000000e32940] [debug]   mean, var: 10.9093, 13.7255
[2022-07-15 05:17:12.751210] [0x0000000000e32940] [debug]   nb reads, covg31, 20
[2022-07-15 05:17:12.751216] [0x0000000000e32940] [debug]   Negative binomial parameters p: 0.794824 and r: 42.2613
[2022-07-15 05:17:12.751220] [0x0000000000e32940] [info]    Collect kmer probability distribution
[2022-07-15 05:17:12.751648] [0x0000000000e32940] [info]    Writing kmer probability distribution to "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/./kmer_probs.txt"
[2022-07-15 05:17:12.755291] [0x0000000000e32940] [info]    Did not find enough non-zero coverage kmers to estimated threshold for true kmers. Use the naive threshold -9
[2022-07-15 05:17:12.755298] [0x0000000000e32940] [info]    Find PRG paths and write to files...
[2022-07-15 05:17:12.755306] [0x0000000000e32940] [info]    Loading VCF refs from file "/hps/nobackup/iqbal/mbhall/drprg/paper/results/drprg/wk_sweep/predict/w15/k15/nanopore/mada_118/tmp_map/gyrA.fa"
[2022-07-15 05:17:12.755767] [0x0000000000e32940] [debug]   Find maxpath for gyrA
[2022-07-15 05:17:12.755879] [0x0000000000e32940] [debug]   Found non-zero coverage in kmer graph
[2022-07-15 05:17:12.756739] [0x0000000000e32940] [debug]   Convert kmernode path to localnode path
[2022-07-15 05:17:12.756948] [0x0000000000e32940] [debug]   Found global coverage 20 and path mode 13 and mean 11
[2022-07-15 05:17:12.757169] [0x0000000000e32940] [debug]   have 1 candidates
[2022-07-15 05:17:12.757178] [0x0000000000e32940] [debug]   Build VCF for prg gyrA
[2022-07-15 05:17:12.757231] [0x0000000000e32940] [debug]   Update VCF with sample path
[2022-07-15 05:17:12.757272] [0x0000000000e32940] [debug]   Update VCF with sample covgs
terminate called after throwing an instance of 'FatalRuntimeError'
  what():  [FATAL ERROR]: Error finding alternative path: no alternative paths were found but we should have found at least one
Aborting...

DEBUG info (for developers, provide this if opening an issue):
Stack trace (most recent call last):
#11   Object "[0x42869d]", at 0x42869d, in
#10   Object "[0xaf6f7f]", at 0xaf6f7f, in
#9    Object "[0x4238ff]", at 0x4238ff, in
#8    Object "[0x51180f]", at 0x51180f, in
#7    Object "[0x504882]", at 0x504882, in
#6    Object "[0x5165ca]", at 0x5165ca, in
#5    Object "[0xadb965]", at 0xadb965, in
#4    Object "[0x514f31]", at 0x514f31, in
#3    Object "[0x4dda54]", at 0x4dda54, in
#2    Object "[0x4dcd43]", at 0x4dcd43, in
#1    Object "[0x4d944f]", at 0x4d944f, in
#0    Object "[0x4f1817]", at 0x4f1817, in

Stack trace (most recent call last):
#16   Object "[0x42869d]", at 0x42869d, in
#15   Object "[0xaf6f7f]", at 0xaf6f7f, in
#14   Object "[0x4238ff]", at 0x4238ff, in
#13   Object "[0x51180f]", at 0x51180f, in
#12   Object "[0x504882]", at 0x504882, in
#11   Object "[0x5165ca]", at 0x5165ca, in
#10   Object "[0xadb965]", at 0xadb965, in
#9    Object "[0x514f31]", at 0x514f31, in
#8    Object "[0x4089d2]", at 0x4089d2, in
#7    Object "[0xaf4979]", at 0xaf4979, in
#6    Object "[0xaf3f8a]", at 0xaf3f8a, in
#5    Object "[0xa2fd43]", at 0xa2fd43, in
#4    Object "[0xad0418]", at 0xad0418, in
#3    Object "[0xa3009b]", at 0xa3009b, in
#2    Object "[0x41f232]", at 0x41f232, in
#1    Object "[0x421c00]", at 0x421c00, in
#0    Object "[0x435b0b]", at 0x435b0b, in
Aborted (Signal sent by tkill() 1061390 7196)

Sorry I would try and debug myself but I am struggling to build pandora at the moment - something to do with SeqAn.

@leoisl
Copy link
Collaborator

leoisl commented Jul 23, 2022

Hey, sorry for the delay. I will try to take a look at this next week. Thanks for the bug report with a MWE, helps a lot!

@leoisl
Copy link
Collaborator

leoisl commented Jul 23, 2022

I am still off pandora, but will return to it soon

@leoisl
Copy link
Collaborator

leoisl commented Jan 12, 2023

Is this still relevant @mbhall88 ?

@mbhall88
Copy link
Member Author

mbhall88 commented Jan 12, 2023

Maybe, but it isn't blocking me (it only happened at a certain w and k value and I'm not using those w/k values currently)

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