Update README

This commit is contained in:
Shangtong Zhang
2018-01-31 20:21:38 -07:00
parent 797f80d5ff
commit 3dcda7b5d5
3 changed files with 5 additions and 5 deletions
+1 -2
View File
@@ -7,13 +7,12 @@ Implemented algorithms:
* Deep Q-Learning (DQN)
* Double DQN
* Dueling DQN
* Async Advantage Actor Critic (A3C)
* (Async) Advantage Actor Critic (A3C / A2C)
* Async One-Step Q-Learning
* Async One-Step Sarsa
* Async N-Step Q-Learning
* Continuous A3C
* Distributed Deep Deterministic Policy Gradient (Distributed DDPG, aka D3PG)
* Hybrid Reward Architecture (HRA)
* Parallelized Proximal Policy Optimization (P3O, similar to DPPO)
* Action Conditional Video Prediction
+1 -1
View File
@@ -100,7 +100,7 @@ class A2CAgent:
value_loss = 0.5 * (Variable(returns) - value).pow(2)
self.optimizer.zero_grad()
(policy_loss + value_loss).mean().backward()
(policy_loss + value_loss).sum().backward()
nn.utils.clip_grad_norm(self.network.parameters(), config.gradient_clip)
self.optimizer.step()
+3 -2
View File
@@ -308,13 +308,14 @@ if __name__ == '__main__':
mkdir('data/video')
mkdir('log')
os.system('export OMP_NUM_THREADS=1')
os.system('export CUDA_VISIBLE_DEVICES=0')
# logger.setLevel(logging.DEBUG)
logger.setLevel(logging.INFO)
dqn_cart_pole()
# dqn_cart_pole()
# async_cart_pole()
# a3c_cart_pole()
# a2c_cart_pole()
a2c_cart_pole()
# a3c_continuous()
# p3o_continuous()
# d3pg_continuous()