milkschen / leviosam2

Fast and accurate coordinate conversion between assemblies
MIT License
108 stars 17 forks source link

Possible bug in leviosam2.py #70

Open Heather1999 opened 8 months ago

Heather1999 commented 8 months ago

Hello, I ran with the leviosam.py with the following command: python leviosam2.py -t 23 -s ilmn_pe -a bwamem -i /home/user/ASC_v3/ori/AS_02N_sorted.bam -o AS_02N_lifted_new -O bam -C t2t2hg38.clft -f /home/user/GRCH38/hg38_1.fa -fi /home/user/GRCH38/hg38_1.fai --use_preset USE_PRESET

However, something went wrong, the followings are warnings showed:

[I::reconcile] Paired-end mode File 0: AS_02N_lifted_new-paired-deferred-sorted_n.bam (source) File 1: AS_02N_lifted_new-paired-realigned-sorted_n.bam (target) [W::reconcile] Num REF in AS_02N_lifted_new-paired-realigned-sorted_n.bam differs with AS_02N_lifted_new-paired-deferred-sorted_n.bam. Please check. Segmentation fault (core dumped) [2024-02-22 17:09:15 /home/user/CHM13/leviosam2.py:743 INFO] samtools merge -f -@ 23 -o AS_02N_lifted_new-final.bam AS_02N_lifted_new-paired-committed.bam AS_02N_lifted_new-paired-deferred-reconciled-sorted.bam && samtools index AS_02N_lifted_new-final.bam merge: invalid option -- 'o'

I guess I can manuallt fix the samtools issue but the Num REF issue seems harder to address. Could you kindly provide some insights? Thank you!

milkschen commented 8 months ago

Could you share the number of reads in each intermediate BAM with me?

The intermediate files can be kept using the --keep_tmp_files flag in the Python workflow.

Heather1999 commented 8 months ago

Thank you for your response! I solved it after switching to the fna file provided in the case study workflow. however samtools merge does not require -o to specify output file, so just one modification to do to the python workflow file:)