Reverse Complement Fails when return_seq_indices=True
Vejni opened this issue · 3 comments
Vejni commented
Hi, thanks for this adaptation.
Reverse complemeting when return_seq_indices
is set True fails, because the seq that is passed to seq_indices_reverse_complement
is a string, while the function treats it as a tensor of indices. A simple fix would be to first call str_to_seq_indices
previous to this.
if self.return_seq_indices:
if self.rc_aug and coin_flip():
seq = seq_indices_reverse_complement(seq)
return str_to_seq_indices(seq)
lucidrains commented
@Vejni hey Marcell! thanks for finding this issue! do let me know if the latest commit fixes it
Vejni commented
Thanks for addressing this. The issue is fixed, however you forgot to rename rc_aug
to should_rc_aug
on line 169, so asking for the augs to be returned will fail.
rand_aug_bool_tensor = torch.tensor([rc_aug])
Other than that, we can close this :)
lucidrains commented