Skip to content

Commit

Permalink
quick bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
avantikalal committed Nov 7, 2024
1 parent c954dd0 commit 0260b9a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/grelu/interpret/motifs.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,10 @@ def scan_sequences(
seq_ids = seq_ids or [str(i) for i in range(len(seqs))]

# Format motifs
if isinstance(motifs, Dict):
motifs = {k: Tensor(v) for k, v in motifs.items()}
if isinstance(motifs, str):
motifs = read_meme_file(motifs)

motifs = {k: Tensor(v) for k, v in motifs.items()}

# Scan each sequence in seqs
results = pd.DataFrame()
Expand Down Expand Up @@ -305,7 +307,6 @@ def compare_motifs(
rc: If True, both the sequence and its reverse complement will be
scanned. If False, only the given sequence will be scanned.
"""
from grelu.interpret.motifs import scan_sequences
from grelu.sequence.mutate import mutate

# Create alt sequence
Expand Down

0 comments on commit 0260b9a

Please sign in to comment.