Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
[ghstack-poisoned]
  • Loading branch information
vmoens committed Dec 15, 2024
1 parent f601cce commit 647dacc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sota-implementations/ppo/ppo_atari.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,8 @@ def update(batch, num_network_updates):
with torch.no_grad(), timeit("adv"):
torch.compiler.cudagraph_mark_step_begin()
data = adv_module(data)
if compile_mode:
data = data.clone()
with timeit("rb - extend"):
# Update the data buffer
data_reshape = data.reshape(-1)
Expand Down
3 changes: 3 additions & 0 deletions sota-implementations/ppo/ppo_mujoco.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,9 @@ def update(batch, num_network_updates):
with torch.no_grad(), timeit("adv"):
torch.compiler.cudagraph_mark_step_begin()
data = adv_module(data)
if compile_mode:
data = data.clone()

with timeit("rb - extend"):
# Update the data buffer
data_reshape = data.reshape(-1)
Expand Down

0 comments on commit 647dacc

Please sign in to comment.