Question: Error in vg : vg Assertion `reference_for.count(fasta_contig)' failed.
gravatar for g_nikiforos
14 months ago by
g_nikiforos0 wrote:

Hello people,

I am a master student in Bioinformatics and this is my first post in Biostars, so please be gentle. :)

I started using vg as part of a project I have for the university, and already got into troubles. I must say here, that i have never used vg before and I am just trying to make it work and learn more about it.

So, I downloaded the version 38 for the human reference genome along with common_all.vcf.gz in order to construct my graph. I created a index file for my VCF file and then i executed the following command:

vg construct -r Homo_sapiens.GRCh38.dna.alt.fa -v 00-common_all.vcf.gz >

It runs for a while, trying to create a index file for the reference genome and then it is crashing, giving the following error:

vg: src/constructor.cpp:2095: void vg::Constructor::construct_graph(const std::vector<FastaReference*>&, const std::vector<vcflib::VariantCallFile*>&, const std::vector<FastaReference*>&, std::function<void(vg:$id(vg::Graph&)>): Assertion `reference_for.count(fasta_contig)' failed

I tried with different reference genomes and different VCF files (00-All.vcf.gz) but again im getting the same error.

I would appreciate any help regarding this matter,

Thank you, Nikiforos

vgteam variation graph vg • 333 views
ADD COMMENTlink modified 13 months ago by Jouni Sirén130 • written 14 months ago by g_nikiforos0
gravatar for Jouni Sirén
13 months ago by
Jouni Sirén130
UCSC Genomics Institute
Jouni Sirén130 wrote:

Your VCF and reference files are probably using different contig names. If so, you can match them by adding options -n vcf_contig=fasta_contig (e.g. -n chr1=1 -n chr2=2) to the vg construct command.

ADD COMMENTlink written 13 months ago by Jouni Sirén130
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1432 users visited in the last hour