Go Back   SEQanswers > Bioinformatics > Bioinformatics

Similar Threads
Thread Thread Starter Forum Replies Last Post
fastq-dump on SRA files harlock0083 Bioinformatics 14 10-18-2018 03:19 AM
fastq-dump error erikm Bioinformatics 10 03-24-2016 04:23 AM
fastq-dump for Illumina duygu Bioinformatics 3 08-03-2011 02:00 PM
Fastq-dump.exe Giles Bioinformatics 2 06-11-2011 12:34 PM
3.4GHz Quad-Core Intel Core i7 versus 3.1GHz Quad-Core Intel Core i5 brachysclereid Bioinformatics 2 05-03-2011 05:31 PM

Thread Tools
Old 07-05-2011, 08:07 AM   #1
Location: boston

Join Date: Jun 2011
Posts: 27
Default CNV core dump problem

HI I'm using CNVnator to do some CNV analysis but came across problems of core dump

Basically I first generated .root files from .bam files; then merged those small .root files into larger ones. See below:

  total 139G
        6.5G NA12878_10.root   3.7G NA12878_18.root   9.1G NA12878_4.root
         16K NA12878_1_1.root  2.8G NA12878_19.root   8.8G NA12878_5.root
        6.6G NA12878_11.root    11G NA12878_1.root    8.3G NA12878_6.root
        6.5G NA12878_12.root   3.1G NA12878_20.root   7.7G NA12878_7.root
        4.6G NA12878_13.root    16K NA12878_2_1.root  7.1G NA12878_8.root
        4.4G NA12878_14.root   1.8G NA12878_21.root   6.1G NA12878_9.root
        4.1G NA12878_15.root   1.8G NA12878_22.root   7.2G NA12878_X.root
        4.1G NA12878_16.root    11G NA12878_2.root    253M NA12878_Y.root
        4.0G NA12878_17.root   9.7G NA12878_3.root
This _1, _2, _3 ....represents chromosome number. The interesting here is, for NA12878_1.root and NA12878_2.root, the two largest files (11GB each), somehow two additional files are generated named as NA12878_1_1.root and NA12878_2_1.root (16K). I think this is core dump problem because core.* files are also generated (which I don't show here)

Is it because these two files are too large?

The part of the errors go like this:
And the werid error report about NA12878_1_1 and NA12878_2_1 and dumped core

Fill: Switching to new file: /home/xug/nearline/NA12878root/NA12878_2_1.root
    Filling and saving tree for 'chr19' ...
    *** glibc detected *** /home/xug/CNVnator/src/cnvnator: double free or corruption (out): 0xDone with the tree.
    ======= Backtrace: =========
    ======= Memory map: ========
    00400000-0043c000 r-xp 00000000 00:17 2189064480                         /home/xug/CNVnator/src/cnvnator
    0063c000-0063d000 rw-p 0003c000 00:17 2189064480                         /home/xug/CNVnator/src/cnvnator
    0063d000-00645000 rw-p 0063d000 00:00 0 
    19cd6000-1a29b000 rw-p 19cd6000 00:00 0 
    3a17a00000-3a17a1a000 r-xp 00000000 08:01 6864978                        /lib64/
    3a17c1a000-3a17c1b000 r--p 0001a000 08:01 6864978                        /lib64/
    3a17c1b000-3a17c1c000 rw-p 0001b000 08:01 6864978                        /lib64/
    3a17e00000-3a17f4a000 r-xp 00000000 08:01 6864988                        /lib64/
    3a17f4a000-3a1814a000 ---p 0014a000 08:01 6864988                        /lib64/
    3a1814a000-3a1814e000 r--p 0014a000 08:01 6864988                        /lib64/
I then used the generated .root files for further step like make histogram, there are errors (not surprisingly) but not only for NA12878_1 or _2, but also for others like _6
part of errors are shown below:
SysError in <TFile::Seek>: cannot seek to position -1857646445 in file NA12878_chr6.root, retpos=-1 (Invalid argument)
    Calculating histogram with bin size of 100 for chromosome 'chr6' ...
    Calculating histogram with bin size of 100 for chromosome 'chr5' ...
    Warning in <TFile::Init>: file NA12878_chr6.root probably not closed, cannot read free segments
    SysError in <TFile::Seek>: cannot seek to position -1857646445 in file NA12878_chr6.root, retpos=-1 (Invalid argument)
    Error in <TKey::Create>: Cannot allocate 60031 bytes for ID = his_rd_u_chr6_100 Title = Unique read depth for chr6
    Error in <TKey::Create>: Cannot allocate 2590048 bytes for ID = his_rd_p_chr6_100 Title =  read depth for chr6
    Making GC histogram for 'chr6' ...
    SysError in <TFile::Seek>: cannot seek to position -1857646445 in file NA12878_chr6.root, retpos=-1 (Invalid argument)
    Making GC histogram for 'chr5' ...

Anyone has encountered such problems? thx
CNVboy is offline   Reply With Quote
Old 06-21-2012, 10:16 AM   #2
Junior Member
Location: India

Join Date: Jun 2012
Posts: 3

I am trying to run CNVnator.The command I used is as follows:
cnvnator -root NA12878.root -chrom 1 2 3 4 5 6 7 8 9 10 -tree aln.bam
but it gives an error about bad allocation.I think there is some problem with the memory.

Parsing file aln.bam ...
Assuming BAM file for aln.bam
Allocating memory ...
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc

I am using an external hard drive with sufficiently large memory.Could anyone please tell me how to get rid of this error?
lambda3388 is offline   Reply With Quote
Old 02-26-2014, 06:59 PM   #3
Location: Singapore

Join Date: Nov 2011
Posts: 85

Hi guys,
i am sorry to revive this thread after long time but i also encountered this problem while trying to generate histograms on merged root file with CNVnator_0.3. Wrote to the author and awaiting reply.

However i was digging the net and found only this thread. But no info how to solve. So i started digging in the software. Seems that the problem is not in the ROOT package but CNVnator itself.
Why? Cos i found that for example the size of the genome is hardcoded:

from HisMaker.hh:
const static double GENOME_SIZE = 2.9e+9; // Excluding gaps

Another problems is that in Genome.cpp there are also hardcoded lengths of chromosomes for hg18 and hg19. Also there are only the standard chromosomes so is not the full hg18 or hg19. However even the sizes/lengths of the hg19 i have and the ones encoded in CNVnator differ. For example chr1:
CNVnator - 247249719
My hg19 - 249250621

So its not fun. The problem is i am not really C++ programmer so its kind of tough for me to figure out the whole procedure but i will try to solve that problem somehow. IF someone who is more proficient in C++ wants to help it will be really appreciated.

kenietz is offline   Reply With Quote


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

All times are GMT -8. The time now is 06:30 PM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Single Sign On provided by vBSSO