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

AssertionError thrown during stitching #20

Closed
cjw85 opened this issue Jan 18, 2019 · 7 comments
Closed

AssertionError thrown during stitching #20

cjw85 opened this issue Jan 18, 2019 · 7 comments

Comments

@cjw85
Copy link
Member

cjw85 commented Jan 18, 2019

The process ran until

...
[03:05:22 - Stitch] Processing ctg254.
[03:05:29 - Stitch] Processing ctg255.
[03:05:36 - Stitch] Processing ctg256.
[03:05:47 - Stitch] Processing ctg257.
[03:05:59 - Stitch] Processing ctg258.
Traceback (most recent call last):
File "/usr/local/bioinfo/src/Medaka/medaka-1.4.3/venv/bin/medaka", line 11, in
load_entry_point('medaka==0.4.3', 'console_scripts', 'medaka')()
File "/usr/local/bioinfo/src/Medaka/medaka-1.4.3/venv/lib/python3.6/site-packages/medaka-0.4.3-py3.6-linux-x86_64.egg/medaka/medaka.py", line 170, in main
args.func(args)
File "/usr/local/bioinfo/src/Medaka/medaka-1.4.3/venv/lib/python3.6/site-packages/medaka-0.4.3-py3.6-linux-x86_64.egg/medaka/stitch.py", line 81, in stitch
joined = stitch_from_probs(args.inputs, regions=args.regions, model_yml=args.model_yml)
File "/usr/local/bioinfo/src/Medaka/medaka-1.4.3/venv/lib/python3.6/site-packages/medaka-0.4.3-py3.6-linux-x86_64.egg/medaka/stitch.py", line 62, in stitch_from_probs
end_1_ind, start_2_ind = get_sample_overlap(s1, s2)
File "/usr/local/bioinfo/src/Medaka/medaka-1.4.3/venv/lib/python3.6/site-packages/medaka-0.4.3-py3.6-linux-x86_64.egg/medaka/common.py", line 487, in get_sample_overlap
assert len(pos1_ovl) == len(pos2_ovl)
AssertionError

Originally posted by @chklopp in #16 (comment)

@cjw85
Copy link
Member Author

cjw85 commented Jan 23, 2019

Hi @chklopp

This is not something we have been able to reproduce, and it's not something for which we have been able to identify a possible cause. If you are willing to share your data we might be able to debug it further, we can do this privately if required.

Alternatively you can invoke the medaka stitch program on single contigs (avoiding the ones which are breaking with e.g.:

medaka stitch medaka/consensus_probs.hdf --regions ctg254 ctg255 ctg256 ctg257 ctg259 ...

The consensus_probs.hdf file will have been created by medaka_consensus

@txje
Copy link

txje commented Jan 26, 2019

I have one of these too and I'm happy to share if it will help debugging

@cjw85
Copy link
Member Author

cjw85 commented Jan 27, 2019

@txje

You should have received an email with details of how to send data to us.

@cjw85
Copy link
Member Author

cjw85 commented Jan 27, 2019

@txje

I've got your files and can reproduce the error. There is a corner-case in how contigs are broken into chunks for inference for which medaka stitch does not make allowance. There is a simple fix which will appear in the next release tomorrow.

@txje
Copy link

txje commented Jan 27, 2019

Thanks for looking into this!

@cjw85
Copy link
Member Author

cjw85 commented Jan 28, 2019

This is resolved in v0.5.0, now on pypi.

@Siadjeu
Copy link

Siadjeu commented Oct 1, 2019

Hi,

I have the same problem as mentioned above with the newest version of medaka v0.9.2 installed with conda:

[02:22:00 - Stitch] Processing tig00001220:0-.
[02:22:01 - Stitch] Processing tig00001224:0-.
[02:22:02 - Stitch] Processing tig00001233:0-.
Traceback (most recent call last):
File "/user/wupf2892/miniconda2/envs/medaka/bin/medaka", line 11, in
sys.exit(main())
File "/user/wupf2892/miniconda2/envs/medaka/lib/python3.6/site-packages/medaka/medaka.py", line 428, in main
args.func(args)
File "/user/wupf2892/miniconda2/envs/medaka/lib/python3.6/site-packages/medaka/stitch.py", line 116, in stitch
joined = stitch_from_probs(args.inputs, regions=args.regions)
File "/user/wupf2892/miniconda2/envs/medaka/lib/python3.6/site-packages/medaka/stitch.py", line 87, in stitch_from_probs
s1, s2)
File "/user/wupf2892/miniconda2/envs/medaka/lib/python3.6/site-packages/medaka/common.py", line 275, in overlap_indices
assert len(pos1_ovl) == len(pos2_ovl)
AssertionError
Failed to stitch consensus chunks.

I need help, thanks!

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

3 participants