Skip to content

Commit

Permalink
[RLlib] Add option for running multiple sgd iters for impala learner …
Browse files Browse the repository at this point in the history
…api (ray-project#33316)

Signed-off-by: Avnish <[email protected]>
Signed-off-by: Jack He <[email protected]>
  • Loading branch information
avnishn authored and ProjectsByJackHe committed May 4, 2023
1 parent 631a683 commit 06e61f8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rllib/algorithms/impala/impala.py
Original file line number Diff line number Diff line change
Expand Up @@ -862,7 +862,10 @@ def learn_on_processed_samples(self) -> ResultDict:
# Then we can't do async updates, so we need to block.
blocking = self.config.num_learner_workers == 0
lg_results = self.learner_group.update(
batch, reduce_fn=_reduce_impala_results, block=blocking
batch,
reduce_fn=_reduce_impala_results,
block=blocking,
num_iters=self.config.num_sgd_iter,
)
else:
lg_results = None
Expand Down

0 comments on commit 06e61f8

Please sign in to comment.