| Definition | Evader is a reinforcement learning project where an agent learns to dodge falling objects using raycasts and policy gradients. |
| No of environments | 1 |
Evader is a reinforcement learning (RL) project where an RL agent learns to dodge falling objects in a custom game, using the tf-agents library. The agent, represented by a purple ball, navigates its environment by observing six raycasts that provide distance measurements, and it can take one of three actions: moving left, moving right, or doing nothing. The episode ends if the agent collides with a falling object or the side walls. The environment setup allows the agent to improve its decision-making process over time by receiving rewards for surviving and avoiding obstacles.
The training process uses the Policy Gradients algorithm, specifically the reinforce-agent from tf-agents, to refine the agent’s strategy. The agent receives a positive reward for surviving each timestep and avoiding obstacles, and a negative reward when it collides with a ball or a wall. Through repeated training episodes, the agent learns to predict which actions maximize its survival and reward. The model successfully improves over the course of 300-500 training episodes, achieving better performance than the developer within approximately 30 minutes on a standard laptop.

