mimoralea / gdrl

Grokking Deep Reinforcement Learning
https://www.manning.com/books/grokking-deep-reinforcement-learning
BSD 3-Clause "New" or "Revised" License
812 stars 234 forks source link

A possible error in chapter-11.ipynb/SharedAdam and SharedRMSprop #24

Open MarginalCentrality opened 2 years ago

MarginalCentrality commented 2 years ago

Maybe we need to change "self.state[p]['steps'] = self.state[p]['shared_step'].item()" to "self.state[p]['step'] = self.state[p]['shared_step'].item()", in both the step functions of SharedAdam and SharedRMSprop under chapter-11.ipynb. Becasue in the step function of Adam, "state[step]" is used rather than "state[steps]".