-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[BUFIX] fail when passed fastas with duplicate sequence ids (#555)
When NvFaidx was used on Fasta files containing duplicate sequence ids, which violates the FASTA spec, it would silently fail and use the last-seen sequence as an entry. This PR fails by default and exposes a parameter to ignore sequence_ids and use integer indexing instead.
- Loading branch information
1 parent
c7281be
commit f8db8a2
Showing
3 changed files
with
65 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
sub-packages/bionemo-noodles/tests/bionemo/noodles/data/dupes.fasta
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
>chr1 version|of|seq1 | ||
ACTGACTGACTG | ||
>chr1 version|of|seq2 | ||
GGTCAAGGTCAA | ||
>chr1 some|random|inputs | ||
AGTCAAGGTCCA | ||
CGTCAAGGTCCC | ||
GGTCAAGGTCCG | ||
TGTCAAGGTCCT | ||
AGTCAAGGTCAA | ||
CGTCAAGGTCAC | ||
GGTCAAGGTCAG | ||
>chr1 why|is|this|done | ||
CCCCCCCCCCCC | ||
ACGT | ||
>chr1 stop|violated|fasta|spec | ||
A |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters