Coder Social home page Coder Social logo

simple-genetic-algorithm's Introduction

Simple-Genetic-Algorithm

Installing dependencies

Run the following command in the project folder to install dependencies. If your system has both Python 2 and 3 installed, run pip if you are using Python 2 and pip3 for Python 3.
pip install -r dependencies.txt

Run the SGA

  1. In the project directory, run: python SGA-functions.py. Use python3 instead of python if you have both Python 2 and Python 3 installed.
  2. Follow the prompt and select the objective function to use and configurations.
  3. Once the algorithm finished running, some graphs and a summary will be created and stored in the results/ directory.

Visualize the fitness values live

  1. Go to the project directory and run the command: bokeh serve --show live_plot.py.
  2. A new tab will pop up in the browser with an empty plot.
  3. In a separate terminal, go to the project directory and follow the steps in the section above to run the algorithm.
  4. The mean and minimum fitness values of each generation will be displayed on the plot as the algorithm runs.
  5. If you are running the algorithm multiple times, the browser tab has to be refreshed before each run for the new data to be displayed.

simple-genetic-algorithm's People

Contributors

gandalf-rick-and-morty avatar vsutaria avatar ezhereshchin avatar franco-wong avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar James Tran avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.