BCF file compatability with Picard tools

nemeshnemesh BroadMember

I was wondering if Picard tools are compatible with both compressed and uncompressed BCF files?

When I generate an uncompressed BCF file using Picard's tool, everything works OK:
java -jar /path/to/picard.jar VcfFormatConverter I=input.vcf.gz O=output.bcf

Here's a random program to test with:
java -jar /path/to/picard/picard.jar SortVcf I=output.bcf O=test.bcf

When I generate a BCF file using bcftools that is compressed, I'm unable to read the file:
bcftools view -Ob -o output.bcf input.vcf.gz

java -jar /path/to/picard/picard.jar SortVcf I=output.bcf O=test.bcf

Exception in thread "main" htsjdk.tribble.TribbleException$MalformedFeatureFile: Unable to parse header with error: Input stream does not contain a BCF encoded file; BCF magic header info not found, at record 0 with position 0:, for input source: /downloads/Snap48p5/bcftools_try/141_HESC_Genome.biallelic.ref_norm.1KG_AF.bcf
at htsjdk.tribble.TribbleIndexedFeatureReader.readHeader(TribbleIndexedFeatureReader.java:253)
at htsjdk.tribble.TribbleIndexedFeatureReader.(TribbleIndexedFeatureReader.java:101)
at htsjdk.tribble.TribbleIndexedFeatureReader.(TribbleIndexedFeatureReader.java:126)
at htsjdk.tribble.AbstractFeatureReader.getFeatureReader(AbstractFeatureReader.java:110)
at htsjdk.tribble.AbstractFeatureReader.getFeatureReader(AbstractFeatureReader.java:74)
at htsjdk.variant.vcf.VCFFileReader.(VCFFileReader.java:58)

Are only uncompressed BCF files supported by HTSJDK?

Issue · Github
by Sheila

Issue Number
3029
State
open
Last Updated
Assignee
Array

Answers

Sign In or Register to comment.