baselines icon indicating copy to clipboard operation
baselines copied to clipboard

Possible bug in gradient clipping of deepq_learner (tf2 branch)

Open Giullar opened this issue 2 years ago • 1 comments

https://github.com/openai/baselines/blob/b99a73afe37206775ac8b884d32a36e213a3fac2/baselines/deepq/deepq_learner.py#L174-L181

In line 179, shouldn't it be: grads = clipped_grads instead of clipped_grads = grads ?

Giullar avatar Nov 09 '22 15:11 Giullar

yes, I think you are right. It should be grads = clipped_grads, as it is the list containing the gradients after clipping, which should be used for optimization.

susanth-24 avatar May 05 '23 03:05 susanth-24