Skip to content

Commit 3676545

Browse files
committed
Added comment that exclusion zones are applied to query motif
1 parent 80dc3e9 commit 3676545

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

stumpy/aamp_motifs.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,8 @@ def _aamp_motifs(
133133
query_matches = np.array([[np.nan, candidate_idx]])
134134

135135
for idx in query_matches[:, 1]:
136+
# Since the query motif is also included as the first item in the list of
137+
# `query_matches`, the exclusion zone is also applied to the query motif!
136138
core.apply_exclusion_zone(P, int(idx), excl_zone, np.inf)
137139

138140
candidate_idx = np.argmin(P[-1])

stumpy/motifs.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,8 @@ def _motifs(
138138
query_matches = np.array([[np.nan, candidate_idx]])
139139

140140
for idx in query_matches[:, 1]:
141+
# Since the query motif is also included as the first item in the list of
142+
# `query_matches`, the exclusion zone is also applied to the query motif!
141143
core.apply_exclusion_zone(P, int(idx), excl_zone, np.inf)
142144

143145
candidate_idx = np.argmin(P[-1])

0 commit comments

Comments
 (0)