Hi, I'm writing a Galaxy wrapper for the GATK BaseRecalibrator tool and I'm running into this error where GATK thinks the directory of the BAM file is the index file for the BAM. I'm running
gatk BuildBamIndex -I input.bam --OUTPUT input.bai
before gatk BaseRecalibrator -I input.bam -R fasta.fa --known-sites known_sites.vcf.gz -O "$output1"
but the terminal outputs the warning
WARNING: BAM index file /home/ubuntu/galaxy/database/jobs_directory/000/482/working is older than BAM /home/ubuntu/galaxy/database/jobs_directory/000/482/working/input.bam
What should I do?
Odd. Can you just try
gatk BuildBamIndex -I input.bam
. That is all you need. The output file name will be automatically made.Oh this is
galaxy
so I guess you are not actually running this on command line?I'm running it on a local galaxy server, so I have access to the command line. I've tried using
gatk BuildBamIndex
andsamtools index
index on the input.bam, but gatk seems to think the file's directory is the index file. Is there a way to specify where the index file is for gatk?