Permalink
Browse files

Continue drawing also in the testing phase

  • Loading branch information...
1 parent 86cf573 commit 0da37459c34d96cdf1a84767cabd1cb0aed79659 @kuz committed Aug 15, 2015
Showing with 14 additions and 0 deletions.
  1. +11 −0 README.md
  2. +3 −0 dqn/train_agent.lua
View
@@ -76,6 +76,17 @@ specified GPU by setting the environment variable GPU_ID, e.g. by
If GPU_ID is not specified, the first available GPU (ID 0) will be used by default.
+Storing a .gif for a trained network
+------------------------------------
+
+Once you have a snapshot of a network you can run
+
+ ./test_gpu <game name> <snapshopt filename>
+
+to make it play one game and store the .gif under `gifs`. For example
+
+ ./test_gpu breakout DQN3_0_1_breakout_FULL_Y.t7
+
Options
-------
View
@@ -123,6 +123,9 @@ while step < opt.steps do
-- Play game in test mode (episodes don't end when losing a life)
screen, reward, terminal = game_env:step(game_actions[action_index])
+ -- display screen
+ win = image.display({image=screen, win=win})
+
if estep%1000 == 0 then collectgarbage() end
-- record every reward

0 comments on commit 0da3745

Please sign in to comment.