Open vetsuisse-unibe opened 3 weeks ago
You need to use -a
with vg validate
:
vg validate bd2.gbz -a BD016.hifi.gam
Thank you very much for your quick answer. When I run validate I get a lot of invalid Alignment
vg validate bd2.gbz -a BD016.hifi.gam
Invalid Alignment:
{"identity": 1.0, "mapping_quality": 60, "name": "m84151_230927_104248_s2/258741483/ccs", "path": {"mapping": [{"edit": [{"from_length": 728, "to_length": 728}], "position": {"name": "17147998", "node_id": "17147998", "offset": "641"}}]}, "sequence": "AGAGTGAATTAAAGAATGTCTATTGTGACCTTAGAATATATTTAAGTAAAGAGTAAAATACATTTTCTGGAGGTACTAAGAAGTAGTAATGAATTGTGAAAAGGAAGATTATAAGATTTCTATAAGGAATTCATATATGAAGTCCCATTCTACTTGAGCAAAGAGCATGATAAAAAAATGCAATGTAAATGAGCACCATCAATAACATTAATTACCTGCTGCCTCTGCAGATGTGTATATTAGAGACAACAGGTTAGATGGGTTTTACTAAAGCACAGCAGACCGCTGAATCATATAGCCACAAAGGGCAAACTGTATCATGGAACCAGTTAGAGCTGACTTTATCACTGAGAAAGACATGCTACCAGATTAAAATGCAAATCATACAACTAATGCTGCATTGCTAGACAACACTATGTATAGAATAGGATAGATGCTGTATGTACAGAGAACCAAAATCTCCAGTCCATGCAATGCTCCATGCTTTTTGGAAATATATGCAAAGAATCATATGCTGATGGGTTACATGCTTAAATAACTACTCATTTTCTCATTTATACAACAAGACCCTGTAACTAACAGATTTTCTCAATACTTTGCAAGAATTTTGCTGACTTATTTGCTACGCAAATAAACCATTTTTATTAAATTCAATGCAATTACAAAGAGGTGATATGCTGTATTGATTTAGAAAGATACATCCAAGTTTAGTTAGTAAATACATTTGG"}
Length of node 17147998 (65) exceeded by Mapping with offset 641 and from-length 728:
{"edit": [{"from_length": 728, "to_length": 728}], "position": {"name": "17147998", "node_id": "17147998", "offset": "641"}}
Invalid Alignment:
I followed the tutorial here https://github.com/ComparativeGenomicsToolkit/cactus/blob/master/doc/sa_refgraph_hackathon_2023.md
and ran the following commands
apptainer exec cactus.sif \
cactus-pangenome ./js-bdchr ./seqfile.chr.txt \
--outName bd2 \
--outDir bd2 \
--reference UU_Cfam_GSD_1 \
--filter 2 \
--giraffe clip filter \
--vcf \
--viz \
--odgi \
--chrom-vg clip filter \
--chrom-og \
--gbz clip filter full \
--gfa clip full \
--vcf \
--logFile bd.log \
--mgCores 64 \
--mapCores 16 \
--consCores 64 \
apptainer exec vg convert ./bd2/bd2.gbz -f > bd2.gbz.gfa
apptainer exec graphaligner\:1.0.19--h21ec9f0_0 GraphAligner -g bd2.gbz.gfa -f BD016_flt.fastq -a BD016.hifi.gam -x vg -t 64
not sure how I should proceed. Thank you very much for any help.
The GFA you get from vg convert
may not be the same graph as the GBZ. That is because GBZ is designed to both preserve the original GFA and expose a graph with long segments chopped to a more manageable size. If you use the GBZ graph, you see the graph with chopped nodes. But if you convert it to GFA, you get the original graph with potentially long segments.
If that is the issue, you should be able to fix it by adding option --no-translation
to the vg convert
command.
*1. I mapped long reads to the graph gbz.gfa using graphAligner and got the gam file. I wanted to to SV calling and genotyping
I ran the below command
apptainer exec cactus.sif vg pack -t 64 -x bd2.gbz -g BD016.hifi.gam -o BD016.pack also apptainer exec cactus.sif vg validate bd2.gbz BD016.hifi.gam gave the output
3. What actually happened? vg pack crashed and I got the following error.
6. What does running
vg version
say?Thank you very much for your help