Skip to content

Commit

Permalink
fix bug of specific init with AAAAA... in sequence and kmer
Browse files Browse the repository at this point in the history
  • Loading branch information
pratas committed Sep 26, 2023
1 parent bd5116e commit 5a592a5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
3 changes: 0 additions & 3 deletions benchmark/Download_FASTA.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,3 @@ cat DNACorpus/* | gto_fasta_from_seq -n "CORPUS" > CORPUS.fa
#
# -----------------------------------------------------------------------------
#
wget virus.fa
#
#
7 changes: 4 additions & 3 deletions src/repeats.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,11 @@ int32_t StartRM(RCLASS *C, uint32_t m, uint64_t i, uint8_t r)
if(last == 0) return 0;

RM = &C->RM[m];
uint64_t idx = rand() % C->T->nPos;
uint64_t idx = rand() % C->T->nPos;

if(E[idx] <= C->P->ctx+1)
return 0;

if(r == 0) // REGULAR REPEAT
{
if(E[idx] == 0)
Expand All @@ -138,8 +141,6 @@ int32_t StartRM(RCLASS *C, uint32_t m, uint64_t i, uint8_t r)
}
else // INVERTED REPEAT
{
if(E[idx] <= C->P->ctx+1)
return 0;
RM->pos = E[idx] - C->P->ctx - 1;
}
}
Expand Down

0 comments on commit 5a592a5

Please sign in to comment.