You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Snake can see in 3 directions Left, Right, In front of snake
44
+
* Each direction takes up 3 vision inputs:
45
+
* first is for seeing apples which is binary 1/0 value (I tested 1/distance but it was a lot worse)
46
+
* second is distance to snake body if any was find in direction 1/distance rounded to 2 decimal points
47
+
* third is distance to walls 1/distance rounded to 2 decimal points
48
+
49
+
I was experimenting with snake looking behind himself but there wasn't any significant improvements there
50
+
51
+
### The most important thing with inputs is that you need to think where snake is looking and not where you look.
52
+
### So when snake is going to the right side of monitor and is looking up/front it means that it is looking to your right
53
+
### It feels obvious but believe me it isn't and after I changed how snake see things I saw the biggest improvement in learning speed
54
+
### head and tail direction is important after some point. Without these inputs my snake best score was 112
55
+
56
+
## Why snakes have different colours?
57
+
Colour of snake is based on some math in matrix (neural network) and it determines the snake colour. So basically in theory you can see how similar to each other snakes are (I wouldn't base any real informations on that :))
58
+
59
+
# How to run best snake for yourself
60
+
61
+
* download SnakeAi.jar from release
62
+
* download best.ser from release
63
+
* run SnakeAi.jar then press "l" (small L on keyboard)
0 commit comments