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

KeyError on RNA-seq data #20

Open
simoncchu opened this issue Feb 21, 2021 · 2 comments
Open

KeyError on RNA-seq data #20

simoncchu opened this issue Feb 21, 2021 · 2 comments

Comments

@simoncchu
Copy link

Hey Daniel,

I met this error when try to run bamsnap on a rna-seq bam file:

Process proc 1:
Traceback (most recent call last):
  File "/home/cc439/anaconda3/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap
    self.run()
  File "/home/cc439/anaconda3/lib/python3.7/multiprocessing/process.py", line 99, in run
    self._target(*self._args, **self._kwargs)
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/bamsnap.py", line 436, in start_process_drawplot_bamlist
    imagefname = self.drawplot_bamlist(pos1, image_w, bamlist, xscale, refseq)
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/bamsnap.py", line 360, in drawplot_bamlist
    ia_sub = self.get_bamplot_image(bam, pos1, image_w, xscale, refseq)
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/bamsnap.py", line 257, in get_bamplot_image
    rset.calculate_readmap(is_strand_group=True)
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/drawreadset.py", line 301, in calculate_readmap
    r = DrawRead(a, self.refseq)
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/drawread.py", line 66, in __init__
    self.set_read_variant()
  File "/home/cc439/anaconda3/lib/python3.7/site-packages/bamsnap/drawread.py", line 126, in set_read_variant
    refbase = self.refseq[gp].upper()
KeyError: 32793279

Any suggestions on this? Thank you!

@Aikaterini-Chatzipli
Copy link

Hi Daniel,

I run into the same issue as Simon when running Bamsnap on RNA-seq bams. Thanks for developing Bamsnap, it's incredibly useful and easy to use for visualizing bams. Please let us know how it would be possible to tackle the KeyError.

Many thanks,

Katerina

@lparsons
Copy link

lparsons commented May 4, 2021

I too have the same issue, using RNA-Seq data. It is possible this is because of the large junctions in the middle of reads?

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