shawnzhangyx / PePr

a peak-calling and differential analysis tool for replicated ChIP-Seq data
GNU General Public License v3.0
37 stars 9 forks source link

Help needed #29

Closed joshuabhk closed 7 years ago

joshuabhk commented 7 years ago

Hi Shawn.

Thank you for your nice program. I got the below error message while I was running my samples using PePr (ver. 1.1.18). By looking at the code and error message above, I assume it is caused by the missing chrY alignments in the input. I check the BAM header of input and it had "chrY".

Can you fix the code so that the this problem goes away? Or suggest to me any work around?

.... 40,000,000 lines processed in bam/input.sorted.bam Traceback (most recent call last): File "/usr/local/Anaconda/envs_app/PePr/1.1.18/bin/PePr", line 11, in sys.exit(argless_main()) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/PePr.py", line 27, in argless_main main(sys.argv) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/PePr.py", line 42, in main read_dict = prepareData.prepare_data(parameter) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/prepareData.py", line 264, in prepare_data read_dict = prepare_data_diff_binding(parameter) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/prepareData.py", line 242, in prepare_data_diff_binding input2_array[chr] = parameter.array_dict[filename][chr] KeyError: 'chrY'

Best,

Bong-Hyun

shawnzhangyx commented 7 years ago

Hi Bong-Hyun,

Could you paste your command here? It will help me see what might go wrong.

Best, Shawn

joshuabhk commented 7 years ago

Sure. Here is the full command line arguments and the message from PePr. Thank you so much!

Command line:

PePr --diff -f bam -c bam/EZH2_1.sorted.bam,bam/EZH2_2.sorted.bam --chip2 bam/PRMT5_1.sorted.bam,bam/PRMT5_2.sorted.bam -i bam/input.sorted.bam --input2 bam/input.sorted.bam -n EZH_vs_PRMT --output-directory PePr

Message from the run:

INFO root 08/18/2017 11:02:42 AM | getting chromosome info Warning: The index file is older than the data file: bam/EZH2_1.sorted.bam.bai INFO root 08/18/2017 11:05:10 AM | Found chrY:59363276 | chrX:155260385 | chr13:115108105 | chr12:133839375 | chr11:134945664 | chr10:135524699 | chr17:81195078 | chr16:90294670 | chr15:102521174 | chr14:107289468 | chr19:59118878 | chr18:78017063 | chr22:51244497 | chr20:62965075 | chr21:48119868 | chr7:159128032 | chr6:171054609 | chr5:180903353 | chr4:191025425 | chr3:197962288 | chr2:243189294 | chr1:249240418 | chr9:141153341 | chr8:146301775 Warning: The index file is older than the data file: bam/EZH2_1.sorted.bam.bai Warning: The index file is older than the data file: bam/EZH2_2.sorted.bam.bai Warning: The index file is older than the data file: bam/PRMT5_1.sorted.bam.bai Warning: The index file is older than the data file: bam/PRMT5_2.sorted.bam.bai Warning: The index file is older than the data file: bam/input.sorted.bam.bai Warning: The index file is older than the data file: bam/input.sorted.bam.bai INFO root 08/18/2017 11:05:11 AM | Read length: 75|75|74|74|74 INFO root 08/18/2017 11:05:11 AM | begin estimating window size Warning: The index file is older than the data file: bam/EZH2_1.sorted.bam.bai INFO root 08/18/2017 11:11:35 AM | Estimated window size is 800 INFO root 08/18/2017 11:11:35 AM | estimating the shift size for bam/EZH2_1.sorted.bam Warning: The index file is older than the data file: bam/EZH2_1.sorted.bam.bai INFO root 08/18/2017 11:18:20 AM | The shift size for bam/EZH2_1.sorted.bam is 93 INFO root 08/18/2017 11:18:20 AM | estimating the shift size for bam/EZH2_2.sorted.bam Warning: The index file is older than the data file: bam/EZH2_2.sorted.bam.bai INFO root 08/18/2017 11:24:51 AM | The shift size for bam/EZH2_2.sorted.bam is 98 INFO root 08/18/2017 11:24:51 AM | estimating the shift size for bam/PRMT5_1.sorted.bam Warning: The index file is older than the data file: bam/PRMT5_1.sorted.bam.bai INFO root 08/18/2017 11:30:51 AM | The shift size for bam/PRMT5_1.sorted.bam is 107 INFO root 08/18/2017 11:30:51 AM | estimating the shift size for bam/PRMT5_2.sorted.bam Warning: The index file is older than the data file: bam/PRMT5_2.sorted.bam.bai INFO root 08/18/2017 11:37:10 AM | The shift size for bam/PRMT5_2.sorted.bam is 107 INFO root 08/18/2017 11:37:10 AM | calculating normalization constants Warning: The index file is older than the data file: bam/input.sorted.bam.bai Warning: The index file is older than the data file: bam/input.sorted.bam.bai INFO root 08/18/2017 11:40:53 AM | printing running parameters: INFO root 08/18/2017 11:40:53 AM | processing bam/EZH2_1.sorted.bam Warning: The index file is older than the data file: bam/EZH2_1.sorted.bam.bai INFO root 08/18/2017 11:44:27 AM | processing bam/EZH2_2.sorted.bam Warning: The index file is older than the data file: bam/EZH2_2.sorted.bam.bai INFO root 08/18/2017 11:48:19 AM | processing bam/PRMT5_1.sorted.bam Warning: The index file is older than the data file: bam/PRMT5_1.sorted.bam.bai INFO root 08/18/2017 11:52:08 AM | processing bam/PRMT5_2.sorted.bam Warning: The index file is older than the data file: bam/PRMT5_2.sorted.bam.bai INFO root 08/18/2017 11:56:03 AM | processing bam/input.sorted.bam Warning: The index file is older than the data file: bam/input.sorted.bam.bai INFO root 08/18/2017 11:58:09 AM | processing bam/input.sorted.bam Warning: The index file is older than the data file: bam/input.sorted.bam.bai INFO root 08/18/2017 12:00:17 PM | Begin differential binding analysis 10,000,000 lines processed in bam/EZH2_1.sorted.bam 20,000,000 lines processed in bam/EZH2_1.sorted.bam 30,000,000 lines processed in bam/EZH2_1.sorted.bam 40,000,000 lines processed in bam/EZH2_1.sorted.bam 50,000,000 lines processed in bam/EZH2_1.sorted.bam 60,000,000 lines processed in bam/EZH2_1.sorted.bam 70,000,000 lines processed in bam/EZH2_1.sorted.bam 10,000,000 lines processed in bam/EZH2_1.sorted.bam 20,000,000 lines processed in bam/EZH2_1.sorted.bam 30,000,000 lines processed in bam/EZH2_1.sorted.bam 40,000,000 lines processed in bam/EZH2_1.sorted.bam 50,000,000 lines processed in bam/EZH2_1.sorted.bam 60,000,000 lines processed in bam/EZH2_1.sorted.bam 70,000,000 lines processed in bam/EZH2_1.sorted.bam 10,000,000 lines processed in bam/EZH2_1.sorted.bam 20,000,000 lines processed in bam/EZH2_1.sorted.bam 30,000,000 lines processed in bam/EZH2_1.sorted.bam 40,000,000 lines processed in bam/EZH2_1.sorted.bam 50,000,000 lines processed in bam/EZH2_1.sorted.bam 60,000,000 lines processed in bam/EZH2_1.sorted.bam 70,000,000 lines processed in bam/EZH2_1.sorted.bam 10,000,000 lines processed in bam/EZH2_2.sorted.bam 20,000,000 lines processed in bam/EZH2_2.sorted.bam 30,000,000 lines processed in bam/EZH2_2.sorted.bam 40,000,000 lines processed in bam/EZH2_2.sorted.bam 50,000,000 lines processed in bam/EZH2_2.sorted.bam 60,000,000 lines processed in bam/EZH2_2.sorted.bam 70,000,000 lines processed in bam/EZH2_2.sorted.bam 80,000,000 lines processed in bam/EZH2_2.sorted.bam 10,000,000 lines processed in bam/PRMT5_1.sorted.bam 20,000,000 lines processed in bam/PRMT5_1.sorted.bam 30,000,000 lines processed in bam/PRMT5_1.sorted.bam 40,000,000 lines processed in bam/PRMT5_1.sorted.bam 50,000,000 lines processed in bam/PRMT5_1.sorted.bam 60,000,000 lines processed in bam/PRMT5_1.sorted.bam 70,000,000 lines processed in bam/PRMT5_1.sorted.bam 10,000,000 lines processed in bam/PRMT5_2.sorted.bam 20,000,000 lines processed in bam/PRMT5_2.sorted.bam 30,000,000 lines processed in bam/PRMT5_2.sorted.bam 40,000,000 lines processed in bam/PRMT5_2.sorted.bam 50,000,000 lines processed in bam/PRMT5_2.sorted.bam 60,000,000 lines processed in bam/PRMT5_2.sorted.bam 70,000,000 lines processed in bam/PRMT5_2.sorted.bam 80,000,000 lines processed in bam/PRMT5_2.sorted.bam 10,000,000 lines processed in bam/input.sorted.bam 20,000,000 lines processed in bam/input.sorted.bam 30,000,000 lines processed in bam/input.sorted.bam 40,000,000 lines processed in bam/input.sorted.bam 10,000,000 lines processed in bam/input.sorted.bam 20,000,000 lines processed in bam/input.sorted.bam 30,000,000 lines processed in bam/input.sorted.bam 40,000,000 lines processed in bam/input.sorted.bam

filetype filename shift_size normalization_factor

chip1 bam/EZH2_1.sorted.bam 93 1.09010508755 chip1 bam/EZH2_2.sorted.bam 98 1.06321462168 chip2 bam/PRMT5_1.sorted.bam 107 0.944414539446 chip2 bam/PRMT5_2.sorted.bam 107 0.933471172736 input1 bam/input.sorted.bam 107 1.40137095196 input2 bam/input.sorted.bam 107 1.40137095196 file-format bam peaktype broad windowsize 800 difftest True threshold 1e-05 normalization inter-group output-directory PePr/ name EZH_vs_PRMT num-processors 1

10,000,000 lines processed in bam/EZH2_1.sorted.bam 20,000,000 lines processed in bam/EZH2_1.sorted.bam 30,000,000 lines processed in bam/EZH2_1.sorted.bam 40,000,000 lines processed in bam/EZH2_1.sorted.bam 50,000,000 lines processed in bam/EZH2_1.sorted.bam 60,000,000 lines processed in bam/EZH2_1.sorted.bam 70,000,000 lines processed in bam/EZH2_1.sorted.bam 10,000,000 lines processed in bam/EZH2_2.sorted.bam 20,000,000 lines processed in bam/EZH2_2.sorted.bam 30,000,000 lines processed in bam/EZH2_2.sorted.bam 40,000,000 lines processed in bam/EZH2_2.sorted.bam 50,000,000 lines processed in bam/EZH2_2.sorted.bam 60,000,000 lines processed in bam/EZH2_2.sorted.bam 70,000,000 lines processed in bam/EZH2_2.sorted.bam 80,000,000 lines processed in bam/EZH2_2.sorted.bam 10,000,000 lines processed in bam/PRMT5_1.sorted.bam 20,000,000 lines processed in bam/PRMT5_1.sorted.bam 30,000,000 lines processed in bam/PRMT5_1.sorted.bam 40,000,000 lines processed in bam/PRMT5_1.sorted.bam 50,000,000 lines processed in bam/PRMT5_1.sorted.bam 60,000,000 lines processed in bam/PRMT5_1.sorted.bam 70,000,000 lines processed in bam/PRMT5_1.sorted.bam 10,000,000 lines processed in bam/PRMT5_2.sorted.bam 20,000,000 lines processed in bam/PRMT5_2.sorted.bam 30,000,000 lines processed in bam/PRMT5_2.sorted.bam 40,000,000 lines processed in bam/PRMT5_2.sorted.bam 50,000,000 lines processed in bam/PRMT5_2.sorted.bam 60,000,000 lines processed in bam/PRMT5_2.sorted.bam 70,000,000 lines processed in bam/PRMT5_2.sorted.bam 80,000,000 lines processed in bam/PRMT5_2.sorted.bam 10,000,000 lines processed in bam/input.sorted.bam 20,000,000 lines processed in bam/input.sorted.bam 30,000,000 lines processed in bam/input.sorted.bam 40,000,000 lines processed in bam/input.sorted.bam 10,000,000 lines processed in bam/input.sorted.bam 20,000,000 lines processed in bam/input.sorted.bam 30,000,000 lines processed in bam/input.sorted.bam 40,000,000 lines processed in bam/input.sorted.bam Traceback (most recent call last): File "/usr/local/Anaconda/envs_app/PePr/1.1.18/bin/PePr", line 11, in

sys.exit(argless_main()) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/PePr.py", line 27, in argless_main main(sys.argv) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/PePr.py", line 42, in main read_dict = prepareData.prepare_data(parameter) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/prepareData.py", line 264, in prepare_data read_dict = prepare_data_diff_binding(parameter) File "/usr/local/Anaconda/envs_app/PePr/1.1.18/lib/python2.7/site-packages/PePr/prepareData.py", line 242, in prepare_data_diff_binding input2_array[chr] = parameter.array_dict[filename][chr] KeyError: 'chrY' On Fri, Aug 18, 2017 at 3:31 PM shawn wrote: > Hi Bong-Hyun, > > Could you paste your command here? It will help me see what might go wrong. > > Best, > Shawn > > — > You are receiving this because you authored the thread. > Reply to this email directly, view it on GitHub > , > or mute the thread > > . >
shawnzhangyx commented 7 years ago

Okay I got it. Thanks! This problem has been fixed in 1.1.19 or later. Would you be able to update to the latest version?

joshuabhk commented 7 years ago

I see. I am testing 1.1.20 right now and the program is still running. I will let you know if the problem persists in the newer version. Thank you very much!

Bong-Hyun

On Fri, Aug 18, 2017, 3:52 PM shawn notifications@github.com wrote:

Okay I got it. Thanks! This problem has been fixed in 1.1.19 or later. Would you be able to update to the latest version?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/shawnzhangyx/PePr/issues/29#issuecomment-323446162, or mute the thread https://github.com/notifications/unsubscribe-auth/AGkVDKGlJftUXAyT8ytYVH-cwpnQhBLWks5sZetxgaJpZM4O76yC .

shawnzhangyx commented 7 years ago

Sure no problem. Let me know if you're still having the same issue.

joshuabhk commented 7 years ago

The error is gone in the newer version! Thank you so much!

Bong-Hyun

On Fri, Aug 18, 2017, 4:20 PM shawn notifications@github.com wrote:

Sure no problem. Let me know if you're still having the same issue.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/shawnzhangyx/PePr/issues/29#issuecomment-323451829, or mute the thread https://github.com/notifications/unsubscribe-auth/AGkVDJZ6RFCg-2S2UahrtUiQxtru_yIeks5sZfIXgaJpZM4O76yC .

shawnzhangyx commented 7 years ago

You're welcome. Closing the issue now.