Snake DQN (10Γ—10)

Double DQN agents from github.com/Nipuna-Lakruwan/snake-rl. State dicts for snake_rl.dqn.qnet(n_in, 256), an MLP n_in β†’ 256 β†’ 256 β†’ 3 over relative actions (straight / left / right).

File Observation Test mean apples (500 games)
dqn_flood_seed0.pt flood (20 features) 51.9 (best 97 = full board)
dqn_flood_seed1.pt flood 48.4
dqn_flood_seed2.pt flood 49.6
dqn_classic_seed{0,1,2}.pt classic (11 features) 18.9 / 18.8 / 19.0

Baselines: greedy 18.3, greedy + flood fill 30.8, random 0.2.

import torch
from snake_rl.dqn import qnet, policy_from
from snake_rl.evaluate import play, summary
q = qnet(20, 256); q.load_state_dict(torch.load("dqn_flood_seed0.pt")); q.eval()
print(summary(play(policy_from(q, "flood"))))
Downloads last month

-

Downloads are not tracked for this model. How to track
Video Preview
loading