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
0c4a93f7
Commit
0c4a93f7
authored
Jan 31, 2023
by
Lucas Bickmann
Browse files
Fix wrong parsing
parent
1026158e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
train_openfold.py
train_openfold.py
+4
-4
No files found.
train_openfold.py
View file @
0c4a93f7
...
...
@@ -283,9 +283,9 @@ def main(args):
sd
=
{
k
[
len
(
"module."
):]:
v
for
k
,
v
in
sd
.
items
()}
model_module
.
load_state_dict
(
sd
)
logging
.
info
(
"Successfully loaded model weights..."
)
if
(
args
.
jax_param
_path
):
model_module
.
load_from_jax
(
args
.
jax_param
_path
)
logging
.
info
(
f
"Successfully loaded JAX parameters at
{
args
.
jax_param
_path
}
..."
)
if
(
args
.
resume_from_
jax_param
s
):
model_module
.
load_from_jax
(
args
.
resume_from_
jax_param
s
)
logging
.
info
(
f
"Successfully loaded JAX parameters at
{
args
.
resume_from_
jax_param
s
}
..."
)
# TorchScript components of the model
if
(
args
.
script_modules
):
...
...
@@ -591,7 +591,7 @@ if __name__ == "__main__":
if
(
str
(
args
.
precision
)
==
"16"
and
args
.
deepspeed_config_path
is
not
None
):
raise
ValueError
(
"DeepSpeed and FP16 training are not compatible"
)
if
(
args
.
jax_param
_path
is
not
None
and
args
.
resume_from_ckpt
is
not
None
):
if
(
args
.
resume_from_
jax_param
s
is
not
None
and
args
.
resume_from_ckpt
is
not
None
):
raise
ValueError
(
"Choose between loading pretrained Jax-weights and a checkpoint-path"
)
# This re-applies the training-time filters at the beginning of every epoch
...
...
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