Solved – How to verify that the ANN code is working properly

neural networks

First I'm not sure if this is the right place to post my question, but I saw some questions about ANN, and I assumed I can ask it here. I have implemented an ANN with back-propagation. I'm using it for Wi-Fi based indoor localization using fingerprinting. I saw many papers achieving accuracy below 2 m, so I hoped for such results but I didn't get it. My network is composed of input layer, 2 hidden layers, and output layer. The input layer has 14 neurons, each hidden layer has 8 neurons, and the output layer has 1 neuron. My sample space that I used to train the network is composed of 630 sample.

I trained the network using different configurations for the learning rate and training iterations. I didn't achieve any good results at all. The average accuracy I achieved was 24 m, which is really bad.

My questions:
1. How can I verify whether the problem is in my code or my ANN design?
2. How to improve on the design to get better results?
3. How to choose which learning rate to start with and how many iterations for training?

This is my first time dealing with ANN, and I didn't find any clear guidelines of how to design it.

Best Answer

In order to verify your back-propagation implementation you could compare your results to that achieved with a know correct back-propagation implementation.

I can recommend FANN (fast artificial neutral networks) as a cross platform open source implementation of back-propagation. http://leenissen.dk/fann/wp/. Though I'm sure the Matlab implimention is also very good if you have access to it.

As for training iterations you could use early stopping methods rather than keep varying the number of epochs http://page.mi.fu-berlin.de/prechelt/Biblio/stop_tricks1997.pdf.

As for the topology of the network. This question has been asked previously: How to choose the number of hidden layers and nodes in a feedforward neural network?

As for the learning rate you might need to do a little trial and error :)

Hope this helps.