SlideShare ist ein Scribd-Unternehmen logo
1 von 41
Downloaden Sie, um offline zu lesen
Parveen Malik
Assistant Professor
KIIT University
Neural Networks
Text Books:
• Neural Networks and Learning Machines – Simon Haykin
• Principles of Soft Computing- S.N.Shivnandam & S.N.Deepa
• Neural Networks using Matlab- S.N. Shivanandam, S. Sumathi ,S N Deepa
What is Neural Network ?
“A neural network is a massively parallel distributed processor made
up of simple processing units that has a natural propensity for storing
experiential knowledge and making it available for use.”
It resembles the brain in two respects:
1. Knowledge is acquired by the network from its environment
through a learning process.
2. Interneuron connection strengths, known as synaptic weights, are
used to store the acquired knowledge.
Neural Network
Why we need Neural Networks ?
 Object Detection
 Visual Tracking
 Image Captioning
 Video Captioning
 Visual Question Answering
 Video question answering
 Video Summarization
 Generating Authentic Photos
 Facial Expression detection
Machine
Learning
Visual
Pattern
Recognition
Natural
Language
Processing
 Language Modelling
 Text prediction
 Speech Recognition
 Machine Translation
 C-H conversation
Modelling
Time series
Modelling
 Share Market Prediction
 Weather Forecasting
 Financial Data analytics
 Mood analytics
Machine Learning and Beyond
More Applications
Aerospace Defence
 High performance aircraft
autopilot
 Flight path simulations
 Aircraft control system
 Autopilot enhancements
 Aircraft component simulations
 Aircraft component detectors.
 Weapon steering
 Target tracking
 Object discrimination
 Facial recognition
 New kind of sensors
 Sonar
 Radar signal processing
 image signal processing
 Data compression
 Feature extraction
 Noise suppression
Manufacturing
 Manufacturing process control
 Product design and analysis
 Process and machine diagnosis
 Real time particle identification
 Visual quality inspection systems
 Wielding analysis
 Analysis of grinding operations
 Chemical product design, analysis
 Machine maintenance analysis
 Project bidding planning and management
 Dynamic modelling of chemical process systems.
Medical Entertainment
 Breast cancer cell analysis
 EEG and ECG analysis
 Prosthesis design
 Optimization of transplant times
 Hospital expense reduction
 Hospital quality improvement
 Emergency room test
advisement
 Animation
 Special effects
 Market forecasting
Electronics
 Code sequence prediction
 Integrated circuit chip layout
 Process control
 Chip failure analysis
 Machine vision
 Voice synthesis
 Non-linear modelling
Applications
Financial Telecommunications
• Real estate appraisal
• Loan advisor
• Mortgage screening
• Corporate bond rating
• Credit line use analysis
• Portfolio trading program
• Corporate financial analysis
• Currency price prediction
• Image and data compression
• Automated information services
• Real time translation of spoken language
• Customer payment processing systems
Securities
• Market analysis
• Automatic bond rating
• Stock trading advisory systems
Automotive Banking
• Automobile automatic guidance systems
• Warranty activity analysers
• Check and other document readers
• Credit application evaluators
Insurance
 Policy application evaluation
 Product optimization
Robotics
• Trajectory control
• Forklift robot
• Manipulator controllers
• Vision systems
Speech Transportation
• Speech recognition
• Speech compression
• Vowel classification
• Text to speech synthesis
• Truck brake diagnosis systems
• Vehicle scheduling
• Routing systems
Central Nervous System
Human Brain and Neuron
CNS- Brain and Neuron
Neuron - Structural Unit of central nervous
system i.e. Brain and Spinal Cord.
• 100 billion neurons, 100 trillion synapses
• Weight -1.5 Kg to 2Kg
• Conduction Speed – 0.6 m/s to 120 m/s
• Power – 20% ,20-40 Watt,10−16 𝐽
𝑜𝑝𝑒𝑟𝑎𝑡𝑖𝑜𝑛𝑠
• Ion Transport Phenomenon
• Fault tolerant
• Asynchronous firing
• Response time = 10−3
sec
“The Brain is a highly complex, non-linear and massively parallel
Computing machine.”
𝑵𝒆𝒖𝒓𝒐𝒏
“A Neuron is a basic unit of brain that processes and transmits information.”
Neuron
• Dendrite: Receive signals from other
neurons
• Soma (Cell body): Process the incoming
signals.
• Myelin Sheath: Covers neurons and help
speed up neuron impulses.
• Axon : Transmits the electric potential from
soma to synaptic terminal and then finally
to other neurons, muscles or glands
• Synaptic Terminal : Release the
neurotransmitter to transmit information to
dendrites.
Neuron Connection
Hierarchal Learning – Inspired Deep Learning
Human Brain Contd.
Historical Perspective about
modelling of Brain through Medical
and Applied Mathematics World
Historical Perspective
Historical Perspective contd.
Historical Perspective contd.
Analogy between
Biological Neural Network
and
Artificial Neural Network
Biological Neural Network Vs Artificial Neural Network
Equivalent Electrical Model
Practical Neural Network (Single Neuron)
𝑥1
𝑥2
𝑥𝑛
⋮
𝑤1
𝑤2
𝑤𝑛
ෝ
𝒚 = 𝒇 ෍
𝒊=𝟏
𝒏
𝒘𝒊𝒙𝒊 + 𝒃
෍(𝐢𝐧𝐩𝐮𝐭)
𝑓
Actual Output
Inputs b (Bias)
𝑥1
𝑥2
𝑥𝑛
⋮
𝑤1
𝑤2
𝑤𝑛
ෝ
𝒚 = 𝒇 ෍
𝒊=𝟎
𝒏
𝒘𝒊𝒙𝒊
෍(𝐢𝐧𝐩𝐮𝐭)
𝑓
Actual Output
(Bias)
𝑤0=b
𝑥0 = 1 Bias is 0th weight with input equal to 1
Activation Functions
Name Geometrical Shape Mathematical Expression Property
Hard Limit 𝒇 𝒙 = ቊ
𝟏 𝒊𝒇 𝒙 ≥ 𝟎
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
Non-differentiable
Bipolar Hard Limit
Signum Function 𝒇 𝒙 = ቐ
𝟏
𝟎
−𝟏
𝒊𝒇 𝒙 > 𝟎
𝒊𝒇 𝒙 = 𝟎
𝒊𝒇 𝒙 < 𝟎
Non-differentiable
Sigmoid Function
𝒇 𝒙 =
𝟏
𝟏 + 𝒆−𝒙
Differentiable
𝒇′
𝒙 = 𝒇 𝒙 𝟏 − 𝒇 𝒙
1
0 𝒙
𝒇 𝒙
1
0
𝒙
𝒇 𝒙
-1
1
0
𝒇 𝒙
Activation Functions
Name Geometrical Shape Mathematical Expression Property
Hyperbolic Tangent
or
Bipolar sigmoid
𝒇 𝒙 = 𝒕𝒂𝒏𝒉𝒙 =
𝒆𝒙−𝒆−𝒙
𝒆𝒙+𝒆−𝒙
Differentiable
𝒇′ 𝒙 = 𝟏 − 𝒇𝟐 𝒙
Bipolar Hard Limit
Signum Function
𝒇 𝒙 = 𝒙
Differentiable
Rectified Linear Unit
𝒇 𝒙 = 𝒎𝒂𝒙(𝟎, 𝒙) Differentiable
0
1
0 𝒙
𝒇 𝒙
-1
𝒇 𝒙
𝒙
𝒇 𝒙
𝒙
0
Single Perceptron to Multiple layer of perceptron – Historical Perspective
McCulloch Pitts (1943) – 1st Mathematical model of neuron
Weighted sum of input signals is compared to a threshold to determine the neuron output
Hebbian Learning Algorithm -1949
Learning of weights to classify the patterns
Organization of Behaviour – David Hebb
Frank Rosenblatt (1957) – More Accurate Neuron Model (Perceptron)
Perceptron Learning Algorithm to find optimum weights
Perceptron Learning Algorithm
Delta rule or Widrow- Hoff Learning Algorithm
Approximate steepest descent algorithm
Least Means Square Algorithm
Adaptive Linear Neuron Network Learning
Marvin Minsky and Seymour Peppert (1969)
Limitation of perceptron in classifying Non separable Patterns
Back Propagation (1986)
Training of Multilayer of Perceptrons
𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚
𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 + (𝒕 − 𝒂)𝒙𝒊
𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 − ቚ
𝜶𝛁𝑭 𝒘
𝒘=𝑾𝒐𝒍𝒅
Geometrical Significance (Hardlimit activation function)
𝑥1
𝑥2
𝑥𝑛
⋮
𝑤1
𝑤2
𝑤𝑛
ෝ
𝒚 = 𝒇 ෍
𝒊=𝟏
𝒏
𝒘𝒊𝒙𝒊 + 𝒃
෍(𝐢𝐧𝐩𝐮𝐭)
𝑓
Inputs b (Bias)
Hyperplane
Activation
Function
0
1
Output
input
Hard limit Function
From Activation function, we can infer if σ𝒊=𝟏
𝒏
𝒘𝒊𝒙𝒊 + 𝒃 or 𝑾𝑻
𝑿 (inner product between weight vector and input vector) is
greater than 0 for output is 1.
𝐰𝐡𝐞𝐫𝐞, 𝐰𝐞𝐢𝐠𝐡𝐭 𝐯𝐞𝐜𝐭𝐨𝐫 , 𝐖 =
𝐰𝟏
𝐰𝟐
⋮
𝐰𝐧
and input vector, 𝑿 =
𝒙𝟏
𝒙𝟐
⋮
𝒙𝒏
. The σ𝒊=𝟏
𝒏
𝒘𝒊𝒙𝒊 + 𝒃 = 𝟎 is equivalent to a hyperplane
boundary.
Geometrical Significance (Hardlimit Activation function)
2 input (𝒙𝟏 & 𝒙𝟐) → Boundary is line (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+b=0) with 𝒘𝟏, 𝒘𝟐 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥ 𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒍𝒊𝒏𝒆 .
3 input (𝒙𝟏, 𝒙𝟐 & 𝒙𝟑) → Boundary is Plane (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+𝒘𝟑𝒙𝟑+b=0) with 𝒘𝟏, 𝒘𝟐, 𝒘𝟑 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥ 𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒑𝒍𝒂𝒏𝒆.
>3 input (𝒙𝟏, 𝒙𝟐,⋯ 𝒙𝒏) → Boundary is Hyperplane (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+⋯+𝒘𝒏𝒙𝒏+b=0) with 𝒘𝟏, 𝒘𝟐 ⋯ 𝒘𝒏 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥
𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒉𝒚𝒑𝒆𝒓𝒑𝒍𝒂𝒏𝒆.
𝐖𝐞𝐢𝐠𝐡𝐭 𝐕𝐞𝐜𝐭𝐨𝐫
(𝐰𝟏, 𝐰𝟐)
𝑳𝒊𝒏𝒆 𝑬𝒒𝒖𝒂𝒕𝒊𝒐𝒏 (𝐰𝟏𝐱𝟏 + 𝐱𝟐𝐰𝟐+b=0)
Class 1
Class 2 𝐖𝐞𝐢𝐠𝐡𝐭 𝐕𝐞𝐜𝐭𝐨𝐫
(𝐰𝟏, 𝐰𝟐, 𝐰𝟑)
𝑷𝒍𝒂𝒏𝒆 𝑬𝒒𝒖𝒂𝒕𝒊𝒐𝒏
(𝐰𝟏𝐱𝟏 + 𝐱𝟐𝐰𝟐++𝐱𝟑𝐰𝟑+b=0)
Class 1
Class 2
𝐱𝟏
𝐱𝟐
𝐱𝟏
𝐱𝟐
𝐱𝟑
2 Class Single Neuron Classification
McCulloch Pitts Neuron
McCulloch Pitts Neuron (1943)
 Mathematical Model of the brain
 Depends upon the threshold (𝜃) with a hard limit activation function
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥1
𝑥2
𝑥𝑛
⋮
𝑤2
𝑤1
𝑤𝑛
𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 ≥ 𝜽
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝜽
OR Gate
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
0 0 0
0 1 1
1 0 1
1 1 1
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥1
𝑥2
𝑤1 = 1
𝑤2=1
𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 ≥ 𝟏
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝜽 = 𝟏
𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 + 𝒙𝟐
McCulloch Pitts Neuron
AND Gate
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
0 0 0
0 1 0
1 0 0
1 1 1
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥1
𝑥2
𝑤1 = 1
𝑤2=1
𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 ≥ 𝟐
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝜽 = 𝟐
𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 + 𝒙𝟐
Not Gate
𝑥 Target
Output (𝒚)
0 1
1 0
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥
𝑤1 = 1
𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 < 𝟎
𝟎 if 𝒚𝒊𝒏 ≥ 𝟏
𝒚𝒊𝒏= 𝒘𝟏𝒙 = 𝒙
McCulloch Pitts Neuron (XOR implementation)
𝒙𝟏 𝒙𝟐 Target
Output
(𝒚=𝒙𝟏
𝑻
𝒙𝟐)
0 0 0
0 1 1
1 0 0
1 1 0
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥1
𝑥2
𝒘𝟏 = −𝟏
𝒘𝟐= 1 𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 ≤ −𝟏
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝜽 = −𝟏
𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟐 − 𝒙𝟏
𝒙𝟏 𝒙𝟐 Target
Output
(𝒚=𝒙𝟏𝒙𝟐
𝑻
)
0 0 0
0 1 0
1 0 1
1 1 0
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝑦 = 𝑓 𝒚𝒊𝒏
𝑥1
𝑥2
𝒘𝟏 = 𝟏
𝒘𝟐=-1
𝑓 𝒚𝒊𝒏 = ቊ
𝟏 if 𝒚𝒊𝒏 ≤ −𝟏
𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆
𝜽 = −𝟏
𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 − 𝒙𝟐
𝒚=𝒙𝟏
𝑻
𝒙𝟐
𝒚=𝒙𝟏𝒙𝟐
𝑻
McCulloch Pitts Neuron (XOR implementation- 3 Neurons)
𝒙𝟏 𝒙𝟐 𝒚𝟏=𝒙𝟏
𝑻
𝒙𝟐 𝒚𝟐=𝒙𝟏𝒙𝟐
𝑻
𝒚=𝒙𝟏
𝑻
𝒙𝟐 + 𝒙𝟏𝒙𝟐
𝑻
0 0 0 0 0
0 1 1 0 1
1 0 0 1 1
1 1 0 0 0
𝒚=𝒙𝟏
𝑻
𝒙𝟐 + 𝒙𝟏𝒙𝟐
𝑻
𝒚𝒊𝒏𝟏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 − 𝒙𝟐
𝑦 = 𝑓 𝒚𝒊𝒏
𝒙𝟏
𝒙𝟐
𝒚𝒊𝒏𝟏 𝑓 𝒚𝒊𝒏𝟏
𝒘𝟏𝟏 = 𝟏
𝒘𝟏𝟐 = −𝟏
𝒘𝟐𝟏 = −𝟏
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
𝒚𝒊𝒏𝟐 𝑓 𝒚𝒊𝒏𝟐
𝒘𝟐𝟐 = 𝟏
𝒚𝒊𝒏𝟐= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟐 − 𝒙𝟏
𝒘𝟏𝟏
(𝟏)
= 𝟏
𝒘𝟏𝟐
(𝟏)
= 𝟏
Hebbian Learning Rule
Hebbian Learning Rule
• Donald Hebb (Psychologist)– The Organization of the behaviour (1949)
• Hebb’s Postulate – “When an axon of cell A is near enough to excite a cell
B and repeatedly or persistently takes part in firing it, some growth process or
metabolic change takes place in one or both cells such that A’s efficiency, as
one of the cells firing B, is increased.”
Mathematically,
𝑾𝒏𝒆𝒘= 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚
Where 𝑥𝑖 is the ith input and 𝑦 is output.
Bipolar inputs or outputs (-1 or +1)
Limitation – Can classify linearly separable patterns only
Hebbian Learning Rule
𝑾𝑵𝒆𝒘 = 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚
Bipolar inputs or outputs (-1 or +1)
AND gate Implementation
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
-1 -1 -1 1 1 -1 1 1 -1
-1 1 -1 1 -1 -1 2 0 -2
1 -1 -1 -1 1 -1 1 1 -3
1 1 1 1 1 1 2 2 -2
Initialized weight & bias
𝒘𝟏(𝒏𝒆𝒘) = 𝒘𝟏(𝒐𝒍𝒅) + 𝒙𝟏𝒚
𝒘𝟐(𝒏𝒆𝒘) = 𝒘𝟐(𝒐𝒍𝒅) + 𝒙𝟐𝒚
𝒘𝟎(𝒏𝒆𝒘) = 𝒘𝟎(𝒐𝒍𝒅) + 𝒙𝟎𝒚 (𝑭𝒐𝒓 𝒃𝒊𝒂𝒔 𝒙𝟎 = 𝟏 & 𝒘𝟎 = 𝒃)
𝒚𝒊𝒏= 𝒘𝟎𝒙𝟎 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒃 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐
𝒙𝟎 = 𝟏
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
𝒙𝟐
𝒙𝟏
𝒘𝟏
𝒘𝟐
𝒘𝟎= b
1 epoch
Iterations
Hebbian Learning Rule
OR gate Implementation
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
-1 -1 -1 1 1 -1 1 1 -1
-1 1 1 -1 1 1 0 2 0
1 -1 1 1 -1 1 1 1 1
1 1 1 1 1 1 2 2 2
Initialized weight & bias
1 epoch
Iterations
Check :
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
Where,
𝒇 𝒚𝒊𝒏 = ቊ
𝟏, 𝒚𝒊𝒏 ≥ 𝟎
𝟎, 𝒚𝒊𝒏 < 𝟎
𝒙𝟐
𝒙𝟏
𝒘𝟏 = 𝟐
𝒘𝟐 = 𝟐
𝒘𝟎= 2
𝒙𝟎 = 𝟏
-1
-1
𝒚𝒊𝒏 = -2 𝒇(𝒚𝒊𝒏) = 𝒇(−𝟐)=0
Hebbian Learning Rule
OR gate Implementation
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
-1 -1 -1 1 1 -1 1 1 -1
-1 1 1 -1 1 1 0 2 0
1 -1 1 1 -1 1 1 1 1
1 1 1 1 1 1 2 2 2
Initialized weight & bias
1 epoch
Iterations
Check :
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
Where,
𝒇 𝒚𝒊𝒏 = ቊ
𝟏, 𝒚𝒊𝒏 ≥ 𝟎
𝟎, 𝒚𝒊𝒏 < 𝟎
𝒙𝟐
𝒙𝟏
𝒘𝟏 = 𝟐
𝒘𝟐 = 𝟐
𝒘𝟎= 2
𝒙𝟎 = 𝟏
1
1
𝒚𝒊𝒏 = 6 𝒇(𝒚𝒊𝒏) = 𝒇 𝟔 = 1
Hebbian Learning Rule
OR gate Implementation
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
-1 -1 -1 1 1 -1 1 1 -1
-1 1 1 -1 1 1 0 2 0
1 -1 1 1 -1 1 1 1 1
1 1 1 1 1 1 2 2 2
Initialized weight & bias
1 epoch
Iterations
Check :
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
Where,
𝒇 𝒚𝒊𝒏 = ቊ
𝟏, 𝒚𝒊𝒏 ≥ 𝟎
𝟎, 𝒚𝒊𝒏 < 𝟎
𝒙𝟐
𝒙𝟏
𝒘𝟏 = 𝟐
𝒘𝟐 = 𝟐
𝒘𝟎= 2
𝒙𝟎 = 𝟏
-1
1
𝒚𝒊𝒏= 2 𝒇(𝒚𝒊𝒏) = 𝒇(𝟐)=1
Q - Are these Optimum set of weights ?
Perceptron Learning Rule
Perceptron Learning Rule
• Frank Rosenblatt – (1957)
• Key contribution - Introduction of a learning rule for training perceptron networks to
solve pattern recognition problems
• Perceptron could even learn when initialized with random values for its weights and
biases.
• Limitations – Can classify only linearly separable problems.
• Limitations were publicized in the book “Perceptrons (1969)” by Marvin Minsky and
Seymour Peppert.
Mathematically,
𝑾𝒏𝒆𝒘= 𝑾𝒐𝒍𝒅 + (𝒚 − ෝ
𝒚) 𝒙𝒊
Where, 𝑥𝑖 𝑖𝑠 𝑖𝑡ℎ 𝑖𝑛𝑝𝑢𝑡, ො
𝑦 𝑖𝑠 𝑎𝑐𝑡𝑢𝑎𝑙 𝑜𝑟 𝑝𝑟𝑒𝑑𝑖𝑐𝑡𝑒𝑑 𝑜𝑢𝑡𝑝𝑢𝑡 𝑎𝑛𝑑
𝑦 𝑖𝑠 𝑡𝑎𝑟𝑔𝑒𝑡 𝑜𝑢𝑡𝑝𝑢𝑡.
Perceptron Learning Rule
𝑾𝑵𝒆𝒘 = 𝑾𝒐𝒍𝒅 + (𝒚 − ෝ
𝒚)𝒙𝒊
AND gate Implementation
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
Actual
Output (ෝ
𝒚)
(𝒚 − ෝ
𝒚) ∆𝒘𝟏
=(𝒚 − ෝ
𝒚)𝒙𝟏
∆𝒘𝟐
= (𝒚 − ෝ
𝒚)𝒙𝟐
∆𝒃
= (𝒚 − ෝ
𝒚)
𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
0 0 0 1 -1 0 0 -1 0 0 -1
0 1 0 0 0 0 0 0 0 0 -1
1 0 0 0 0 0 0 0 0 0 -1
1 1 1 0 1 1 1 1 1 1 0
Initialized weight & bias
𝒘𝟏(𝒏𝒆𝒘) = 𝒘𝟏(𝒐𝒍𝒅) + ∆𝒘𝟏 = 𝒘𝟏(𝒐𝒍𝒅) +(𝒚 − ෝ
𝒚)𝒙𝟏
𝒘𝟐(𝒏𝒆𝒘) = 𝒘𝟐(𝒐𝒍𝒅) + ∆𝒘𝟐 = 𝒘𝟐(𝒐𝒍𝒅) +(𝒚 − ෝ
𝒚)𝒙𝟐
𝒘𝟎(𝒏𝒆𝒘) = 𝒘𝟎(𝒐𝒍𝒅) +(𝒚 − ෝ
𝒚)𝒙𝟎 (𝑭𝒐𝒓 𝒃𝒊𝒂𝒔 𝒙𝟎 = 𝟏 & 𝒘𝟎 = 𝒃)
𝒚𝒊𝒏= 𝒘𝟎𝒙𝟎 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒃 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐
𝒙𝟎 = 𝟏
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏
ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
𝒇 𝒚𝒊𝒏 = ቊ
𝟏, 𝒚𝒊𝒏 ≥ 𝟎
𝟎, 𝒚𝒊𝒏 < 𝟎
𝒙𝟐
𝒙𝟏
𝒘𝟏
𝒘𝟐
𝒘𝟎= b
1 epoch
Iterations
Weights after 1 epoch
OR gate Implementation
Initialized weight & bias
1 epoch
Iterations
Check :
𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ
𝒚 = 𝒇 𝒚𝒊𝒏
Where,
𝒇 𝒚𝒊𝒏 = ቊ
𝟏, 𝒚𝒊𝒏 ≥ 𝟎
𝟎, 𝒚𝒊𝒏 < 𝟎
𝒙𝟐
𝒙𝟏
𝒘𝟏 = 𝟏
𝒘𝟐 = 𝟎
𝒘𝟎= 0
𝒙𝟎 = 𝟏
0
0
𝒚𝒊𝒏 = 0 𝒇(𝒚𝒊𝒏) = 𝒇 𝟎 = 1
𝒙𝟏 𝒙𝟐 Target
Output (𝒚)
Actual
Output (ෝ
𝒚)
(𝒚 − ෝ
𝒚) ∆𝒘𝟏
=(𝒚 − ෝ
𝒚)𝒙𝟏
∆𝒘𝟐
= (𝒚 − ෝ
𝒚)𝒙𝟐
∆𝒃
= (𝒚 − ෝ
𝒚)
𝒘𝟏
0
𝒘𝟐
0
𝒘𝟎(𝒃)
0
0 0 0 1 -1 0 0 -1 0 0 -1
0 1 1 0 1 0 1 1 0 1 0
1 0 1 1 0 0 0 0 0 1 0
1 1 1 1 0 0 0 0 0 1 0
× 𝑾𝒓𝒐𝒏𝒈 Output
Need more iterations
Perceptron Learning Rule

Weitere ähnliche Inhalte

Was ist angesagt?

Neuro-Fuzzy Controller
Neuro-Fuzzy ControllerNeuro-Fuzzy Controller
Neuro-Fuzzy ControllerIshwar Bhoge
 
Multilayer perceptron
Multilayer perceptronMultilayer perceptron
Multilayer perceptronomaraldabash
 
Optical Channel Capacity of MIMO system
Optical Channel Capacity of MIMO systemOptical Channel Capacity of MIMO system
Optical Channel Capacity of MIMO systemAWANISHKUMAR84
 
Intro to Neural Networks
Intro to Neural NetworksIntro to Neural Networks
Intro to Neural NetworksDean Wyatte
 
Recurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRURecurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRUananth
 
Agent based intrusion detection, response and blocking using signature method...
Agent based intrusion detection, response and blocking using signature method...Agent based intrusion detection, response and blocking using signature method...
Agent based intrusion detection, response and blocking using signature method...Mumbai Academisc
 
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...Pallepati Vasavi
 
Brief Introduction to Boltzmann Machine
Brief Introduction to Boltzmann MachineBrief Introduction to Boltzmann Machine
Brief Introduction to Boltzmann MachineArunabha Saha
 
Recursive Neural Networks
Recursive Neural NetworksRecursive Neural Networks
Recursive Neural NetworksSangwoo Mo
 
A Brief Introduction on Recurrent Neural Network and Its Application
A Brief Introduction on Recurrent Neural Network and Its ApplicationA Brief Introduction on Recurrent Neural Network and Its Application
A Brief Introduction on Recurrent Neural Network and Its ApplicationXiaohu ZHU
 
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...Simplilearn
 
Deep Learning - RNN and CNN
Deep Learning - RNN and CNNDeep Learning - RNN and CNN
Deep Learning - RNN and CNNPradnya Saval
 
Blind deconvolution in Wireless Communication
Blind deconvolution in Wireless CommunicationBlind deconvolution in Wireless Communication
Blind deconvolution in Wireless CommunicationAritra Chatterjee
 
Introduction to Deep Learning
Introduction to Deep LearningIntroduction to Deep Learning
Introduction to Deep LearningOswald Campesato
 
Training Neural Networks
Training Neural NetworksTraining Neural Networks
Training Neural NetworksDatabricks
 
Introduction of Deep Learning
Introduction of Deep LearningIntroduction of Deep Learning
Introduction of Deep LearningMyungjin Lee
 
Introduction to Recurrent Neural Network
Introduction to Recurrent Neural NetworkIntroduction to Recurrent Neural Network
Introduction to Recurrent Neural NetworkYan Xu
 

Was ist angesagt? (20)

Neuro-Fuzzy Controller
Neuro-Fuzzy ControllerNeuro-Fuzzy Controller
Neuro-Fuzzy Controller
 
Multilayer perceptron
Multilayer perceptronMultilayer perceptron
Multilayer perceptron
 
Optical Channel Capacity of MIMO system
Optical Channel Capacity of MIMO systemOptical Channel Capacity of MIMO system
Optical Channel Capacity of MIMO system
 
Intro to Neural Networks
Intro to Neural NetworksIntro to Neural Networks
Intro to Neural Networks
 
Recurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRURecurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRU
 
Agent based intrusion detection, response and blocking using signature method...
Agent based intrusion detection, response and blocking using signature method...Agent based intrusion detection, response and blocking using signature method...
Agent based intrusion detection, response and blocking using signature method...
 
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...Mobile computing unit2,SDMA,FDMA,CDMA,TDMA  Space Division Multi Access,Frequ...
Mobile computing unit2,SDMA,FDMA,CDMA,TDMA Space Division Multi Access,Frequ...
 
Brief Introduction to Boltzmann Machine
Brief Introduction to Boltzmann MachineBrief Introduction to Boltzmann Machine
Brief Introduction to Boltzmann Machine
 
Recursive Neural Networks
Recursive Neural NetworksRecursive Neural Networks
Recursive Neural Networks
 
A Brief Introduction on Recurrent Neural Network and Its Application
A Brief Introduction on Recurrent Neural Network and Its ApplicationA Brief Introduction on Recurrent Neural Network and Its Application
A Brief Introduction on Recurrent Neural Network and Its Application
 
Neural Networks
Neural NetworksNeural Networks
Neural Networks
 
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...
Recurrent Neural Network (RNN) | RNN LSTM Tutorial | Deep Learning Course | S...
 
Deep Learning - RNN and CNN
Deep Learning - RNN and CNNDeep Learning - RNN and CNN
Deep Learning - RNN and CNN
 
Blind deconvolution in Wireless Communication
Blind deconvolution in Wireless CommunicationBlind deconvolution in Wireless Communication
Blind deconvolution in Wireless Communication
 
Introduction to Deep Learning
Introduction to Deep LearningIntroduction to Deep Learning
Introduction to Deep Learning
 
Training Neural Networks
Training Neural NetworksTraining Neural Networks
Training Neural Networks
 
Introduction of Deep Learning
Introduction of Deep LearningIntroduction of Deep Learning
Introduction of Deep Learning
 
Backpropagation algo
Backpropagation  algoBackpropagation  algo
Backpropagation algo
 
Introduction to Recurrent Neural Network
Introduction to Recurrent Neural NetworkIntroduction to Recurrent Neural Network
Introduction to Recurrent Neural Network
 
LSTM
LSTMLSTM
LSTM
 

Ähnlich wie Lecture 4 neural networks

Lect1_Threshold_Logic_Unit lecture 1 - ANN
Lect1_Threshold_Logic_Unit  lecture 1 - ANNLect1_Threshold_Logic_Unit  lecture 1 - ANN
Lect1_Threshold_Logic_Unit lecture 1 - ANNMostafaHazemMostafaa
 
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience hirokazutanaka
 
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...DurgadeviParamasivam
 
Neuromorphic computing for neural networks
Neuromorphic computing for neural networksNeuromorphic computing for neural networks
Neuromorphic computing for neural networksClaudio Gallicchio
 
Artificial Neural Network in Medical Diagnosis
Artificial Neural Network in Medical DiagnosisArtificial Neural Network in Medical Diagnosis
Artificial Neural Network in Medical DiagnosisAdityendra Kumar Singh
 
Artificial Neural Network seminar presentation using ppt.
Artificial Neural Network seminar presentation using ppt.Artificial Neural Network seminar presentation using ppt.
Artificial Neural Network seminar presentation using ppt.Mohd Faiz
 
Nural network ER. Abhishek k. upadhyay
Nural network ER. Abhishek  k. upadhyayNural network ER. Abhishek  k. upadhyay
Nural network ER. Abhishek k. upadhyayabhishek upadhyay
 
w1-01-introtonn.ppt
w1-01-introtonn.pptw1-01-introtonn.ppt
w1-01-introtonn.pptKotaGuru1
 
Deep learning lecture - part 1 (basics, CNN)
Deep learning lecture - part 1 (basics, CNN)Deep learning lecture - part 1 (basics, CNN)
Deep learning lecture - part 1 (basics, CNN)SungminYou
 
Neural networks
Neural networksNeural networks
Neural networksBasil John
 
Introduction to Artificial Neural Networks
Introduction to Artificial Neural Networks Introduction to Artificial Neural Networks
Introduction to Artificial Neural Networks MuhammadMir92
 
20141003.journal club
20141003.journal club20141003.journal club
20141003.journal clubHayaru SHOUNO
 
14 Machine Learning Single Layer Perceptron
14 Machine Learning Single Layer Perceptron14 Machine Learning Single Layer Perceptron
14 Machine Learning Single Layer PerceptronAndres Mendez-Vazquez
 
Artificial Neural Network (draft)
Artificial Neural Network (draft)Artificial Neural Network (draft)
Artificial Neural Network (draft)James Boulie
 
Artificial Intelligence Applications in Petroleum Engineering - Part I
Artificial Intelligence Applications in Petroleum Engineering - Part IArtificial Intelligence Applications in Petroleum Engineering - Part I
Artificial Intelligence Applications in Petroleum Engineering - Part IRamez Abdalla, M.Sc
 

Ähnlich wie Lecture 4 neural networks (20)

Lect1_Threshold_Logic_Unit lecture 1 - ANN
Lect1_Threshold_Logic_Unit  lecture 1 - ANNLect1_Threshold_Logic_Unit  lecture 1 - ANN
Lect1_Threshold_Logic_Unit lecture 1 - ANN
 
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience
JAISTサマースクール2016「脳を知るための理論」講義04 Neural Networks and Neuroscience
 
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...
BACKPROPOGATION ALGO.pdfLECTURE NOTES WITH SOLVED EXAMPLE AND FEED FORWARD NE...
 
Neuromorphic computing for neural networks
Neuromorphic computing for neural networksNeuromorphic computing for neural networks
Neuromorphic computing for neural networks
 
Artificial Neural Network in Medical Diagnosis
Artificial Neural Network in Medical DiagnosisArtificial Neural Network in Medical Diagnosis
Artificial Neural Network in Medical Diagnosis
 
Artificial Neural Network seminar presentation using ppt.
Artificial Neural Network seminar presentation using ppt.Artificial Neural Network seminar presentation using ppt.
Artificial Neural Network seminar presentation using ppt.
 
ANN.ppt
ANN.pptANN.ppt
ANN.ppt
 
Neural Networks
Neural NetworksNeural Networks
Neural Networks
 
Nural network ER. Abhishek k. upadhyay
Nural network ER. Abhishek  k. upadhyayNural network ER. Abhishek  k. upadhyay
Nural network ER. Abhishek k. upadhyay
 
w1-01-introtonn.ppt
w1-01-introtonn.pptw1-01-introtonn.ppt
w1-01-introtonn.ppt
 
Deep learning lecture - part 1 (basics, CNN)
Deep learning lecture - part 1 (basics, CNN)Deep learning lecture - part 1 (basics, CNN)
Deep learning lecture - part 1 (basics, CNN)
 
SoftComputing5
SoftComputing5SoftComputing5
SoftComputing5
 
Neural networks
Neural networksNeural networks
Neural networks
 
Introduction to Artificial Neural Networks
Introduction to Artificial Neural Networks Introduction to Artificial Neural Networks
Introduction to Artificial Neural Networks
 
20141003.journal club
20141003.journal club20141003.journal club
20141003.journal club
 
Artificial Neural Network
Artificial Neural NetworkArtificial Neural Network
Artificial Neural Network
 
annintro.ppt
annintro.pptannintro.ppt
annintro.ppt
 
14 Machine Learning Single Layer Perceptron
14 Machine Learning Single Layer Perceptron14 Machine Learning Single Layer Perceptron
14 Machine Learning Single Layer Perceptron
 
Artificial Neural Network (draft)
Artificial Neural Network (draft)Artificial Neural Network (draft)
Artificial Neural Network (draft)
 
Artificial Intelligence Applications in Petroleum Engineering - Part I
Artificial Intelligence Applications in Petroleum Engineering - Part IArtificial Intelligence Applications in Petroleum Engineering - Part I
Artificial Intelligence Applications in Petroleum Engineering - Part I
 

Mehr von ParveenMalik18

Mehr von ParveenMalik18 (11)

Lecture 6 radial basis-function_network
Lecture 6 radial basis-function_networkLecture 6 radial basis-function_network
Lecture 6 radial basis-function_network
 
Lecture 5 backpropagation
Lecture 5 backpropagationLecture 5 backpropagation
Lecture 5 backpropagation
 
Lecture 3 fuzzy inference system
Lecture 3  fuzzy inference systemLecture 3  fuzzy inference system
Lecture 3 fuzzy inference system
 
Lecture 2 fuzzy inference system
Lecture 2  fuzzy inference systemLecture 2  fuzzy inference system
Lecture 2 fuzzy inference system
 
Lecture 1 computational intelligence
Lecture 1  computational intelligenceLecture 1  computational intelligence
Lecture 1 computational intelligence
 
Chapter8
Chapter8Chapter8
Chapter8
 
Chapter6
Chapter6Chapter6
Chapter6
 
Chapter5
Chapter5Chapter5
Chapter5
 
Chapter3
Chapter3Chapter3
Chapter3
 
Chapter2
Chapter2Chapter2
Chapter2
 
Electrical and Electronic Measurement
Electrical and Electronic MeasurementElectrical and Electronic Measurement
Electrical and Electronic Measurement
 

Kürzlich hochgeladen

Vishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsVishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsSachinPawar510423
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...Chandu841456
 
Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHC Sai Kiran
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfAsst.prof M.Gokilavani
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 
Introduction-To-Agricultural-Surveillance-Rover.pptx
Introduction-To-Agricultural-Surveillance-Rover.pptxIntroduction-To-Agricultural-Surveillance-Rover.pptx
Introduction-To-Agricultural-Surveillance-Rover.pptxk795866
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfAsst.prof M.Gokilavani
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfROCENODodongVILLACER
 
computer application and construction management
computer application and construction managementcomputer application and construction management
computer application and construction managementMariconPadriquez1
 
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfg
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfgUnit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfg
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfgsaravananr517913
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptMadan Karki
 
lifi-technology with integration of IOT.pptx
lifi-technology with integration of IOT.pptxlifi-technology with integration of IOT.pptx
lifi-technology with integration of IOT.pptxsomshekarkn64
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfme23b1001
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfAsst.prof M.Gokilavani
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)dollysharma2066
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort servicejennyeacort
 
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerAnamika Sarkar
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxKartikeyaDwivedi3
 

Kürzlich hochgeladen (20)

POWER SYSTEMS-1 Complete notes examples
POWER SYSTEMS-1 Complete notes  examplesPOWER SYSTEMS-1 Complete notes  examples
POWER SYSTEMS-1 Complete notes examples
 
Vishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsVishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documents
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...
 
Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECH
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
Introduction-To-Agricultural-Surveillance-Rover.pptx
Introduction-To-Agricultural-Surveillance-Rover.pptxIntroduction-To-Agricultural-Surveillance-Rover.pptx
Introduction-To-Agricultural-Surveillance-Rover.pptx
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdf
 
computer application and construction management
computer application and construction managementcomputer application and construction management
computer application and construction management
 
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfg
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfgUnit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfg
Unit7-DC_Motors nkkjnsdkfnfcdfknfdgfggfg
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.ppt
 
lifi-technology with integration of IOT.pptx
lifi-technology with integration of IOT.pptxlifi-technology with integration of IOT.pptx
lifi-technology with integration of IOT.pptx
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdf
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptx
 

Lecture 4 neural networks

  • 1. Parveen Malik Assistant Professor KIIT University Neural Networks
  • 2. Text Books: • Neural Networks and Learning Machines – Simon Haykin • Principles of Soft Computing- S.N.Shivnandam & S.N.Deepa • Neural Networks using Matlab- S.N. Shivanandam, S. Sumathi ,S N Deepa
  • 3. What is Neural Network ?
  • 4. “A neural network is a massively parallel distributed processor made up of simple processing units that has a natural propensity for storing experiential knowledge and making it available for use.” It resembles the brain in two respects: 1. Knowledge is acquired by the network from its environment through a learning process. 2. Interneuron connection strengths, known as synaptic weights, are used to store the acquired knowledge. Neural Network
  • 5. Why we need Neural Networks ?
  • 6.  Object Detection  Visual Tracking  Image Captioning  Video Captioning  Visual Question Answering  Video question answering  Video Summarization  Generating Authentic Photos  Facial Expression detection Machine Learning Visual Pattern Recognition Natural Language Processing  Language Modelling  Text prediction  Speech Recognition  Machine Translation  C-H conversation Modelling Time series Modelling  Share Market Prediction  Weather Forecasting  Financial Data analytics  Mood analytics Machine Learning and Beyond
  • 8. Aerospace Defence  High performance aircraft autopilot  Flight path simulations  Aircraft control system  Autopilot enhancements  Aircraft component simulations  Aircraft component detectors.  Weapon steering  Target tracking  Object discrimination  Facial recognition  New kind of sensors  Sonar  Radar signal processing  image signal processing  Data compression  Feature extraction  Noise suppression Manufacturing  Manufacturing process control  Product design and analysis  Process and machine diagnosis  Real time particle identification  Visual quality inspection systems  Wielding analysis  Analysis of grinding operations  Chemical product design, analysis  Machine maintenance analysis  Project bidding planning and management  Dynamic modelling of chemical process systems. Medical Entertainment  Breast cancer cell analysis  EEG and ECG analysis  Prosthesis design  Optimization of transplant times  Hospital expense reduction  Hospital quality improvement  Emergency room test advisement  Animation  Special effects  Market forecasting Electronics  Code sequence prediction  Integrated circuit chip layout  Process control  Chip failure analysis  Machine vision  Voice synthesis  Non-linear modelling Applications
  • 9. Financial Telecommunications • Real estate appraisal • Loan advisor • Mortgage screening • Corporate bond rating • Credit line use analysis • Portfolio trading program • Corporate financial analysis • Currency price prediction • Image and data compression • Automated information services • Real time translation of spoken language • Customer payment processing systems Securities • Market analysis • Automatic bond rating • Stock trading advisory systems Automotive Banking • Automobile automatic guidance systems • Warranty activity analysers • Check and other document readers • Credit application evaluators Insurance  Policy application evaluation  Product optimization Robotics • Trajectory control • Forklift robot • Manipulator controllers • Vision systems Speech Transportation • Speech recognition • Speech compression • Vowel classification • Text to speech synthesis • Truck brake diagnosis systems • Vehicle scheduling • Routing systems
  • 10. Central Nervous System Human Brain and Neuron
  • 11. CNS- Brain and Neuron Neuron - Structural Unit of central nervous system i.e. Brain and Spinal Cord. • 100 billion neurons, 100 trillion synapses • Weight -1.5 Kg to 2Kg • Conduction Speed – 0.6 m/s to 120 m/s • Power – 20% ,20-40 Watt,10−16 𝐽 𝑜𝑝𝑒𝑟𝑎𝑡𝑖𝑜𝑛𝑠 • Ion Transport Phenomenon • Fault tolerant • Asynchronous firing • Response time = 10−3 sec “The Brain is a highly complex, non-linear and massively parallel Computing machine.” 𝑵𝒆𝒖𝒓𝒐𝒏
  • 12. “A Neuron is a basic unit of brain that processes and transmits information.” Neuron • Dendrite: Receive signals from other neurons • Soma (Cell body): Process the incoming signals. • Myelin Sheath: Covers neurons and help speed up neuron impulses. • Axon : Transmits the electric potential from soma to synaptic terminal and then finally to other neurons, muscles or glands • Synaptic Terminal : Release the neurotransmitter to transmit information to dendrites.
  • 14. Hierarchal Learning – Inspired Deep Learning Human Brain Contd.
  • 15. Historical Perspective about modelling of Brain through Medical and Applied Mathematics World
  • 19. Analogy between Biological Neural Network and Artificial Neural Network
  • 20. Biological Neural Network Vs Artificial Neural Network Equivalent Electrical Model
  • 21. Practical Neural Network (Single Neuron) 𝑥1 𝑥2 𝑥𝑛 ⋮ 𝑤1 𝑤2 𝑤𝑛 ෝ 𝒚 = 𝒇 ෍ 𝒊=𝟏 𝒏 𝒘𝒊𝒙𝒊 + 𝒃 ෍(𝐢𝐧𝐩𝐮𝐭) 𝑓 Actual Output Inputs b (Bias) 𝑥1 𝑥2 𝑥𝑛 ⋮ 𝑤1 𝑤2 𝑤𝑛 ෝ 𝒚 = 𝒇 ෍ 𝒊=𝟎 𝒏 𝒘𝒊𝒙𝒊 ෍(𝐢𝐧𝐩𝐮𝐭) 𝑓 Actual Output (Bias) 𝑤0=b 𝑥0 = 1 Bias is 0th weight with input equal to 1
  • 22. Activation Functions Name Geometrical Shape Mathematical Expression Property Hard Limit 𝒇 𝒙 = ቊ 𝟏 𝒊𝒇 𝒙 ≥ 𝟎 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 Non-differentiable Bipolar Hard Limit Signum Function 𝒇 𝒙 = ቐ 𝟏 𝟎 −𝟏 𝒊𝒇 𝒙 > 𝟎 𝒊𝒇 𝒙 = 𝟎 𝒊𝒇 𝒙 < 𝟎 Non-differentiable Sigmoid Function 𝒇 𝒙 = 𝟏 𝟏 + 𝒆−𝒙 Differentiable 𝒇′ 𝒙 = 𝒇 𝒙 𝟏 − 𝒇 𝒙 1 0 𝒙 𝒇 𝒙 1 0 𝒙 𝒇 𝒙 -1 1 0 𝒇 𝒙
  • 23. Activation Functions Name Geometrical Shape Mathematical Expression Property Hyperbolic Tangent or Bipolar sigmoid 𝒇 𝒙 = 𝒕𝒂𝒏𝒉𝒙 = 𝒆𝒙−𝒆−𝒙 𝒆𝒙+𝒆−𝒙 Differentiable 𝒇′ 𝒙 = 𝟏 − 𝒇𝟐 𝒙 Bipolar Hard Limit Signum Function 𝒇 𝒙 = 𝒙 Differentiable Rectified Linear Unit 𝒇 𝒙 = 𝒎𝒂𝒙(𝟎, 𝒙) Differentiable 0 1 0 𝒙 𝒇 𝒙 -1 𝒇 𝒙 𝒙 𝒇 𝒙 𝒙 0
  • 24. Single Perceptron to Multiple layer of perceptron – Historical Perspective McCulloch Pitts (1943) – 1st Mathematical model of neuron Weighted sum of input signals is compared to a threshold to determine the neuron output Hebbian Learning Algorithm -1949 Learning of weights to classify the patterns Organization of Behaviour – David Hebb Frank Rosenblatt (1957) – More Accurate Neuron Model (Perceptron) Perceptron Learning Algorithm to find optimum weights Perceptron Learning Algorithm Delta rule or Widrow- Hoff Learning Algorithm Approximate steepest descent algorithm Least Means Square Algorithm Adaptive Linear Neuron Network Learning Marvin Minsky and Seymour Peppert (1969) Limitation of perceptron in classifying Non separable Patterns Back Propagation (1986) Training of Multilayer of Perceptrons 𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚 𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 + (𝒕 − 𝒂)𝒙𝒊 𝑾𝒏𝒆𝒘 = 𝑾𝒐𝒍𝒅 − ቚ 𝜶𝛁𝑭 𝒘 𝒘=𝑾𝒐𝒍𝒅
  • 25. Geometrical Significance (Hardlimit activation function) 𝑥1 𝑥2 𝑥𝑛 ⋮ 𝑤1 𝑤2 𝑤𝑛 ෝ 𝒚 = 𝒇 ෍ 𝒊=𝟏 𝒏 𝒘𝒊𝒙𝒊 + 𝒃 ෍(𝐢𝐧𝐩𝐮𝐭) 𝑓 Inputs b (Bias) Hyperplane Activation Function 0 1 Output input Hard limit Function From Activation function, we can infer if σ𝒊=𝟏 𝒏 𝒘𝒊𝒙𝒊 + 𝒃 or 𝑾𝑻 𝑿 (inner product between weight vector and input vector) is greater than 0 for output is 1. 𝐰𝐡𝐞𝐫𝐞, 𝐰𝐞𝐢𝐠𝐡𝐭 𝐯𝐞𝐜𝐭𝐨𝐫 , 𝐖 = 𝐰𝟏 𝐰𝟐 ⋮ 𝐰𝐧 and input vector, 𝑿 = 𝒙𝟏 𝒙𝟐 ⋮ 𝒙𝒏 . The σ𝒊=𝟏 𝒏 𝒘𝒊𝒙𝒊 + 𝒃 = 𝟎 is equivalent to a hyperplane boundary.
  • 26. Geometrical Significance (Hardlimit Activation function) 2 input (𝒙𝟏 & 𝒙𝟐) → Boundary is line (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+b=0) with 𝒘𝟏, 𝒘𝟐 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥ 𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒍𝒊𝒏𝒆 . 3 input (𝒙𝟏, 𝒙𝟐 & 𝒙𝟑) → Boundary is Plane (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+𝒘𝟑𝒙𝟑+b=0) with 𝒘𝟏, 𝒘𝟐, 𝒘𝟑 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥ 𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒑𝒍𝒂𝒏𝒆. >3 input (𝒙𝟏, 𝒙𝟐,⋯ 𝒙𝒏) → Boundary is Hyperplane (𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐+⋯+𝒘𝒏𝒙𝒏+b=0) with 𝒘𝟏, 𝒘𝟐 ⋯ 𝒘𝒏 𝒂𝒔 𝒏𝒐𝒓𝒎𝒂𝒍 ⊥ 𝒗𝒆𝒄𝒕𝒐𝒓 𝒐𝒇 𝒉𝒚𝒑𝒆𝒓𝒑𝒍𝒂𝒏𝒆. 𝐖𝐞𝐢𝐠𝐡𝐭 𝐕𝐞𝐜𝐭𝐨𝐫 (𝐰𝟏, 𝐰𝟐) 𝑳𝒊𝒏𝒆 𝑬𝒒𝒖𝒂𝒕𝒊𝒐𝒏 (𝐰𝟏𝐱𝟏 + 𝐱𝟐𝐰𝟐+b=0) Class 1 Class 2 𝐖𝐞𝐢𝐠𝐡𝐭 𝐕𝐞𝐜𝐭𝐨𝐫 (𝐰𝟏, 𝐰𝟐, 𝐰𝟑) 𝑷𝒍𝒂𝒏𝒆 𝑬𝒒𝒖𝒂𝒕𝒊𝒐𝒏 (𝐰𝟏𝐱𝟏 + 𝐱𝟐𝐰𝟐++𝐱𝟑𝐰𝟑+b=0) Class 1 Class 2 𝐱𝟏 𝐱𝟐 𝐱𝟏 𝐱𝟐 𝐱𝟑 2 Class Single Neuron Classification
  • 28. McCulloch Pitts Neuron (1943)  Mathematical Model of the brain  Depends upon the threshold (𝜃) with a hard limit activation function 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥1 𝑥2 𝑥𝑛 ⋮ 𝑤2 𝑤1 𝑤𝑛 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 ≥ 𝜽 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 𝜽 OR Gate 𝒙𝟏 𝒙𝟐 Target Output (𝒚) 0 0 0 0 1 1 1 0 1 1 1 1 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥1 𝑥2 𝑤1 = 1 𝑤2=1 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 ≥ 𝟏 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 𝜽 = 𝟏 𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 + 𝒙𝟐
  • 29. McCulloch Pitts Neuron AND Gate 𝒙𝟏 𝒙𝟐 Target Output (𝒚) 0 0 0 0 1 0 1 0 0 1 1 1 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥1 𝑥2 𝑤1 = 1 𝑤2=1 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 ≥ 𝟐 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 𝜽 = 𝟐 𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 + 𝒙𝟐 Not Gate 𝑥 Target Output (𝒚) 0 1 1 0 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥 𝑤1 = 1 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 < 𝟎 𝟎 if 𝒚𝒊𝒏 ≥ 𝟏 𝒚𝒊𝒏= 𝒘𝟏𝒙 = 𝒙
  • 30. McCulloch Pitts Neuron (XOR implementation) 𝒙𝟏 𝒙𝟐 Target Output (𝒚=𝒙𝟏 𝑻 𝒙𝟐) 0 0 0 0 1 1 1 0 0 1 1 0 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥1 𝑥2 𝒘𝟏 = −𝟏 𝒘𝟐= 1 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 ≤ −𝟏 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 𝜽 = −𝟏 𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟐 − 𝒙𝟏 𝒙𝟏 𝒙𝟐 Target Output (𝒚=𝒙𝟏𝒙𝟐 𝑻 ) 0 0 0 0 1 0 1 0 1 1 1 0 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝑦 = 𝑓 𝒚𝒊𝒏 𝑥1 𝑥2 𝒘𝟏 = 𝟏 𝒘𝟐=-1 𝑓 𝒚𝒊𝒏 = ቊ 𝟏 if 𝒚𝒊𝒏 ≤ −𝟏 𝟎 𝒐𝒕𝒉𝒆𝒓𝒘𝒊𝒔𝒆 𝜽 = −𝟏 𝒚𝒊𝒏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 − 𝒙𝟐 𝒚=𝒙𝟏 𝑻 𝒙𝟐 𝒚=𝒙𝟏𝒙𝟐 𝑻
  • 31. McCulloch Pitts Neuron (XOR implementation- 3 Neurons) 𝒙𝟏 𝒙𝟐 𝒚𝟏=𝒙𝟏 𝑻 𝒙𝟐 𝒚𝟐=𝒙𝟏𝒙𝟐 𝑻 𝒚=𝒙𝟏 𝑻 𝒙𝟐 + 𝒙𝟏𝒙𝟐 𝑻 0 0 0 0 0 0 1 1 0 1 1 0 0 1 1 1 1 0 0 0 𝒚=𝒙𝟏 𝑻 𝒙𝟐 + 𝒙𝟏𝒙𝟐 𝑻 𝒚𝒊𝒏𝟏= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟏 − 𝒙𝟐 𝑦 = 𝑓 𝒚𝒊𝒏 𝒙𝟏 𝒙𝟐 𝒚𝒊𝒏𝟏 𝑓 𝒚𝒊𝒏𝟏 𝒘𝟏𝟏 = 𝟏 𝒘𝟏𝟐 = −𝟏 𝒘𝟐𝟏 = −𝟏 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 𝒚𝒊𝒏𝟐 𝑓 𝒚𝒊𝒏𝟐 𝒘𝟐𝟐 = 𝟏 𝒚𝒊𝒏𝟐= 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒙𝟐 − 𝒙𝟏 𝒘𝟏𝟏 (𝟏) = 𝟏 𝒘𝟏𝟐 (𝟏) = 𝟏
  • 33. Hebbian Learning Rule • Donald Hebb (Psychologist)– The Organization of the behaviour (1949) • Hebb’s Postulate – “When an axon of cell A is near enough to excite a cell B and repeatedly or persistently takes part in firing it, some growth process or metabolic change takes place in one or both cells such that A’s efficiency, as one of the cells firing B, is increased.” Mathematically, 𝑾𝒏𝒆𝒘= 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚 Where 𝑥𝑖 is the ith input and 𝑦 is output. Bipolar inputs or outputs (-1 or +1) Limitation – Can classify linearly separable patterns only
  • 34. Hebbian Learning Rule 𝑾𝑵𝒆𝒘 = 𝑾𝒐𝒍𝒅 + 𝒙𝒊𝒚 Bipolar inputs or outputs (-1 or +1) AND gate Implementation 𝒙𝟏 𝒙𝟐 Target Output (𝒚) ∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 -1 -1 -1 1 1 -1 1 1 -1 -1 1 -1 1 -1 -1 2 0 -2 1 -1 -1 -1 1 -1 1 1 -3 1 1 1 1 1 1 2 2 -2 Initialized weight & bias 𝒘𝟏(𝒏𝒆𝒘) = 𝒘𝟏(𝒐𝒍𝒅) + 𝒙𝟏𝒚 𝒘𝟐(𝒏𝒆𝒘) = 𝒘𝟐(𝒐𝒍𝒅) + 𝒙𝟐𝒚 𝒘𝟎(𝒏𝒆𝒘) = 𝒘𝟎(𝒐𝒍𝒅) + 𝒙𝟎𝒚 (𝑭𝒐𝒓 𝒃𝒊𝒂𝒔 𝒙𝟎 = 𝟏 & 𝒘𝟎 = 𝒃) 𝒚𝒊𝒏= 𝒘𝟎𝒙𝟎 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒃 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 𝒙𝟎 = 𝟏 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 𝒙𝟐 𝒙𝟏 𝒘𝟏 𝒘𝟐 𝒘𝟎= b 1 epoch Iterations
  • 35. Hebbian Learning Rule OR gate Implementation 𝒙𝟏 𝒙𝟐 Target Output (𝒚) ∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 -1 -1 -1 1 1 -1 1 1 -1 -1 1 1 -1 1 1 0 2 0 1 -1 1 1 -1 1 1 1 1 1 1 1 1 1 1 2 2 2 Initialized weight & bias 1 epoch Iterations Check : 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 Where, 𝒇 𝒚𝒊𝒏 = ቊ 𝟏, 𝒚𝒊𝒏 ≥ 𝟎 𝟎, 𝒚𝒊𝒏 < 𝟎 𝒙𝟐 𝒙𝟏 𝒘𝟏 = 𝟐 𝒘𝟐 = 𝟐 𝒘𝟎= 2 𝒙𝟎 = 𝟏 -1 -1 𝒚𝒊𝒏 = -2 𝒇(𝒚𝒊𝒏) = 𝒇(−𝟐)=0
  • 36. Hebbian Learning Rule OR gate Implementation 𝒙𝟏 𝒙𝟐 Target Output (𝒚) ∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 -1 -1 -1 1 1 -1 1 1 -1 -1 1 1 -1 1 1 0 2 0 1 -1 1 1 -1 1 1 1 1 1 1 1 1 1 1 2 2 2 Initialized weight & bias 1 epoch Iterations Check : 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 Where, 𝒇 𝒚𝒊𝒏 = ቊ 𝟏, 𝒚𝒊𝒏 ≥ 𝟎 𝟎, 𝒚𝒊𝒏 < 𝟎 𝒙𝟐 𝒙𝟏 𝒘𝟏 = 𝟐 𝒘𝟐 = 𝟐 𝒘𝟎= 2 𝒙𝟎 = 𝟏 1 1 𝒚𝒊𝒏 = 6 𝒇(𝒚𝒊𝒏) = 𝒇 𝟔 = 1
  • 37. Hebbian Learning Rule OR gate Implementation 𝒙𝟏 𝒙𝟐 Target Output (𝒚) ∆𝒘𝟏 ∆𝒘𝟐 ∆𝒃 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 -1 -1 -1 1 1 -1 1 1 -1 -1 1 1 -1 1 1 0 2 0 1 -1 1 1 -1 1 1 1 1 1 1 1 1 1 1 2 2 2 Initialized weight & bias 1 epoch Iterations Check : 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 Where, 𝒇 𝒚𝒊𝒏 = ቊ 𝟏, 𝒚𝒊𝒏 ≥ 𝟎 𝟎, 𝒚𝒊𝒏 < 𝟎 𝒙𝟐 𝒙𝟏 𝒘𝟏 = 𝟐 𝒘𝟐 = 𝟐 𝒘𝟎= 2 𝒙𝟎 = 𝟏 -1 1 𝒚𝒊𝒏= 2 𝒇(𝒚𝒊𝒏) = 𝒇(𝟐)=1 Q - Are these Optimum set of weights ?
  • 39. Perceptron Learning Rule • Frank Rosenblatt – (1957) • Key contribution - Introduction of a learning rule for training perceptron networks to solve pattern recognition problems • Perceptron could even learn when initialized with random values for its weights and biases. • Limitations – Can classify only linearly separable problems. • Limitations were publicized in the book “Perceptrons (1969)” by Marvin Minsky and Seymour Peppert. Mathematically, 𝑾𝒏𝒆𝒘= 𝑾𝒐𝒍𝒅 + (𝒚 − ෝ 𝒚) 𝒙𝒊 Where, 𝑥𝑖 𝑖𝑠 𝑖𝑡ℎ 𝑖𝑛𝑝𝑢𝑡, ො 𝑦 𝑖𝑠 𝑎𝑐𝑡𝑢𝑎𝑙 𝑜𝑟 𝑝𝑟𝑒𝑑𝑖𝑐𝑡𝑒𝑑 𝑜𝑢𝑡𝑝𝑢𝑡 𝑎𝑛𝑑 𝑦 𝑖𝑠 𝑡𝑎𝑟𝑔𝑒𝑡 𝑜𝑢𝑡𝑝𝑢𝑡.
  • 40. Perceptron Learning Rule 𝑾𝑵𝒆𝒘 = 𝑾𝒐𝒍𝒅 + (𝒚 − ෝ 𝒚)𝒙𝒊 AND gate Implementation 𝒙𝟏 𝒙𝟐 Target Output (𝒚) Actual Output (ෝ 𝒚) (𝒚 − ෝ 𝒚) ∆𝒘𝟏 =(𝒚 − ෝ 𝒚)𝒙𝟏 ∆𝒘𝟐 = (𝒚 − ෝ 𝒚)𝒙𝟐 ∆𝒃 = (𝒚 − ෝ 𝒚) 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 0 0 0 1 -1 0 0 -1 0 0 -1 0 1 0 0 0 0 0 0 0 0 -1 1 0 0 0 0 0 0 0 0 0 -1 1 1 1 0 1 1 1 1 1 1 0 Initialized weight & bias 𝒘𝟏(𝒏𝒆𝒘) = 𝒘𝟏(𝒐𝒍𝒅) + ∆𝒘𝟏 = 𝒘𝟏(𝒐𝒍𝒅) +(𝒚 − ෝ 𝒚)𝒙𝟏 𝒘𝟐(𝒏𝒆𝒘) = 𝒘𝟐(𝒐𝒍𝒅) + ∆𝒘𝟐 = 𝒘𝟐(𝒐𝒍𝒅) +(𝒚 − ෝ 𝒚)𝒙𝟐 𝒘𝟎(𝒏𝒆𝒘) = 𝒘𝟎(𝒐𝒍𝒅) +(𝒚 − ෝ 𝒚)𝒙𝟎 (𝑭𝒐𝒓 𝒃𝒊𝒂𝒔 𝒙𝟎 = 𝟏 & 𝒘𝟎 = 𝒃) 𝒚𝒊𝒏= 𝒘𝟎𝒙𝟎 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 = 𝒃 + 𝒘𝟏𝒙𝟏 + 𝒘𝟐𝒙𝟐 𝒙𝟎 = 𝟏 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 𝒇 𝒚𝒊𝒏 = ቊ 𝟏, 𝒚𝒊𝒏 ≥ 𝟎 𝟎, 𝒚𝒊𝒏 < 𝟎 𝒙𝟐 𝒙𝟏 𝒘𝟏 𝒘𝟐 𝒘𝟎= b 1 epoch Iterations Weights after 1 epoch
  • 41. OR gate Implementation Initialized weight & bias 1 epoch Iterations Check : 𝒚𝒊𝒏 𝑓 𝒚𝒊𝒏 ෝ 𝒚 = 𝒇 𝒚𝒊𝒏 Where, 𝒇 𝒚𝒊𝒏 = ቊ 𝟏, 𝒚𝒊𝒏 ≥ 𝟎 𝟎, 𝒚𝒊𝒏 < 𝟎 𝒙𝟐 𝒙𝟏 𝒘𝟏 = 𝟏 𝒘𝟐 = 𝟎 𝒘𝟎= 0 𝒙𝟎 = 𝟏 0 0 𝒚𝒊𝒏 = 0 𝒇(𝒚𝒊𝒏) = 𝒇 𝟎 = 1 𝒙𝟏 𝒙𝟐 Target Output (𝒚) Actual Output (ෝ 𝒚) (𝒚 − ෝ 𝒚) ∆𝒘𝟏 =(𝒚 − ෝ 𝒚)𝒙𝟏 ∆𝒘𝟐 = (𝒚 − ෝ 𝒚)𝒙𝟐 ∆𝒃 = (𝒚 − ෝ 𝒚) 𝒘𝟏 0 𝒘𝟐 0 𝒘𝟎(𝒃) 0 0 0 0 1 -1 0 0 -1 0 0 -1 0 1 1 0 1 0 1 1 0 1 0 1 0 1 1 0 0 0 0 0 1 0 1 1 1 1 0 0 0 0 0 1 0 × 𝑾𝒓𝒐𝒏𝒈 Output Need more iterations Perceptron Learning Rule