Subscribe To Robotics | IntroDuction | History | Home


Friends Dont Forget To check the archieve at the left end of the page



Make Your Own Robot Tutoials



Simple Beetle Bot | Wired Robot | Combat Robot | Solar Engine |



Beam Symet | Photopopper | Beam Trimet | Line Follower |

Latest Updates
Driver Less Car | I-Sobot | MotherBoard | MicroController | Artificial Brain |

Camera Sensors Hardware | Remote Control Working

Google

Friday, April 18, 2008

Neural Network Example

A simple example for testing a neural network implementation is trying to
learn the digits 0..9 from a seven-segment display representation. Figure 19.8
shows the arrangement of the segments and the numerical input and training
output for the neural network, which could be read from a data file. Note that
there are ten output neurons, one for each digit, 0..9. This will be much easier
to learn than e.g. a four-digit binary encoded output (0000 to 1001).



Figure 19.9 shows the decrease of total error values by applying the backpropagation
procedure on the complete input data set for some 700 iterations.
Eventually the goal of an error value below 0.1 is reached and the algorithm
terminates. The weights stored in the neural net are now ready to take on previously
unseen real data. In this example the trained network could e.g. be tested
against 7-segment inputs with a single defective segment (always on or always
off).



Neural Controller

Control of mobile robots produces tangible actions from sensor inputs. A controller for a robot receives input from its sensors, processes the data using relevantlogic, and sends appropriate signals to the actuators. For most large tasks, the ideal mapping from input to action is not clearly specified nor readily apparent. Such tasks require a control program that must be carefully designed and tested in the robot’s operational environment. The creation of these control programs is an ongoing concern in robotics as the range of viable application domains expands, increasing the complexity of tasks expected of autonomous robots.

A number of questions need to be answered before the feed-forward ANN in Figure can be implemented. Among them are: How can the success of the network be measured? The robot should perform a collision-free left-wall following.

How can the training be performed?

In simulation or on the real robot.

What is the desired motor output for each situation?

The motor function that drives the robot close to the wall on the left-hand
side and avoids collisions.

Neural networks have been successfully used to mediate directly between
sensors and actuators to perform certain tasks. Past research has focused on
using neural net controllers to learn individual behaviors. Vershure developed
a working set of behaviors by employing a neural net controller to drive a set
of motors from collision detection, range finding, and target detection sensors
[Vershure et al. 1995]. The on-line learning rule of the neural net was designed
to emulate the action of Pavlovian classical conditioning. The resulting controller
associated actions beneficial to task performance with positive feedback.
Adaptive logic networks (ALNs), a variation of NNs that only use boolean
operations for computation, were successfully employed in simulation by
Kube et al. to perform simple cooperative group behaviors [Kube, Zhang,
Wang 1993]. The advantage of the ALN representation is that it is easily mappable
directly to hardware once the controller has reached a suitable working
state.
In Chapter 22 an implementation of a neural controller is described that is
used as an arbitrator or selector of a number of behaviors. Instead of applying a
learning method like backpropagation shown in Section 19.3, a genetic algorithm
is used to evolve a neural network that satisfies the requirements.

NEURAL NETWORKS

The artificial neural network (ANN), often simply called neural network(NN), is a processing model loosely derived from biological neurons [Gurney 2002]. Neural networks are often used for classification problems or decision making problems that do not have a simple or straightforward algorithmic solution. The beauty of a neural network is its ability to learn an input to output mapping from a set of training cases without explicit programming, and then being able to generalize this mapping to cases not seen previously. There is a large research community as well as numerous industrial users
working on neural network principles and applications [Rumelhart, McClelland 1986], [Zaknich 2003]. In this chapter, we only briefly touch on this subject and concentrate on the topics relevant to mobile robots.

Neural Network Principles:

A neural network is constructed from a number of individual units called neurons that are linked with each other via connections. Each individual neuron has a number of inputs, a processing node, and a single output, while each connection from one neuron to another is associated with a weight. Processing in a neural network takes place in parallel for all neurons. Each neuron constantly (in an endless loop) evaluates (reads) its inputs, calculates its local activation value according to a formula shown below, and produces (writes) an output value.

The activation function of a neuron a(I, W) is the weighted sum of its inputs, i.e. each input is multiplied by the associated weight and all these terms are added. The neuron’s output is determined by the output function o(I, W),for which numerous different models exist.In the simplest case, just thresholding is used for the output function. For our purposes, however, we use the non-linear “sigmoid” output function
defined in Figure 19.1 and shown in Figure 19.2, which has superior characteristics for learning (see Section 19.3). This sigmoid function approximates the Heaviside step function, with parameter 􀁕 controlling the slope of the graph
(usually set to 1).






Feed-Forward Networks:

A neural net is constructed from a number of interconnected neurons, which are usually arranged in layers. The outputs of one layer of neurons are connected to the inputs of the following layer. The first layer of neurons is called the “input layer”, since its inputs are connected to external data, for example sensors to the outside world. The last layer of neurons is called the “output layer”, accordingly, since its outputs are the result of the total neural network and are made available to the outside. These could be connected, for example, to robot actuators or external decision units. All neuron layers between the input layer and the output layer are called “hidden layers”, since their actions cannot be observed directly from the outside.

If all connections go from the outputs of one layer to the input of the next layer, and there are no connections within the same layer or connections from a later layer back to an earlier layer, then this type of network is called a “feedforward network”. Feed-forward networks (Figure 19.3) are used for the simplest types of ANNs and differ significantly from feedback networks, which we will not look further into here.




For most practical applications, a single hidden layer is sufficient, so the typical NN for our purposes has exactly three layers:

• Input layer (for example input from robot sensors)

• Hidden layer (connected to input and output layer)

• Output layer (for example output to robot actuators)

Perceptron Incidentally, the first feed-forward network proposed by Rosenblatt had only two layers, one input layer and one output layer [Rosenblatt 1962]. However, these so-called “Perceptrons” were severely limited in their computational power because of this restriction, as was soon after discovered by [Minsky,Papert 1969]. Unfortunately, this publication almost brought neural network research to a halt for several years, although the principal restriction applies only to two-layer networks, not for networks with three layers or more. In the standard three-layer network, the input layer is usually simplified in the way that the input values are directly taken as neuron activation. No activation function is called for input neurons.