| Definition | Snake-Gym is a customizable RL environment for the classic Snake game, supporting dynamic grid sizes and multiple observation formats for Gymnasium-compatible agents. |
| No of environments | 102 |
Snake-Gym provides a reinforcement learning environment based on the classic Snake game, offering two observation formats: a 150×150 RGB image or a simplified 10×10 matrix representing the game state. In the game, the agent (snake) navigates through a grid, aiming to eat food while avoiding collisions with walls or its own body. The task challenges agents to maximize the snake’s length by learning optimal movement strategies. The environment supports random grid sizes, providing flexibility and variety in game configurations, challenging agents to adapt their strategies based on the size and complexity of the grid.
| Example observations | |
| Example actions | |
| Example reward |

