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
f362ebff
Commit
f362ebff
authored
Mar 29, 2022
by
Gustaf Ahdritz
Browse files
Undo DeepSpeed config change
parent
16e0082f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
10 deletions
+10
-10
deepspeed_config.json
deepspeed_config.json
+1
-1
scripts/build_deepspeed_config.py
scripts/build_deepspeed_config.py
+9
-9
No files found.
deepspeed_config.json
View file @
f362ebff
...
...
@@ -7,7 +7,7 @@
"enabled"
:
false
,
"opt_level"
:
"O2"
},
"bf16"
:
{
"bf
loat
16"
:
{
"enabled"
:
true
},
"zero_optimization"
:
{
...
...
scripts/build_deepspeed_config.py
View file @
f362ebff
...
...
@@ -134,10 +134,10 @@ p.add_argument("--fp16", dest="fp16", action="store_true", default=False,
help
=
"""Whether to train in 16-bit/mixed-precision mode.
Mutually exclusive with --amp"""
)
p
=
parser
.
add_argument_group
(
"Half-precision training (bf16)"
)
p
.
add_argument
(
"--bf16"
,
dest
=
"bf16"
,
action
=
"store_true"
,
p
=
parser
.
add_argument_group
(
"Half-precision training (bf
loat
16)"
)
p
.
add_argument
(
"--bf
loat
16"
,
dest
=
"bf
loat
16"
,
action
=
"store_true"
,
default
=
False
,
help
=
"""Whether to train in 16-bit bf16 mode. Mutually
help
=
"""Whether to train in 16-bit bf
loat
16 mode. Mutually
exclusive with --amp and --fp16. Requires hardware
support"""
)
...
...
@@ -258,8 +258,8 @@ if(args.scheduler is not None):
d
[
"scheduler"
]
=
scheduler
# 16-bit training
if
(
sum
([
args
.
amp
,
args
.
fp16
,
args
.
bf16
])
>
1
):
raise
ValueError
(
"Only one of --fp16, --amp, or --bf16 can be enabled"
)
if
(
sum
([
args
.
amp
,
args
.
fp16
,
args
.
bf
loat
16
])
>
1
):
raise
ValueError
(
"Only one of --fp16, --amp, or --bf
loat
16 can be enabled"
)
if
(
args
.
amp
):
amp
=
{}
...
...
@@ -270,10 +270,10 @@ elif(args.fp16):
fp16
=
{}
fp16
[
"enabled"
]
=
args
.
fp16
d
[
"fp16"
]
=
fp16
elif
(
args
.
bf16
):
bf16
=
{}
bf16
[
"enabled"
]
=
args
.
bf16
d
[
"bf16"
]
=
bf16
elif
(
args
.
bf
loat
16
):
bf
loat
16
=
{}
bf
loat
16
[
"enabled"
]
=
args
.
bf
loat
16
d
[
"bf
loat
16"
]
=
bf
loat
16
# Activation checkpointing
ac
=
{}
...
...
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