Menu

Post image 1
Post image 2
Post image 3
1 / 3
0

A CNN Grid Encoding for Snake AI That DOUBLES! the Best Published Score

DEV Community·Stat Phantom·about 1 month ago
#PNKrRgjd
Reading 0:00
15s threshold

A traditional Snake game grid has only 4 states each grid point can be in: empty, head, body, or apple. And for some reason every published Snake AI paper either throws away spatial information by condensing the game state into a handful of hand-picked numbers, or buries entity identity under layers of raw pixel data that the network has to untangle. Incredibly wasteful. The solution? Binary Plane Encoding. Using it, a CNN-based model reached a record score of 125 on a 20×20 grid in 2.5 hours on a single RTX 2070, doubling the best published result of 62 (even the average is consistently above this record). This post explains the encoding, why it works, and explores why nobody in the Snake DRL space has tried it before. The Two Camps The published literature on deep reinforcement learning for Snake spans 2018 to 2025 and splits into two approaches to state representation. Camp one: hand-crafted feature vectors. Sebastianelli et al. (2021) and Kommalapati et al.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More