gaoyubang / nanom6A

MIT License
19 stars 11 forks source link

The KeyError from predict_sites.py", line 277, in site2corrd #4

Closed q1134269149 closed 3 years ago

q1134269149 commented 3 years ago

Hi, When I ran the predict_sites.py for my data, I got the following error: """ Traceback (most recent call last): File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 546, in run_main() File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 496, in run_main site2corrd(basefl) File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 277, in site2corrd gpos,ref,gbase,genename=sites[ids][spos] KeyError: '697' """ To rule out the possibility of my data, I downloaded your article's dataset of poplar, and ran the predict_sites.py, I got the same error as follow: """ 3.m6A site to genome sites Traceback (most recent call last): File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 546, in run_main() File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 496, in run_main site2corrd(basefl) File "/home/softs/nanom6A_2021_2_6/predict_sites.py", line 277, in site2corrd gpos,ref,gbase,genename=sites[ids][spos] KeyError: '332' """ I try to deal this KeyError, however, I failed. Can you give me some advice? Thanks hqin

q1134269149 commented 3 years ago

After I tried to change the code of if mod>limit and ids in sites: ( line 277 in predict_sites.py) to if mod>limit and ids in sites and spos in sites[ids].keys():, this KeyError was solved, but I didn't know if it would affect the results. Thanks hqin

gaoyubang commented 3 years ago

i will check the error tomorrow

gaoyubang commented 3 years ago

This will not affect the results, this error occors because of the genome corrdinate of m6A site in reads was missing.
But can you test if run_binary.sh in nanom6A_2021_2_6.tar.gz with test data worked without error?

q1134269149 commented 3 years ago

Hi, Could you give me your email address for easy communication, please. Thanks hqin

gaoyubang commented 3 years ago

1489582340@qq.com

q1134269149 commented 3 years ago

Thanks. I've sent you an email, please check it, thank you hqin

gaoyubang commented 3 years ago

This bug has been solved.