We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ec5b3c6 commit c1012a6Copy full SHA for c1012a6
2 files changed
enformer_pytorch/data.py
@@ -70,6 +70,13 @@ def seq_indices_to_one_hot(t, padding = -1):
70
out = out.masked_fill(is_padding[..., None], 0.25)
71
return out
72
73
+# augmentations
74
+
75
+def one_hot_reverse_complement(one_hot):
76
+ *_, n, d = one_hot.shape
77
+ assert d == 4, 'must be one hot encoding with last dimension equal to 4'
78
+ return torch.flip(one_hot, (-1, -2))
79
80
# processing bed files
81
82
class FastaInterval():
setup.py
@@ -4,7 +4,7 @@
4
name = 'enformer-pytorch',
5
packages = find_packages(exclude=[]),
6
include_package_data = True,
7
- version = '0.2.11',
+ version = '0.2.12',
8
license='MIT',
9
description = 'Enformer - Pytorch',
10
author = 'Phil Wang',
0 commit comments