Using Artificial Neural Networks in Phaser games.

Article by Richard Davey. Posted on 15th Aug 2016.   @phaser_

image

From Glenn De Backer: "For a game project I needed to recognize certain drawings and that preferably in javascript as it`s a web game. There are multiple solutions for tackling this problem and the use of a neural network is one of them.

Neural networks was for a long time something that I understood conceptually, but found very daunting to use. As a result experiences that I had with recognizing things were mostly built around support vector machines.

The problem was that at the moment of writing I didn’t found a suitable SVM JavaScript library that worked at the client side. I did however find some ANN libraries, so it was time to try tackling it once and for all.

But what are neural networks ?

An ANN (Artificial Neural Networks) is simply put a computational model that is inspired by biological neural networks that (among other things) can be used to recognize patterns or simple drawings in my case.

With that in mind it’s important to note that an ANN is just a model and not a complete simulation of how a brain works. But like a biological neuron the artificial version has some inputs (dendrites), a part (soma) that processes those inputs and certain outputs (axon)."

Read More