Teaching An AI To Play A Racing Game Via Screen Input

If you’re a fleshy human, you probably learn to play video games by looking at the screen and pressing the buttons, and maybe copying the way you’ve seen others play the game before. [tryfonaskam] has recently been trying to teach an AI to play games in much the same way.

[tryfonaskam] built PILA—short for Polytrack Imitation Learning Agent. As you might have guest from the name, it’s an AI agent designed to play a simple racing game called PolyTrack. Rather than manually programming the agent’s behavior, PILA instead trains itself through supervised learning, where it observes the gameplay state via screen capture and monitoring the keyboard inputs made by human players as they drive the tracks. It then uses this to guide its own behavior, and learns to play the game by itself. The model receives live frames from the graphics engine while playing, and then predicts the appropriate actions and makes the right keyboard inputs in turn to steer the car through the track.

This project reminds us of similar efforts to teach a raw AI how to play Trackmania, or the Drivatar technology in the Forza series of racing games.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.