Edouard360 / Halite-Python-RL

A fork of the Halite Starting Kit, aimed at providing an interface and debugging tools and for RL strategies (reinforcement learning).
6 stars 2 forks source link

Move state computation to tensorflow #12

Open Edouard360 opened 7 years ago

Edouard360 commented 7 years ago

Instead of computing the local states in python, and call sess.run for each square, we should do it on the tensorflow side, with a single call.

Another interesting thing to do would be to keep this strategy only for the border. To quickly analyse whether the point is at the border or not, we would need an operator doing something like:

    [ 0 0 0 0 ]                             [ 0 0 0 0 ]
    [ 0 1 1 1 ]                             [ 0 1 1 1 ]
X = [ 1 1 1 1 ]       to               X' = [ 1 0 0 1 ]
    [ 0 1 1 1 ]                             [ 0 1 0 1 ]
    [ 0 1 1 0 ]                             [ 0 1 1 0 ]