1
0
mirror of https://github.com/gryf/coach.git synced 2025-12-18 11:40:18 +01:00
Files
coach/docs_raw/source/components/agents/value_optimization/pal.rst
Itai Caspi 6d40ad1650 update of api docstrings across coach and tutorials [WIP] (#91)
* updating the documentation website
* adding the built docs
* update of api docstrings across coach and tutorials 0-2
* added some missing api documentation
* New Sphinx based documentation
2018-11-15 15:00:13 +02:00

1.9 KiB
Raw Blame History

Actions space: Discrete

References: Increasing the Action Gap: New Operators for Reinforcement Learning

Network Structure

/_static/img/design_imgs/dqn.png

Algorithm Description

Training the network

  1. Sample a batch of transitions from the replay buffer.

  2. Start by calculating the initial target values in the same manner as they are calculated in DDQN yDDQNt=r(st,at)+γQ(st+1,argmaxaQ(st+1,a))

  3. The action gap V(st)Q(st,at) should then be subtracted from each of the calculated targets. To calculate the action gap, run the target network using the current states and get the Q values for all the actions. Then estimate V as the maximum predicted Q value for the current state: V(st)=maxaQ(st,a)

  4. For advantage learning (AL), reduce the action gap weighted by a predefined parameter α from the targets yDDQNt: yt=yDDQNtα⋅(V(st)Q(st,at))

  5. For persistent advantage learning (PAL), the target network is also used in order to calculate the action gap for the next state: V(st+1)Q(st+1,at+1) where at+1 is chosen by running the next states through the online network and choosing the action that has the highest predicted Q value. Finally, the targets will be defined as - yt=yDDQNtαmin(V(st)Q(st,at),V(st+1)Q(st+1,at+1))

  6. Train the online network using the current states as inputs, and with the aforementioned targets.

  7. Once in every few thousand steps, copy the weights from the online network to the target network.