Artificial Neural Networks: System That Can Acquire, Store, and Utilize Experiential Knowledge
Artificial Neural Networks: System That Can Acquire, Store, and Utilize Experiential Knowledge
Artificial Neural Networks: System That Can Acquire, Store, and Utilize Experiential Knowledge
• The Machine
– Calculation
– Precision
– Logic
Overview
The Brain
Brain vs.. Computers
The Perceptron
Multi-layer networks
Some Applications
The contrast in architecture
• The Von Neumann
architecture uses a single
processing unit;
– Tens of millions of operations
per second
– Absolute arithmetic precision
synapse axon
nucleus
cell body
dendrites
The Structure of Neurons
A neuron has a cell body, a branching input
structure (the dendrIte) and a branching output
structure (the axOn)
wjn
an
General Symbols
Synaptic
w1 Connections
x1
w2
x2
w3 O
x3 f(wx)
wn Neuron’s
xn
processing node
Multiplicative Weights
W=[ w1,w2,…wn ]T
X=[x1,x2,…xn]T
O f (W T X )
n
O f wi xi
i 1
Activation functions
Continuous model – Bipolar - sigmoid
2
f (net )
1 exp( net )
1 -Bipolar continuous
1
f (net ) -Unipolar continuous
1 exp( net )
Activation functions
Discrete model – Bipolar -hard limit
Learning Signal d
Generator
Supervised Learning
x O
Neural Network
Unsupervised Learning
Supervised Vs
Unsupervised
Training and test data sets
Training set; input & target
Training data
Y • • •
• •
• • •
• • •
• •
• •
xT X
Neuro Processing
Association response–auto association–hetero association
Input
Pattern { O}
Input Output
Pattern Pattern
{• }
{ O •
} Distorte Rhomboi
d Square {X 8} d
Distorte Square
d Square
Auto association Hetero association
Classification response – classification - recognition
Input Class
Input Class
Pattern member
Pattern member
1
1 { X •
} 1
{ X •
} 1
recognition
classification
Learning in Neural
Networks
Learn values of weights from I/O pairs
Start with random weights
Load training example’s input
Observe computed input
Modify weights to reduce difference
Iterate over all training examples
Terminate when weights stop changing OR when
error is very small
Single perceptron as
classifier
What is net doing while learning?
Consider two input one output network
x1 w1
O1=1 or 0
f
x2 w2
w1x1+w2x2>0 class 1 : o1=1
w1x1+w2x2<0 class 2 : o1=0
x2
x x
w1x1+w2x2=0
x x
x1
W WXT=0
o o
W is
perpendicular
o o
to X
In practical application line may not pass through
origin
Bias is used to achieve this
Bias also needs to train
Conclusion: Classes must be linearly separable
Example
x2
Construct ANN to solve AND gate
P X1 X2 D X
1 0 0 -1
2 0 1 -1
x1
3 1 0 -1
4 1 1 +1
x1 w1
O1=1 or -1
f
x2 w2
w0
Boundary
w1x1+w2x2-
-1 w0=0
world is not that simple…
x2
Ex-OR gate
X
P X1 X2 D
1 0 0 -1
2 0 1 +1 X
x1
3 1 0 +1
4 1 1 -1
X o1=sgn(-2x1+x2-1/2)
x1 o2=sgn( x1-x2-1/2)
Image space
Pattern Space Image Space Class
x1 x2 o1 o2 -
0 0 -1 -1 2 x1
-2 o1
0 1 1 -1 1 f
1
1 0 -1 1 1
1 o2
-1
1 1 -1 -1 2
x2 f
1/2
1/2
-1
Image Space
o2 o3>0
03=sgn(o1+o2+1)
o1
o1 1 o3
f
o2 1
-1
o3<0 o3=0 -1
Finally…
Pattern Space Image Space o1+o2+1 03 Class
x1 x2 o1 o2 - - -
0 0 -1 -1 -ve -1 2
0 1 1 -1 +ve +1 1
1 0 -1 1 +ve +1 1
1 1 -1 -1 -ve -1 2
Two Layer Network
o1
x1 -2 f 1
1 o3
f
1
o2 1
x2 -1 f -1
1/2
1/2
-1
-1
Learning Rules
General Rule: Weight vector increases in proportion to the
product of input X and learning signal r,
where r = r(wi,X,di) so
change in weight = [cr(wi,X,di)] X, C learning constant
x1
oi
: f
xn
w
r Learning signal
X generator di
c
1. Hebbian learning rule
In this rule learning signal r is,
r f (WiT X )
y f (V Z )
T
For j=1,2,…,J V is the col vector and j row of V.
j
th
O f (W Y )
T
For k=1,2,…K W is a col vector and k row of W.th
E 0.5(d o ) E 2
6.Hidden layer
p pweights
1, q q 1are
adjusted:
E 0, p 1
10 10 10
8 8 8
NN are able to generalise
learning involves generating a partitioning of the input
space
for single layer network input space must be linearly
separable
what is the dimension of this input space?
how many points in the input space?
this network is binary(uses binary values)
networks may also be continuous
ALVINN
Drives 70 mph on a public highway
30 outputs
for steering
30x32 weights
4 hidden
into one out of
units
four hidden
30x32 pixels unit
as inputs
Stock market prediction