JS Asteroids Automation Part 2 (Neural Network)
Mt. Ford Studios
In the second part of this JavaScript Asteroids Automation tutorial series, we set up our neural network! We write a “feedForward” function to send in data through the input layer, where it works its way through the hidden layer, and then finally pops out the other side from the output layer! We also write a “train” function to teach our network to handle the input data correctly by adjusting the weights incrementally. We add bias neurons to each layer, which are special nodes that are always set to “on” in order to improve the learning process. In the end, we test out our neural network by sending in XOR gate logic and seeing what happens!
Neural networks are a fairly advanced topic, so this tutorial series will (attempt!) to keep the complex theory to a minimum. Download the code below!
CODE Asteroids Automation Part 2 – Neural Network: https://drive.google.com/open?id=1_0rYsKM9XW8TOPVyFK8uM5Q9_1OzRY7A Neural Network JS Part 2 – NeuralNetwork class: https://drive.google.com/open?id=1ROSjAEHAGMTN6MDP1LDAln7xaZD0aCsV
GAME SOUND FILES https://drive.google.com/open?id=1iSykdpBCc7xafRFHrdH0mH4TeR5ansAc
USEFUL LINKS Artificial neural network: https://en.wikipedia.org/wiki/Artificial_neural_network XOR gate: https://en.wikipedia.org/wiki/XOR_gate Visual Studio Code: https://code.visualstudio.com/
FIND US ON FACEBOOK https://www.facebook.com/MountfordStudios/ ... https://www.youtube.com/watch?v=IgsJqrXtkKI
89335172 Bytes