schneebergerlab / msyd

MIT License
9 stars 0 forks source link

Feature request: Check for correct reference in input #4

Open mnshgl0110 opened 1 year ago

mnshgl0110 commented 1 year ago

I provided the following incorrect table as input:

chm13_mat.bam   chm13_matsyri.out
chm13_pat.bam   chm13_patsyri.out
mat_pat.bam mat_patsyri.out

which resulted in the following error:

pansyn.find_multisyn(syns, alns, only_core=True)
Traceback (most recent call last):
  File "/srv/netscratch/dep_mercier/grp_schneeberger/software/anaconda3_2021/envs/mgpy3.8/lib/python3.8/site-packages/IPython/core/interactiveshell.py", line 3398, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-15-4c7dca4baca4>", line 1, in <cell line: 1>
    pansyn.find_multisyn(syns, alns, only_core=True)
  File "pansyri/pyxfiles/pansyn.pyx", line 262, in pansyri.pansyn.find_multisyn
  File "pansyri/pyxfiles/pansyn.pyx", line 132, in pansyri.pansyn.find_overlaps
  File "pansyri/pyxfiles/util.pyx", line 85, in pansyri.util.get_orgs_from_df
TypeError: reduce() of empty sequence with no initial value

Pansyri should check that the input table: 1) Have same reference 2) The files are indeed alignment and syri output files

If the input file is incorrect then it should throw an informative error.