On the eve of PAC-MAN’s 40th anniversary, the researchers at the prominent tech giant, NVIDIA, teamed up with MIT, the University of Toronto and Vector Institute to build a new AI model known as GameGAN to recreate the gaming environment of PAC-MAN. The interesting side of this research is that the AI not only just plays PAC-MAN but also creates its own gameplay by watching the game without the need for a game engine.
Seung-Wook Kim, a researcher at NVIDIA and lead author of the project, said in a blog post, this is the first research to emulate a game engine using GAN-based neural networks. They wanted to see whether the AI could learn the rules of an environment just by looking at the screenplay of an agent moving through the game and it did.
Behind GameGAN
GameGAN is a powerful new AI model created by NVIDIA Research that is trained on 50,000 episodes of the PAC-MAN game. The model has the capability to generate a fully functional version of PAC-MAN, without any underlying game engine. This means that even without understanding the fundamental rules of a game, this AI model can recreate the game with convincing results.
According to the researchers at NVIDIA, GameGAN is the first neural network model that mimics a computer game engine by harnessing generative adversarial networks, or GANs. GAN-based models comprise of two competing neural networks that are a generator and discriminator. The model learns how to create new content that’s convincing enough to pass for the original.
Japanese multinational video game developer and publisher, Bandai Namco Entertainment Inc. provided the data of PAC-MAN in order to train the GameGAN model. With this data, the researchers at the NVIDIA AI Research Lab in Toronto used NVIDIA DGX systems to train neural networks on the PAC-MAN episodes that include a total of a few million frames, which are paired with data on the keystrokes of an AI agent playing the game.
After training, the GameGAN model then generates static elements of the environment, for instance, a consistent maze shape, dots as well as Power Pellets, including moving elements like the enemy ghosts and PAC-MAN itself.
How GameGAN Works
When an artificial agent plays the GAN-generated game, the GameGAN model responds to the actions of the agents by generating new frames of the game environment in real time. If this GAN model is trained on screenplays from games with multiple levels or versions, the model can even generate game layouts, which it has never seen before.
Instead of a traditional game engine, the GameGAN model relies on neural networks to generate PAC-MAN’s environment. Also, the AI keeps track of the virtual world while remembering what’s already been generated to maintain visual consistency from frame to frame. The neural network model can learn its rules simply by ingesting screen recordings and agent keystrokes from past gameplay.
Benefits Of GameGAN
- According to Koichiro Tsutsumi from BANDAI NAMCO Research Inc., this research presents exciting possibilities to help game developers accelerate the creative process of developing new level layouts, characters and even games
- The game developers could use this AI tool to automatically design new level layouts for existing games, using screenplay from the original levels as training data
- Since the GameGAN model can disentangle the background from the moving characters, one can recast the game with favourite emoji to take place in an outdoor hedge maze or swap out PAC-MAN. This capability can be used by the game developers to experiment with new character ideas or game themes
Wrapping Up
Creating a simulator is a time-consuming process for developers, who must code rules about how objects interact with one another and how light works within the environment. According to the researchers, the GameGAN model introduces the possibility that the work of writing a simulator for tasks like these could one day be replaced by simply training a neural network.