Predator Prey Simulation (Updated April 2023)
I wanted to try my hand in a re-enforcement learning project, so decided to try my hand at simulating predator/prey relationships.
This is one of my largest projects, involving the creation of nearly 4000 lines of code covering object oriented programming, machine learning, simulation optimization, and re-enforcement learning.
The high end description of this project is simple - create a 2D simulation with predator objects that seek to hunt down prey objects, and prey that seek to not be eaten. The prey will also require food, which will be static circles that nourish them. This will require many things from these character objects - including the ability to interpret the simulated world around them, analyze their situation, and change their behavior accordingly. Not only this, but we need the simulation itself to be highly efficient to see major changes in behavior. I could have used a language other than python if I was concerned with efficiency (such as C/C++), however I was more interested in practicing my skills using python's native object oriented tools.
Like Some Technical Details? Start at the simulation box and character objects.
Want to jump into the interesting machine learning bits? Go to vision and training.
Pages in progress - Results and full simulation videos.