Genetic Algorithm for best pokemon

Built With

Share this project:


posted an update

Further information regarding the submission:

This evolutionary algorithm is designed to provide good pokemon teams. In total there are 257,263,500,975,264,000 different ways to create a team with the total 800 pokemon. Therefore it is infeasible for a human to find the best team.

Being an evolutionary algorithm, it populates a group of teams and then manipulates that group via evolution to determine the best one. It does so with the following strategy: for(number of generations) select two parents from the population perform genetic crossover perform mutation add the best to the new population repeat

Crossover is a simple 1 point crossover, where half of the pokemon on Team 1 and Team 2 is given to the child team.

Mutation provides a 5% chance at each position in the team to replace the pokemon with a different one.

The next question is: how do we determine "good" teams?

The fitness function pits two teams against each other, in order to simulate an actual pokemon battle. Teams take turns playing with pokemon in the given order. Using the official pokemon damage formulas, pokemon continue to battle until one team has all of its pokemon eliminated.The function then reports the standing team as the better one.

Log in or sign up for Devpost to join the conversation.