SEQanswers

Go Back   SEQanswers > Bioinformatics > Bioinformatics



Similar Threads
Thread Thread Starter Forum Replies Last Post
Empty sequence dictionary aquleaf Bioinformatics 2 01-14-2013 06:10 PM
Cuffmerge error: loading reference annotation failed? Kcornelius Bioinformatics 4 04-24-2012 03:01 PM
GATK error because of the order of reference chr. dkrtndhkd Bioinformatics 5 03-20-2012 07:34 AM
GATK and hg19 reference. kasthuri Bioinformatics 3 06-08-2011 12:46 PM
Tophat...Mapping reads against Reference with Bowtie [FAILED] Brajbio Bioinformatics 0 06-02-2010 12:33 AM

Reply
 
Thread Tools
Old 06-06-2012, 01:59 AM   #1
evonne16
Junior Member
 
Location: shanghai

Join Date: Nov 2011
Posts: 7
Default GATK: Failed to load reference dictionary

Hi,
When I use DepthOfCoverage of GATK, the error is 'Failed to load reference dictionary' .
I can't get why.
My command as below:
$java -jar GenomeAnalysisTK.jar \ -T DepthOfCoverage \ -R refall/allRef.fa \ -I mapping/DNAnew.sorted.bam \ -o mapping/dcDNA.targetCoverage

Thanks
evonne16 is offline   Reply With Quote
Old 06-06-2012, 05:19 AM   #2
Heisman
Senior Member
 
Location: St. Louis

Join Date: Dec 2010
Posts: 535
Default

Have you used that same reference dictionary for other commands with the GATK successfully?
Heisman is offline   Reply With Quote
Old 06-11-2012, 02:01 AM   #3
me_myself_andI
Member
 
Location: Singapore

Join Date: Nov 2010
Posts: 30
Default

I think you might have to create the dict file manually depending on the GATK version. I see this happening every now and then as well. The extra-complication is that if (my version of) GATK can't read the dict file it will also create an empty reference index file. What works for me is the following:

Before running GATK:

1. test if the reference index (refall/allRef.fa.fai in your case) exists and if it doesn't or if it's of size zero, recreate it with 'samtools faidx'.

2. Also test wether the reference dictionary exists (refall/allRef.fa.dict in your case) and if it doesn't or if it's of size zero recreate it with Picard's CreateSequenceDictionary.

Andreas

EDIT: As pointed out by dGho 'samtools index' was meant to be 'samtools faidx'

Last edited by me_myself_andI; 01-23-2014 at 04:35 PM. Reason: corrected mistake: use of wrong subcommand
me_myself_andI is offline   Reply With Quote
Old 07-09-2012, 10:10 AM   #4
wangli
Member
 
Location: Texas

Join Date: Apr 2012
Posts: 48
Default

Hi, Andreas

I would like to thank you for your very useful information here. I got my similar problem fixed according to your suggestions.
Actually, I have used the same dictionary for other commands of GATK successfully before. So, at first, i feel very confused why it can be used for some command but not others. Following your suggestion, I check my .dict and .fai files again, and i found their size is 0. Then i just deleted them. And type in my command. We donot need to use samtools or picard to generate these two files. The new version of GATK can generate itself. But i donot know why after running through a command, these two files turn to 0 size and we need to generate them again. That is weird. But my problem is solved. Thanks again!
wangli is offline   Reply With Quote
Old 01-23-2014, 09:24 AM   #5
dGho
Member
 
Location: Rochester, NY

Join Date: Jan 2013
Posts: 43
Default

Quote:
Originally Posted by me_myself_andI View Post
1. test if the reference index (refall/allRef.fa.fai in your case) exists and if it doesn't or if it's of size zero, recreate it with 'samtools index'.
Your comment was very useful, but just for reference or for future readers, I believe you meant the following command to create a ref index:

samtools faidx refall/allRef.fa
dGho is offline   Reply With Quote
Old 01-23-2014, 04:34 PM   #6
me_myself_andI
Member
 
Location: Singapore

Join Date: Nov 2010
Posts: 30
Default

Yes, that's right!
me_myself_andI is offline   Reply With Quote
Reply

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 03:08 AM.


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