Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't load pggb output? #90

Closed
yuliamostovoy opened this issue Jul 15, 2022 · 7 comments · Fixed by #92
Closed

Can't load pggb output? #90

yuliamostovoy opened this issue Jul 15, 2022 · 7 comments · Fixed by #92
Labels
gfa Issues related to GFA standard
Milestone

Comments

@yuliamostovoy
Copy link

I'm trying to load the HPRC PGGB-generated GFAs from here: https://s3-us-west-2.amazonaws.com/human-pangenomics/index.html?prefix=pangenomes/freeze/freeze1/pggb/chroms/

I get this error message:

There was an error when attempting to load:
/Users/ymm14/work/graphs/chr1.hprc-v1.0-pggb.nopaths.gfa

Please verify that this file has the correct format.

Original Bandage is able to load the same files with no issues. I'd appreciate any help, thanks!

@asl
Copy link
Owner

asl commented Jul 15, 2022

The graph uses "DP" tag of unexpected type. It is expected that the tag should use a floating point, not integer:

DP:i:1  RC:i:317470

We will introduce workaround in the next Bandage-NG version. For now the workaround is to replace DP:i: in the file with DP:f:.

@asl asl added the gfa Issues related to GFA standard label Jul 15, 2022
@asl asl added this to the 2022.07 milestone Jul 15, 2022
@yuliamostovoy
Copy link
Author

Thank you!

@paoloczi
Copy link

Actually, the samtools specification states in section 1.4.2 that the DP tag should be an integer. So the HPRC PGGB output is correct, and Bandage should expect an integer by default - although you could allow it to also accept a floating point number.

DP : read depth at this position for this sample (Integer)

@asl
Copy link
Owner

asl commented Jul 15, 2022

@paoloczi The interpretation is completely different and I doubt samtools spec is irrelevant here. DP in case of graphs is an average depth of the node (e.g. average number of kmers / reads / fragments covered each position of the node), therefore it is expected to be a floating point value, there is no "position" here. And this is what do assemblers produce.

@paoloczi
Copy link

That is what I was thinking too before I saw that quote, and in fact I was looking for corroboration of the Bandage assumption that it is supposed to be a float. But I was not able to find any document or specification describing a floating point DP tag in any context - do you know of one?

@asl
Copy link
Owner

asl commented Jul 15, 2022

No. This is exactly what #35 supposed to be

@asl
Copy link
Owner

asl commented Jul 15, 2022

@yuliamostovoy The fix is included in the following snapshot: https://github.com/asl/BandageNG/releases/tag/v2022.07.16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gfa Issues related to GFA standard
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants