×

Srdjan Susnic's video: Machine Learning for Flappy Bird using Neural Network Genetic Algorithm

@Machine Learning for Flappy Bird using Neural Network & Genetic Algorithm
Read the complete tutorial about how to implement a machine learning algorithm for the Flappy Bird video game here: http://www.askforgametask.com/tutorial/machine-learning-algorithm-flappy-bird This video shows a creation of an artificial intelligence controller for the Flappy Bird game using neural networks and a genetic algorithm. The program is written in HTML5 using Phaser framework (http://phaser.io/). There is also used Synaptic Neural Network library (https://synaptic.juancazala.com/) to implement entire artificial neural network instead of making a new one from the scratch. Download source code here: https://github.com/ssusnic/Machine-Learning-Flappy-Bird ----------------------------------------------------------------- According to Arthur Samuel, machine learning is the science of getting computers to act without being explicitly programmed. It is a fine tuning process of learning that incrementally improves an initial random system. The form of machine learning implemented in this program uses a genetic algorithm to train artificial neural networks. The birds are learning how to flap optimally in order to fly safely through barriers as long as possible. The main concept is based on these 3 steps: 1. creating the initial population of 10 birds randomly 2. learning as the game is being played 3. applying natural evolution to form the next improved population ----------------------------------------------------------------- To play the game, each bird has its own neural network consisted of the next 3 layers: 1. an input layer with 2 neurons representing what a bird sees: - horizontal distance to the closest gap - height difference to the closest gap 2. a hidden layer with 6 neurons 3. an output layer with 1 neuron to perform flap if its value is greater than 0.5 ----------------------------------------------------------------- To measure the quality of birds and select the best ones, for each bird is calculated its fitness function in this way: - reward a bird by its total traveled distance - penalize a bird by its current distance to the closest gap When the entire population is dead, the fittest four birds are selected to breed a new population by using genetic algorithm operators: selection, crossover and mutation. ----------------------------------------------------------------- Visit us: http://www.askforgametask.com Like us: https://www.facebook.com/askforgametask Follow us: https://twitter.com/ssusnic Music: "Bedtime Tune" by Jay Man http://www.ourmusicbox.com

10.9K

639
Srdjan Susnic
Subscribers
3.3K
Total Post
22
Total Views
879.1K
Avg. Views
40K
View Profile
This video was published on 2017-08-10 21:34:41 GMT by @Srdjan-Susnic on Youtube. Srdjan Susnic has total 3.3K subscribers on Youtube and has a total of 22 video.This video has received 10.9K Likes which are higher than the average likes that Srdjan Susnic gets . @Srdjan-Susnic receives an average views of 40K per video on Youtube.This video has received 639 comments which are higher than the average comments that Srdjan Susnic gets . Overall the views for this video was lower than the average for the profile.Srdjan Susnic #MachineLearning #NeuralNetwork #ArtificialIntelligence #MachineLearningAlgorithms #AI #DataScience #Tensorflow #JavaScript has been used frequently in this Post.

Other post by @Srdjan Susnic