phasegenomics/FALCON-Phase

falcon-phase bamfilt segmentation fault on some OSs

peterdfields opened this issue · 6 comments

Hi,

I'm trying to run FALCON-Phase as part of the pb-assembly pipeline. I'm finding that in getting to the falcon-phase bamfilt step there is always a segmentation fault when running the binary built as part of bioconda and also built from a direct pull from github and built from source code if it is done on an Ubuntu system. I then tried the falcon-phase command on a CentOS machine and the command runs just fine. I figure this isn't really OS specific but something more basic associated with the build. However, both builds of the binaries from the FALCON-Phase repo finishes fine. Given what is mentioned in #34 , maybe you have some advice on how to trouble shoot this further? Are there particular details of my machines that would be useful to determine what's going wrong? Thank you for your time and advice.

zeeev commented

Hi @peterdfields,

Thank you for reminding me about this bug. I believe this issue is the same as #34. You should be able to run FP on Ubuntu, and furthermore segmentation faults are never appropriate. Do you think you could generate a core-dump file for me to investigate? I've listed the steps below. If you don't have time I'll try to recreate the issue on an amazon ec2 ubuntu instance.

  • Allow large core dumps: ulimit -c unlimited
  • Remove the falcon-phase binary
  • Change the makefile (
    CFLAG=-Wall -O3
    ) from CFLAG=-Wall -O3 to CFLAG=-Wall -g
  • Run make
  • Run the FP pipeline

You should get a core dump file that will allow me to find the spot in the code that is causing the problem. I think I should be able to resolve the bug today.

Thanks again for reaching out,

Zev

Hi Zev,

Thank you for your response. I followed the instructions on the Ubuntu machine. The generated core file can be accessed using the following link: https://www.dropbox.com/s/hm6t6itvmyg2bel/core

Please let me know if additional information would be useful. And thank you again for your help on this.

zeeev commented

Hi @peterdfields and @jnarayan81,

I think I've fixed the problem. If you'd be so kind, could you try the fix_bam_filt_empty_exclude_list branch? Just drop into the main directory and type:

git checkout fix_bam_filt_empty_exclude_list 
cd src 
make clean
make

Then try running the pipeline.

Best,

Zev

Hi Zev,

At least for running the direct running of the falcon-phase command the modifications you made seem to have made things work. Thank you! There does still seem to be an issue in the pb-assembly pipeline where for whatever reason the structure of the falcon-phase call is problematic. Specifically, instead of calling the bamfilt flag after falcon-phase it is being placed at the end of the command, after setting the output file name. I don't know if this behavior is different across OSs though, so maybe another issue should be created on the pb-assembly repo? In which case this issue can probably be closed. Thank you again for your assistance.

zeeev commented

Hi @peterdfields

You're seeing a print statement from the falcon-phase binary that isn't properly formatted. The command is being called correctly, but I need to change the print statement. In other words, it's just a printing error. It should be it's own bug, I'll open a bug report on it. It has no effect on the pipeline.
See bug #56.

Can I close out this issue?

Hi Zev,

I think it's possible it could be a deeper issue than just the print statement, or maybe I'm not following you here. What I mean is I replaced the bioconda installed version of falcon-phase with the version built from the fix_bam_filt_empty_exclude_list repo (I had tried this earlier with versions of falcon-phase built directly from the Falcon-Phase repo). I then re-ran fc_phase.py and the same error arose. I bypassed this issue by generating the touch file and placing the filtered bam file in the correct directory (not generating the touch file will just result in a blank filtered bam file, overwriting the previously generated filtered bam file outside the pb-assembly directory hierarchy). But I think isn't related to this issue, and so it can be closed. Thanks again.