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
02493a8c
Commit
02493a8c
authored
Feb 23, 2024
by
Christina Floristean
Committed by
jnwei
May 09, 2024
Browse files
Hotfix to switch order of feature dict generation
parent
945ecc0c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
9 deletions
+10
-9
run_pretrained_openfold.py
run_pretrained_openfold.py
+10
-9
No files found.
run_pretrained_openfold.py
View file @
02493a8c
...
@@ -131,7 +131,16 @@ def generate_feature_dict(
...
@@ -131,7 +131,16 @@ def generate_feature_dict(
args
,
args
,
):
):
tmp_fasta_path
=
os
.
path
.
join
(
args
.
output_dir
,
f
"tmp_
{
os
.
getpid
()
}
.fasta"
)
tmp_fasta_path
=
os
.
path
.
join
(
args
.
output_dir
,
f
"tmp_
{
os
.
getpid
()
}
.fasta"
)
if
len
(
seqs
)
==
1
:
if
"multimer"
in
args
.
config_preset
:
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
fp
.
write
(
'
\n
'
.
join
([
f
">
{
tag
}
\n
{
seq
}
"
for
tag
,
seq
in
zip
(
tags
,
seqs
)])
)
feature_dict
=
data_processor
.
process_fasta
(
fasta_path
=
tmp_fasta_path
,
alignment_dir
=
alignment_dir
,
)
elif
len
(
seqs
)
==
1
:
tag
=
tags
[
0
]
tag
=
tags
[
0
]
seq
=
seqs
[
0
]
seq
=
seqs
[
0
]
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
...
@@ -143,14 +152,6 @@ def generate_feature_dict(
...
@@ -143,14 +152,6 @@ def generate_feature_dict(
alignment_dir
=
local_alignment_dir
,
alignment_dir
=
local_alignment_dir
,
seqemb_mode
=
args
.
use_single_seq_mode
,
seqemb_mode
=
args
.
use_single_seq_mode
,
)
)
elif
"multimer"
in
args
.
config_preset
:
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
fp
.
write
(
'
\n
'
.
join
([
f
">
{
tag
}
\n
{
seq
}
"
for
tag
,
seq
in
zip
(
tags
,
seqs
)])
)
feature_dict
=
data_processor
.
process_fasta
(
fasta_path
=
tmp_fasta_path
,
alignment_dir
=
alignment_dir
,
)
else
:
else
:
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
with
open
(
tmp_fasta_path
,
"w"
)
as
fp
:
fp
.
write
(
fp
.
write
(
...
...
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