|
bitsim
Model, simulate, estimate and control robots in C++
|
Functions | |
| read (path, side) | |
| where (plane) | |
| draw (board, side, title, trail) | |
| main () | |
Variables | |
| dict | ACTIONS = {-1: "start", 0: "up", 1: "down", 2: "left", 3: "right"} |
| list | PIECES = [("goal", 1, "#f4c542"), ("pit", 2, "#d1495b"), ("wall", 3, "#555555")] |
Make a GIF of episodes on bitrl's Gridworld. The DQN examples write episode.csv after training: a row for every step, the episode, the action that led to the board (-1 for the first board), the reward and the board, 4 x side x side values: a one-hot plane each for the player, the goal, the pit and the wall, row by row. Usage: python grid_world_gif.py episode.csv --out dqn.gif [--title DQN] [--side 4] [--episodes 1,2,0] Needs matplotlib and imageio.
| grid_world_gif.draw | ( | board, | |
| side, | |||
| title, | |||
| trail ) |
| grid_world_gif.main | ( | ) |
| grid_world_gif.read | ( | path, | |
| side ) |
| grid_world_gif.where | ( | plane | ) |
| dict grid_world_gif.ACTIONS = {-1: "start", 0: "up", 1: "down", 2: "left", 3: "right"} |
| list grid_world_gif.PIECES = [("goal", 1, "#f4c542"), ("pit", 2, "#d1495b"), ("wall", 3, "#555555")] |