I wanted to re-create the latest Deep Q-Learning results on Atari, a huge milestone for AI Research in the past few years.
Apart from the official code in Lua, I found several Python implementations on github, notably this one from OpenAI or this one among many others. Very few Python implementations actually run on Atari environments though, and even less actually report benchmarks comparing to published results. Not only that, but I wasn’t able to reproduce or even run some implementations, including the OpenAI DDQN Atari baselines (see github issue)…kind of ironic.
After wasting several days of GPU time, I remembered that I implemented a version of DQN for a CS294 homework, which actually works. I added DDQN + Dueling + Prioritized Replay and put it in
yarlp (Yet Another Reinforcement Learning Package). Then I ran some benchmarks!
I trained 6 Atari environments for 10M time-steps (40M frames), using 1 random seed, since I have limited time on this Earth. I used DDQN with dueling networks without prioritized replay. I compare the final mean 100 episode raw scores for yarlp (with exploration of 0.01) with results from Hasselt et al, 2015 and Wang et al, 2016 which train for 200M frames and evaluate on 100 episodes (exploration of 0.05). I also compared visually to the learning curves released by OpenAI.
|env||yarlp DUEL 40M Frames||Hasselt et al DDQN 200M Frames||Wang et al DUEL 200M Frames|
Here are the learning curves:
Since I ran for 1/5th of the frames, I wasn’t expecting the final rewards to be close to that of the published results. But some environments are, especially the easier ones like Pong and Breakout. A notable difference between these implementations is that I use piece-wise learning rate and exploration schedules while Hasselt and Wang use linear ones. I wanted to do a mini-ablation experiment to see how these differences stack up against learned rewards. Surprisingly, the piece-wise schedules (
no_lr_schedule) seemed to make the biggest gain as opposed to dueling networks or prioritized replay! Granted, I didn’t run for multiple random seeds or environments or more frames, but this begs the question, can better exploration and learning rate schedules beat recent advances due to prioritized replay or dueling networks on Atari?
Enjoy some gifs instead!
This blog post pretty much sums up my experience with Deep RL algorithms so far.