r3fang / SnapATAC

Analysis Pipeline for Single Cell ATAC-seq
GNU General Public License v3.0
296 stars 125 forks source link

failed to read alignments from BAM #247

Open kunalkathuria opened 2 years ago

kunalkathuria commented 2 years ago

Hi,

I got the following error while trying to run snaptools after following all previous steps ending with name-sorting the snap.bam:

(This was after the first try where the BAM file was missing an EOF marker, causing snap-pre to exit, so I added the marker manually and ran the command below)

snaptools snap-pre --input-file=atac_v1_adult_brain_fresh_5k.snap.nsrt.bam --output-snap=atac_v1_adult_brain_fresh_5k.snap --genome-name=mm10 --genome-size=Nofile --min-mapq=30 --min-flen=50 --max-flen=1000 --keep-chrm=TRUE --keep-single=FALSE --keep-secondary=False --overwrite=True --max-num=20000 --min-cov=500 --verbose=True

error: failed to read alingment info from bam file

I checked the BAM file, and it certainly has reads.

I had also tried running the uncompressed version of the BAM file earlier, and got the same error.

Any help appreciated! Thank you!

Best,

Kunal

priscilla-glenn commented 1 year ago

Hi, I also have a question on Step 4. Pre-processing (snaptools). I followed steps 1-3 with my demultiplexed 10x files, and when I run snap-pre, I get the output: [E::idx_find_and_load] Could not retrieve index file for 'Mouse_S1.bam'

Was I missing a step?

Here is my code:

naptools snap-pre --input-file=Mouse_S1.bam --output-snap=Mouse_S1.snap --genome-name=mm10 --genome-size=Mouse_chr_sizes_simple --min-mapq=30 --min-flen=0 --max-flen=1000 --keep-chrm=TRUE --keep-single=FALSE --keep-secondary=FALSE --overwrite=TRUE --min-cov=100 --verbose=TRUE

Thank you! Priscilla

SammiLyu commented 5 months ago

Hi,

I am attempting snaptools to generate a snap file from cellranger output as well and run into the same issue. Anybody knows how this can be fixed? Really appreciate it!

Sammi