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
apex
Commits
214fda42
Unverified
Commit
214fda42
authored
Apr 03, 2019
by
mcarilli
Committed by
GitHub
Apr 03, 2019
Browse files
Allow verbose casting information for O1
parent
84028786
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
apex/amp/_initialize.py
apex/amp/_initialize.py
+1
-1
No files found.
apex/amp/_initialize.py
View file @
214fda42
...
@@ -199,7 +199,7 @@ def _initialize(models, optimizers, properties):
...
@@ -199,7 +199,7 @@ def _initialize(models, optimizers, properties):
if
properties
.
patch_torch_functions
:
if
properties
.
patch_torch_functions
:
# handle is unused here. It's accessible later through a global value anyway.
# handle is unused here. It's accessible later through a global value anyway.
handle
=
amp_init
(
loss_scale
=
properties
.
loss_scale
)
handle
=
amp_init
(
loss_scale
=
properties
.
loss_scale
,
verbose
=
(
_amp_state
.
verbosity
==
2
)
)
for
optimizer
in
optimizers
:
for
optimizer
in
optimizers
:
# Disable Amp casting for the optimizer step, because it should only be
# Disable Amp casting for the optimizer step, because it should only be
# applied to FP32 master params anyway.
# applied to FP32 master params anyway.
...
...
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