Update async methods

This commit is contained in:
Shangtong Zhang
2017-12-12 10:39:16 -07:00
parent 83a4270bb2
commit fed4bd5163
2 changed files with 13 additions and 5 deletions
+9 -1
View File
@@ -90,12 +90,20 @@ I use 8 threads and a two tanh hidden layer network, each hidden layer has 64 hi
# Usage
Detailed usage and all training parameters can be found in ```main.py```.
And you need to create following directories before running the program:
You need to create following directories before running the program:
```
cd DeepRL
mkdir data log
```
Code is only tested in macOS 10.12 and CentO/S 6.8. And for CentO/S 6.8, you need
```
export OMP_NUM_THREADS=1
```
manually in shell before running parallelized implementation.
# References
* [Human Level Control through Deep Reinforcement Learning](https://www.nature.com/nature/journal/v518/n7540/full/nature14236.html)
* [Asynchronous Methods for Deep Reinforcement Learning](https://arxiv.org/abs/1602.01783)
+4 -4
View File
@@ -100,7 +100,7 @@ def async_pixel_atari(name):
config.discount = 0.99
config.target_network_update_freq = 10000
config.max_episode_length = 10000
config.num_workers = 10
config.num_workers = 6
config.update_interval = 20
config.test_interval = 50000
config.test_repetitions = 1
@@ -120,7 +120,7 @@ def a3c_pixel_atari(name):
config.worker = AdvantageActorCritic
config.discount = 0.99
config.max_episode_length = 10000
config.num_workers = 10
config.num_workers = 6
config.update_interval = 20
config.test_interval = 50000
config.test_repetitions = 1
@@ -270,7 +270,7 @@ if __name__ == '__main__':
# gym.logger.setLevel(logging.DEBUG)
gym.logger.setLevel(logging.INFO)
dqn_cart_pole()
# dqn_cart_pole()
# async_cart_pole()
# a3c_cart_pole()
# a3c_continuous()
@@ -282,7 +282,7 @@ if __name__ == '__main__':
# dqn_pixel_atari('PongNoFrameskip-v4')
# async_pixel_atari('PongNoFrameskip-v4')
# a3c_pixel_atari('PongNoFrameskip-v4')
a3c_pixel_atari('PongNoFrameskip-v4')
# dqn_pixel_atari('BreakoutNoFrameskip-v4')
# async_pixel_atari('BreakoutNoFrameskip-v4')