Error loading BAM file header

400 views
Skip to first unread message

Mar

unread,
Mar 10, 2017, 7:20:51 AM3/10/17
to igv-help
IGV version 2.3.90 (143)

When I try to load my bam file into IGV (the reference genome being already loaded), i get the following error:
            
                 Error loading SAM header: Sequence lengths > 2^29-1 are not supported

My reference chromosome genome (with wich the alignment was originally generated)  is 779mb, does this mean that my index is too long for display?

P.s. the bam file was sorted and indexed (both in .bai and .csi format) using samtools:
samtools sort SNP.alignment.bam SNP.alignment.sorted
samtools index SNP.alignment.sorted (or samtools index -c for .csi)

Thanks in advance!

Mar

unread,
Mar 10, 2017, 7:28:27 AM3/10/17
to igv-help
I attach the igv.log
igv.log

James Robinson

unread,
Mar 10, 2017, 12:19:08 PM3/10/17
to igv-help
Yes, that's what it means.    Do you know of any tools that can query this file?    The limitation is imposed by the BAM index format  (see here (page 13):  https://samtools.github.io/hts-specs/SAMv1.pdf.     If you know of a tool that can successfully read and query this file in regions > 2^29  please let me know.   It's a known limitation of the BAM format.

--

---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/bf52c0a5-0998-4d6e-88bc-3e0e26f65892%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Message has been deleted

Jim Robinson

unread,
Mar 10, 2017, 12:30:19 PM3/10/17
to igv-help
I should clarify that my comment applies to the BAM index  (.bai) file.   IGV depends on the htsjdk and does not currently support the .csi file.   This is on my to-do list.

Mar

unread,
Mar 10, 2017, 12:54:57 PM3/10/17
to igv-help
I ended up visualizing it on CLC, which is fine for my specific purpose (just locating the interval spanned by the reads). But nut sure if it can fit everyone's needs (plus it's not free!).

I tried other software (e.g. IGB and BamView) but it wasn't working. Not sure if it was for my lack of expertise though. 

Il giorno venerdì 10 marzo 2017 17:19:08 UTC, Jim Robinson ha scritto:
Yes, that's what it means.    Do you know of any tools that can query this file?    The limitation is imposed by the BAM index format  (see here (page 13):  https://samtools.github.io/hts-specs/SAMv1.pdf.     If you know of a tool that can successfully read and query this file in regions > 2^29  please let me know.   It's a known limitation of the BAM format.
On Fri, Mar 10, 2017 at 4:28 AM, Mar <mara....@gmail.com> wrote:
I attach the igv.log

Il giorno venerdì 10 marzo 2017 12:20:51 UTC, Mar ha scritto:
IGV version 2.3.90 (143)

When I try to load my bam file into IGV (the reference genome being already loaded), i get the following error:
            
                 Error loading SAM header: Sequence lengths > 2^29-1 are not supported

My reference chromosome genome (with wich the alignment was originally generated)  is 779mb, does this mean that my index is too long for display?

P.s. the bam file was sorted and indexed (both in .bai and .csi format) using samtools:
samtools sort SNP.alignment.bam SNP.alignment.sorted
samtools index SNP.alignment.sorted (or samtools index -c for .csi)

Thanks in advance!

--

---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+u...@googlegroups.com.

James Robinson

unread,
Mar 10, 2017, 12:57:44 PM3/10/17
to igv-help
IGB almost certainly relies on the same library (htsjdk) as IGV.   I'm not sure about BamView but suspect it does as well.


To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/a3b512bd-8c57-45b2-bc7b-c5623c3ccd67%40googlegroups.com.

Janet Young

unread,
Jun 7, 2017, 5:17:49 PM6/7/17
to igv-help
I'd also like to request adding support for bigger chromosomes, if possible.  I'm trying to look at bam files for RNAseq mapped to the opossum monDom5 assembly, but chr1 and chr2 exceed that length threshold. I can still look at genes on other chromosomes, though, if I just ignore the errors on loading the bam files - that's good!

thanks,

Janet

------------------------------------------------------------------- 

Dr. Janet Young 

Malik lab

Division of Basic Sciences
Fred Hutchinson Cancer Research Center
1100 Fairview Avenue N., A2-025, 
P.O. Box 19024, Seattle, WA 98109-1024, USA.

email: jayoung  ...at...  fredhutch.org

------------------------------------------------------------------- 

James Robinson

unread,
Jun 7, 2017, 5:42:39 PM6/7/17
to igv-help
Noted,  supporting this is difficult until the htsjdk does so.   If possible enter an issue on their git forum.

Jim


To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/363641b0-6d0d-42b7-b383-eb947193229d%40googlegroups.com.

Janet Young

unread,
Jun 15, 2017, 1:59:44 PM6/15/17
to igv-help
done -  https://github.com/samtools/htsjdk/issues/900 

thanks, Jim. hope someone picks it up.

Janet

Reply all
Reply to author
Forward
0 new messages