The algorithm process of collision-avoidance strategy for ASs based on the DDPG algorithm
| Initialise critic and actor network parameters: θQ and θμ |
| Initialise the critic and actor network target networks and directly copy parameters: |
| Initialise the experience pool R |
| 1: For episode = 1, M: |
| 2: Initialise random process N |
| 3: Obtain the initial state of the AS s1 |
| 4: For t = 1, T: |
| 5: Choose an action based on the current policy and random noise: |
| 6: Perform action at, get instant reward rt and next state st+1 |
| 7: Store state/action pairs (st, at, rt, st+1) into experience pool R |
| 8: Randomly sample K state/action pairs (st, at, rt, st+1) from the experience pool R |
| 9: Compute the ‘label value’ of the critical network: |
| 10: Calculate the error of the critical network and use gradient descent to update critical network parameters |
| 11: Calculate the gradient of the actor network and update the actor network parameters using gradient ascent: |
| 12: Update the parameters of the critic and actor network target network: |
| 13: End for |
| 14: End for |
| Initialise critic and actor network parameters: |
| Initialise the critic and actor network target networks and directly copy parameters: |
| Initialise the experience pool |
| 1: For episode = 1, |
| 2: Initialise random process |
| 3: Obtain the initial state of the AS |
| 4: For |
| 5: Choose an action based on the current policy and random noise: |
| 6: Perform action |
| 7: Store state/action pairs ( |
| 8: Randomly sample |
| 9: Compute the ‘label value’ of the critical network: |
| 10: Calculate the error of the critical network |
| 11: Calculate the gradient of the actor network and update the actor network parameters using gradient ascent: |
| 12: Update the parameters of the critic and actor network target network: |
| 13: End for |
| 14: End for |
Sharing content requires targeting cookies to be enabled. Please update your cookie preferences to use this feature.