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
bc98827b
Commit
bc98827b
authored
Mar 20, 2020
by
Thor Johnsen
Browse files
Bug fix
parent
90795025
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
apex/contrib/optimizers/distributed_fused_adam.py
apex/contrib/optimizers/distributed_fused_adam.py
+2
-2
No files found.
apex/contrib/optimizers/distributed_fused_adam.py
View file @
bc98827b
...
@@ -409,7 +409,7 @@ class DistributedFusedAdam(torch.optim.Optimizer):
...
@@ -409,7 +409,7 @@ class DistributedFusedAdam(torch.optim.Optimizer):
bias_correction
,
bias_correction
,
group
[
'weight_decay'
])
group
[
'weight_decay'
])
elif
self
.
_revert_method
==
2
:
elif
self
.
_revert_method
==
2
:
self
.
_swap_optimizer_state_buffers
()
self
.
_
_
swap_optimizer_state_buffers
()
elif
self
.
_revert_method
==
3
:
elif
self
.
_revert_method
==
3
:
raise
RuntimeError
(
'revert_step debug option not implemented yet'
)
raise
RuntimeError
(
'revert_step debug option not implemented yet'
)
else
:
else
:
...
@@ -430,7 +430,7 @@ class DistributedFusedAdam(torch.optim.Optimizer):
...
@@ -430,7 +430,7 @@ class DistributedFusedAdam(torch.optim.Optimizer):
bias_correction
,
bias_correction
,
group
[
'weight_decay'
])
group
[
'weight_decay'
])
elif
self
.
_revert_method
==
2
:
elif
self
.
_revert_method
==
2
:
self
.
_swap_optimizer_state_buffers
()
self
.
_
_
swap_optimizer_state_buffers
()
fused_adam_cuda
.
adam_no_overflow_check
(
fused_adam_cuda
.
adam_no_overflow_check
(
self
.
_fp32_backup_p
[
group_buffer_start
:
group_buffer_end
],
self
.
_fp32_backup_p
[
group_buffer_start
:
group_buffer_end
],
self
.
_fp32_p
[
group_buffer_start
:
group_buffer_end
],
self
.
_fp32_p
[
group_buffer_start
:
group_buffer_end
],
...
...
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