Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
OpenFold
Commits
1d7dc67c
Commit
1d7dc67c
authored
Nov 15, 2021
by
Gustaf Ahdritz
Browse files
Remove vestigial function
parent
a933bc74
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
49 deletions
+0
-49
openfold/utils/feats.py
openfold/utils/feats.py
+0
-49
No files found.
openfold/utils/feats.py
View file @
1d7dc67c
...
@@ -161,55 +161,6 @@ def build_extra_msa_feat(batch):
...
@@ -161,55 +161,6 @@ def build_extra_msa_feat(batch):
return
torch
.
cat
(
msa_feat
,
dim
=-
1
)
return
torch
.
cat
(
msa_feat
,
dim
=-
1
)
# adapted from model/tf/data_transforms.py
def
build_msa_feat
(
batch
):
"""Create and concatenate MSA features."""
# Whether there is a domain break. Always zero for chains, but keeping
# for compatibility with domain datasets.
has_break
=
batch
[
"between_segment_residues"
]
aatype_1hot
=
nn
.
functional
.
one_hot
(
batch
[
"aatype"
],
num_classes
=
21
)
target_feat
=
[
has_break
.
unsqueeze
(
-
1
),
aatype_1hot
,
# Everyone gets the original sequence.
]
msa_1hot
=
nn
.
functional
.
one_hot
(
batch
[
"msa"
],
num_classes
=
23
)
has_deletion
=
batch
[
"deletion_matrix"
]
deletion_value
=
torch
.
atan
(
batch
[
"deletion_matrix"
]
/
3.0
)
*
(
2.0
/
math
.
pi
)
msa_feat
=
[
msa_1hot
,
has_deletion
.
unsqueeze
(
-
1
),
deletion_value
.
unsqueeze
(
-
1
),
]
if
"cluster_profile"
in
batch
:
deletion_mean_value
=
tf
.
atan
(
batch
[
"cluster_deletion_mean"
]
/
3.0
)
*
(
2.0
/
np
.
pi
)
msa_feat
.
extend
(
[
batch
[
"cluster_profile"
],
tf
.
expand_dims
(
deletion_mean_value
,
axis
=-
1
),
]
)
if
"extra_deletion_matrix"
in
protein
:
batch
[
"extra_has_deletion"
]
=
tf
.
clip_by_value
(
batch
[
"extra_deletion_matrix"
],
0.0
,
1.0
)
batch
[
"extra_deletion_value"
]
=
tf
.
atan
(
batch
[
"extra_deletion_matrix"
]
/
3.0
)
*
(
2.0
/
np
.
pi
)
batch
[
"msa_feat"
]
=
torch
.
cat
(
msa_feat
,
dim
=-
1
)
batch
[
"target_feat"
]
=
torch
.
cat
(
target_feat
,
dim
=-
1
)
return
batch
def
torsion_angles_to_frames
(
def
torsion_angles_to_frames
(
t
:
T
,
t
:
T
,
alpha
:
torch
.
Tensor
,
alpha
:
torch
.
Tensor
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment