How to play Pokémon with reinforcement learning

AI playing Pokémon isn’t new and the quest continues to get it to play all the way through and actually beat the Champion. But while we wait to see if that’s achievable, we have Peter Whidden and his phenomenal use of machine learning to play Pokémon Red.

Whidden used a technique known as reinforcement learning where you let a model try to complete a task and reward it every time it gets something right (the reinforcement part). Then, it will “learn” which ways are good and which ways should be avoided to try and find the optimal path of success. That’s the crude explanation anyway so I implore you to watch the video to get a full scope of what reinforcement learning involves. You can also read one of our articles on neural networks used to teach a bot to play Super Mario Kart by itself for a similar idea of what’s happening here.

In the above video, you can see how Whidden built a Python model to not only get Red out of Pallet Town, which is remarkable in itself, but it managed to catch Pokémon and defeat Brock! That’s incredible work, outside of something like Twitch Plays Pokémon or a TAS bot; even a bot with randomised inputs would struggle. But the amazing thing is, this all took around 50,000 hours to do. That’s roughly over 5 years of work. Let that sink in.

Leave a Reply

Your email address will not be published. Required fields are marked *