Skip to content

This project is all about using NEAT algorithm to perform neuroevolution in order to make an AI agent for the game "Sway".

Notifications You must be signed in to change notification settings

suprasauce/Sway

Repository files navigation

Sway

This project titled “Sway” approaches the idea of neuroevolution by using the NEAT algorithm to point towards an optimal solution for the given task. The environment is set up as a virtual simulation in an accelerated time frame and NEAT is performed over generations until a solution is achieved. The task involves determining various dynamic values which help propagate the motion of entities in the virtual simulation towards a favourable direction leading to an optimum.

Dark purple coloured square represents the human playing, while the other light purple coloured squares represent different AI agent's playing. The task is to hit the red colored square box.

Installation

Windows

  1. Clone the project on your local machine in your prefered directory by typing the following command in git bash/ Powershell/ CMD (or download the file yourself)
git clone https://github.com/suprasauce/Sway.git
  1. Install python for windows if you don't have it (preferably python 3.8+). Activate a virtual environment in Powershell/ CMD by either installing virtualenv and following its instructions to make a virtual environment, or by using the venv package which comes with python by default
python -m venv env

This will make a folder named env. Then type

(Powershell)

path_where_env_is_stored\env\Scripts\Activate.ps1

(CMD)

path_where_env_is_stored\env\Scripts\activate
  1. Go to the project directory
    To install all the dependencies, run
pip install -r requirements.txt
  1. Run the game.py file by typing the following command in CMD/ Powershell (make sure virtual env is activated) in the directory where you cloned the folder
python game.py

Reference

https://nn.cs.utexas.edu/downloads/papers/stanley.ec02.pdf

About

This project is all about using NEAT algorithm to perform neuroevolution in order to make an AI agent for the game "Sway".

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages