Behave or Else!

Project Summary. Weeks 1 & 2 were primarily spent working out the tools to use and finding resources to learn more about neural networks, their applications and the finer points on how exactly they were implemented. My original Plan had be to use the Unity 3d engine to build the environment, the vehicle and the network. As I began to look into the implementation of NN(Neural Networking), I decided it would limit my capacity to achieve my goal. Primarily there was little to no prior support for NN in Unity nor any kind of learning material in C# for this purpose. This meant it would take much more work in a programming language I am barely familiar with, and I suspected I would run into many more problems if I continued.

I found a couple on online texts created with the purpose of introducing the concepts of Neural Networking. The first was this http://neuralnetworksanddeeplearning.com/about.html. This online book/website taught using an example of an image recognition system used to read print written in Python. Though the application was completely different from what I intended to do I felt that it might be a worthwhile look into the general data structure of this particular branch of AI especially since there was a focus on how Neural Networks implemented learning functions and methods. While this book didn’t end up being terribly helpful in learning about implementation I do feel it gave me a more developed conceptual understanding of What NN is and how it works. I did however find a resource that proved to be invaluable to learning about implementation; The Nature of Code by Daniel Schiffman. This text taught through practical exercises and used Processing, a programming tool that ran on java but simplified things for easy drafting. It had an entire chapter on NN focussing on the most basic implementations and even included an example of implementing an example of a self-steering vehicle. I got to work building a simple vehicle class and some obstacle/targets. With which to build a simple 2-d environment to use in testing. If everything went well I could later upgrade to a 3-d environment.

Following along the exercises gave me great insight into how the most basic part of NN, the Perceptron functioned and how to implement it in a simple processing sketch. Progress was admittedly slow in developing a functional understanding of implementation in part due to divided attention among other assignments. To balance the slow progress, as if Daniel Schiffman knew exactly what I was trying to accomplish the chapter taught me a most useful piece of information. If we already had the answers to the questions we pose to the Perceptron, we can implement a training algorithm to replace manually training the Perceptron with accumulated test data. This essentially allowed me to bypass gathering data from test drivers (i.e real people). Instead I simply needed to include calculations in a training function that would allow the perceptron to adjust itself incrementally towards a ‘correct’ value. Getting it to work however was another matter entirely. A single perceptron can by itself steer a vehicle by taking in Vector values that represent forces and outputting a single value representing the mean steering force to move the Vehicle. This much had been made apparent from the demonstrations within the Chapter. My personal Experience was less successful. The results of my own programming are remarkably unpredictable, bogged with glitches and strange behaviours.

On occasion a vehicle would successfully steer it’s way into a target circle. However a more typical happening was that they would rapidly oscillate their direction before locking either east or west, before disappearing with their location co-ordinates returning NaN.

the vehicle moves towards the target
multiple vehicles, one successfully reaches it's target
"Charging Warp Drive"
as the vehicle diappears console prints for the location return "NaN"

In Conclusion, Though I myself did not reach the expected outcome and failed to successfully implement a NN that could steer a vehicle I feel like this project was nonetheless a success. Through research and practical exercise I feel I can answer the question posed within this Project: Can a Neural Network learn to avoid hazards in a 3d environment? Most Definitely. A single perceptron can accept input for all the various conditions and forces at play and in response generate a steering force guiding a simulated autonomous vehicle to avoid an obstacle in a 2-d environment. It is a logical extension that a more powerful network of neural objects could easily learn to navigate complex 3d environments. Such a cases are indeed already widespread and see use in a great number of real world applications as shown in the project proposal