All Projects → gmaggiotti → genetic_deep_learning

gmaggiotti / genetic_deep_learning

Licence: other
No description or website provided.

Programming Languages

Jupyter Notebook
11667 projects
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to genetic deep learning

NSGAII.jl
A NSGA-II implementation in Julia
Stars: ✭ 18 (+38.46%)
Mutual labels:  genetic-algorithm
Genetic-Algorithm-for-Job-Shop-Scheduling-and-NSGA-II
Learning how to implement GA and NSGA-II for job shop scheduling problem in python
Stars: ✭ 178 (+1269.23%)
Mutual labels:  genetic-algorithm
triangula
Generate high-quality triangulated and polygonal art from images.
Stars: ✭ 3,775 (+28938.46%)
Mutual labels:  genetic-algorithm
ASD-ML-API
This project has 3 goals: To find out the best machine learning pipeline for predicting ASD cases using genetic algorithms, via the TPOT library. (Classification Problem) Compare the accuracy of the accuracy of the determined pipeline, with a standard Naive-Bayes classifier. Saving the classifier as an external file, and use this file in a Flask…
Stars: ✭ 14 (+7.69%)
Mutual labels:  genetic-algorithm
snake-neural-network
An experiment with neural network and genetic algorithms
Stars: ✭ 68 (+423.08%)
Mutual labels:  genetic-algorithm
UnityGeneticAlgorithmMaze
Modern reimplementation in Unity of Bob's Map from AI Techniques for Game Programming
Stars: ✭ 37 (+184.62%)
Mutual labels:  genetic-algorithm
AI-Programming-using-Python
This repository contains implementation of different AI algorithms, based on the 4th edition of amazing AI Book, Artificial Intelligence A Modern Approach
Stars: ✭ 43 (+230.77%)
Mutual labels:  genetic-algorithm
opt4j
Modular Java framework for meta-heuristic optimization
Stars: ✭ 25 (+92.31%)
Mutual labels:  genetic-algorithm
snakeneuralnetworkjs
Neuroevolution of Neural Network for snakes in the Browser
Stars: ✭ 13 (+0%)
Mutual labels:  genetic-algorithm
EvOLuTIoN
A simple simulation in Unity, which uses genetic algorithm to optimize forces applied to cubes
Stars: ✭ 44 (+238.46%)
Mutual labels:  genetic-algorithm
Smart-Rockets
This project is a fun little demo of a genetic algorithm. A population of rockets attempt to find their way to a a target.
Stars: ✭ 15 (+15.38%)
Mutual labels:  genetic-algorithm
Super-Meta-MarIO
Mario AI Ensemble
Stars: ✭ 15 (+15.38%)
Mutual labels:  genetic-algorithm
darkgreybox
DarkGreyBox: An open-source data-driven python building thermal model inspired by Genetic Algorithms and Machine Learning
Stars: ✭ 25 (+92.31%)
Mutual labels:  genetic-algorithm
Drowsy
💤🖌️ AI making tiny Bitsy video games. Features an experimental generative structure inspired by GANs and Genetic Algorithms
Stars: ✭ 19 (+46.15%)
Mutual labels:  genetic-algorithm
Savior
(WIP)The deployment framework aims to provide a simple, lightweight, fast integrated, pipelined deployment framework for algorithm service that ensures reliability, high concurrency and scalability of services.
Stars: ✭ 124 (+853.85%)
Mutual labels:  deeplearning
A-quantum-inspired-genetic-algorithm-for-k-means-clustering
Implementation of a Quantum inspired genetic algorithm proposed by A quantum-inspired genetic algorithm for k-means clustering paper.
Stars: ✭ 28 (+115.38%)
Mutual labels:  genetic-algorithm
neuro-evolution
A project on improving Neural Networks performance by using Genetic Algorithms.
Stars: ✭ 25 (+92.31%)
Mutual labels:  genetic-algorithm
gan deeplearning4j
Automatic feature engineering using Generative Adversarial Networks using Deeplearning4j and Apache Spark.
Stars: ✭ 19 (+46.15%)
Mutual labels:  deeplearning
awesome-conformal-prediction
A professionally curated list of awesome Conformal Prediction videos, tutorials, books, papers, PhD and MSc theses, articles and open-source libraries.
Stars: ✭ 998 (+7576.92%)
Mutual labels:  deeplearning
jGeneticNeuralNet
A Java library that trains neural networks with a genetic algorithm.
Stars: ✭ 16 (+23.08%)
Mutual labels:  genetic-algorithm

Genetic Deep Learning

Codacy Badge build Coverage Status GitHub license pv

This project aims to use genetic algorithms to boost the learning of DNN. Building and training a family of NN with same structure and hyperparameters from scratch but starting from different random weights. After a few epochs of training, the networks that perform better are chosen and crossover their weights in order to mating and produce the next generation.

Main problems to solve with NN:

  • Architecture optimization:finding optimal layers and number of nodes in each layer of the network required to capture features from given data.
  • Hyperparameter optimization: refers to choosing values of hyperparameters like - learning rate, optimization algorithm, dropout rate, batch size, etc.
  • Weight optimization: find the right values for each neuron within each weight in order to solve the general equation with a minimum error.

This project is focused on solving weight optimization, using Genetic Algorithms combined with Gradient Descent and implement a method to make the process faster.

Intuition of how gradients of the new generations improves the chosen slope when mating the fittest

The ”Survival of the Fittest” scheme, proposed by Charles Darwin in his Theory of Natural Selection, is used. The mating process takes place after every ’n’ epoch, in this example n=600. After the first generation of parents are trained for ’n’ iterations, their dominance is calculated based on their ability to reduce loss. Networks that achieve less loss are selected to create the new generation.

Comparison of the loss of the GDNN, choosing the best NN within each generation (where each generations occurs within 600 epochs), vs the loss of DNN.

Set-up

git clone https://github.com/gmaggiotti/genetic_deep_learning

pip install -r requirements.txt

Example Usage

from NN3 import NN3
from sklearn.model_selection import train_test_split
from nn_utils import run_GDNN_model, read_dataset

X, Y = read_dataset(180, 500)
dataset = train_test_split(X, Y, test_size=0.3, random_state=1)

epochs = 600
population_size = 20
generations = 10

run_GDNN_model(NN3, epochs, population_size, generations, dataset)

results:

600,0.168544190248,0.853358180509,0.365456152434
1200,0.190101287106,0.86226507466,0.351355096229
1800,0.171879024117,0.845500071458,0.373490978584
2400,0.197814229677,0.843125854644,0.376948511977
3000,0.175281053543,0.846390250419,0.374509228029
3600,0.174354637606,0.846694537943,0.371549666719
4200,0.177174209814,0.854009316851,0.367267148903
4800,0.153127387675,0.856748424631,0.35567444011
5400,0.145970882656,0.859319560831,0.349651657185
6000,0.145480255007,0.859810989131,0.349801966101

Linting

Versioning

  • pylint 2.2.2
  • astroid 2.1.0
  • autopep8 1.4.3 (pycodestyle: 2.4.0)

Linting scripts

  • Error check: pylint src
  • Error fix: autopep8 --in-place --aggressive --aggressive src

Copyright (c) 2018 Gabriel A. Maggiotti

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].