(p-iteea-0033) embedded systemsusers.itk.ppke.hu/~fulta/d46/piteea0033_2016_lecture_10.pdf · •...

38
Pázmány Péter Katolikus Egyetem Információs Technológiai Kar Building blocks of bio-inspired learning algorithms Part 1/2 Lecture 10 May 4, 2016 Beágyazott elektronikus rendszerek (P-ITEEA-0033) Embedded Systems

Upload: others

Post on 04-Aug-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Pázmány Péter Katolikus Egyetem

Információs Technológiai Kar

Building blocks of bio-inspired

learning algorithms

Part 1/2

Lecture 10

May 4, 2016

Beágyazott elektronikus rendszerek

(P-ITEEA-0033)

Embedded Systems

Page 2: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Outline

• Example for complex space-time algorithm:

visual attentional selection, search and

classification

• Classification using neural networks

(solutions, feature extraction, etc.)

• Adaptive Resonance Theory (ART) network

(operation and application)

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 3: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

High level

autonomous

flight control

Controller

control

commands

flight

plan

SensorsSensory

information

processing

Example: unmanned aerial

navigation

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 4: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Landscape patterns to recognize

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 5: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Search and recognition

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 6: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Tasks to solve

• Navigation (to complete mission)

• Reconnaissance (based on land features)

• Processing video stream

– sensing, extracting space-time features

• Recognition, decision

• Maintaining contact (base, other UAVs)

• Sensing, computing, communication ...

• Speed, power and physical limits!May 4, 2016 Lecture 10, P-ITEEA-0033

Page 7: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Sensing-processing for

exploration/selection/tracking/navigation

CMOS sensor(cut through an image

window controlled by an

attention mechanism)

CNN sensor-processor(exploration by parallel,

spatio-temporal nonlinear

feature extraction)

DSP (selection/ tracking/

navigation)

Sensor Image

1024x1024

Window

128x128

Nonlinear

spatio-temporal

channels

Global and

local feature

descriptors

Selection of focus and

scale of attention

Optical flow &

navigation parameter

estimation (YPR)

Feature classification

using ART network

Upper-level framework

(at different time-scales)

Y,

P, R

C

F, S

M

T

T

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 8: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Integer DSP

(TX C6415

720 MHz)

Communication

Processor

(ETRAX 100)

Memory

(Flash &

SDRAM)

Color

CMOS Sensor

(IBIS 5-C)

Sensor-

processor

(ACE16k)

PLD (XILINX)

Ethernet /

RS 232 /

USB / Dig I/O /

FireWire

(1280x1024) (128x128)

Float DSP

(TX C6701

150 MHz)

Visual

input

Bi-i as embedded system

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 9: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Pázmány Péter Katolikus Egyetem

Információs Technológiai Kar

Decision/classification with

neural networks

Page 10: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Classification methods using

neural networks

• Classifications using adaptive methods

• Input-output data representation

• Multi-layer perceptron (MLP)

• Supervised and unsupervised learning

• Off-line and on-line learning

• Categorization vs. classification

• ART and ARTMAP networks

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 11: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Biological motivations

• Structure of typical nerve cell:

– body, dendrites, axon

• Interconnection

• Operation:

– excitation, inhibition, signal integration, firing

• Learning

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 12: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

The model neuron

f x( )

x1

x2

x3

xn

x0=1w1

w2

w3

wn

w0

y

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 13: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

The Perceptron

Function:

yx wi i

i

n

1 0

10

if

otherwise

where

and

x x i n

w R i ni

i0 1 1 1 1

0

, , , ,...,

, ,...,

‘net input’

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 14: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Perceptron decision regions

x1

xn

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 15: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Multi-layer Perceptrons (MLP)

• Architecture

• Combining decision regions

• MLP’s can implement arbitrary

decision/classification tasks

• Learning??

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 16: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

The ADALINE

• ADAptive LInear NEuron

• Output function is linear: f(x) = x

• Learning by minimising Mean-Squared

Error (MSE)

• The “delta” learning rule:

wE

wd y xi

ii

( )

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 17: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

The LMS training algorithm

1. Initialise weight vector (w = w0)

2. Select new training pair (x, d)

3. Calculate actual output y

4. Calculate error:

5. Adjust weight vector:

6. If MSE = min. Then stop Else Goto 2.

w d y f net x i ni i ( ) ( ) , ,...,0

d y

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 18: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Minimizing errorError

Weight

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 19: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Back-propagation networks

• Multi-layer net, nonlinear output function

• Solving the credit assignment problem

• Calculating error for hidden nodes (by

propagating error terms backwards)

• Minimising MSE by gradient descent

• BP nets are universal function

approximators

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 20: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Back-propagation training

Error

InputOutput

TargetError

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 21: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Problems with BP training

• Only local minima can be found

• Overtraining (overfitting)

• Long training time

• Catastrophic forgetting

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 22: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Learning by self-organisation

• Learning without a teacher

• Typical network architectures and learning

methods

• What can be learned?

• Learning classification?

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 23: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Self-organising networks

x1 x2 x3 xn

y1 y2 ym

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 24: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Self-organizing networks

• Winner-take-all at output

• Unsupervised learning

yD w x D w x i j

ii j

1

0

if

otherwise

( , ) ( , ),

wx w i

iiold

( ) if node wins

otherwise0

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 25: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Unsupervised learning example

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 26: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Adaptive Resonance Theory

(ART) networks

• Stephen Grossberg (1976, 1987, …)

• Gail Carpenter (1987, …)

• Goal:

“Autonomous learning within complex

environments that are not under strict

external control.”

• The Stability-Plasticity dilemma

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 27: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART networks (cont’d)

• Human capabilities:

– ability to pay attention (at variable levels)

– expectation & reaction to unexpected events

– learning without a teacher

• ART is capable of …

“development of stable recognition codes

by self-organisation in real-time in

response to arbitrary sequences of input

patterns.”

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 28: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART variants

– ART1 (1987): binary input patterns

– ART2 (1987): continuous (real-valued) inputs

– ART3 (1990): hierarchical search

– ARTMAP (1991): supervised ART

– Fuzzy ART(MAP) (1991, 1992): ART and fuzzy

logic

– …

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 29: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Definition of ART networks

• Level 1: Nonlinear differential equations

(activation, coupling, signal propagation &

learning laws)

• Level 2: Asymptotic approximation using

algebraic equations

• Level 3: Algorithmic description of

emerging behaviour as a result of network

interactions

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 30: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network architecture

F1 STM

STMF2

Gain Control

Gain Control

Input pattern

LTM

LTM

Attentional Subsystem Orienting

Subsystem

A

STM

Reset

wave

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 31: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network dynamics

...

F0

F1

F2

Attentional subsystem Orienting

subsystem

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 32: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network dynamics

1 0 1 1 1 0

?

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 33: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network dynamics

?

!

1 0 1 1 1 0May 4, 2016 Lecture 10, P-ITEEA-0033

Page 34: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network dynamics

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 35: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART network operation

Compute the similarity

with the Choice function

Select the best prototype

Winner-Take-All strategy

Check the difference

Match functionr

Update the winner

Learning function

Create

new category

I

Categories

pass

winner

Resetfail

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 36: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART1 example

InputCategory prototypes

1 2 3

5.0r1 2 3 4 5

8.0r

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 37: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

ART1 emergent behaviour

The ART1 network implements a fast and

stable incremental clustering algorithm.

May 4, 2016 Lecture 10, P-ITEEA-0033

Page 38: (P-ITEEA-0033) Embedded Systemsusers.itk.ppke.hu/~fulta/d46/PITEEA0033_2016_Lecture_10.pdf · • ART and ARTMAP networks May 4, 2016 Lecture 10, P-ITEEA-0033. Biological motivations

Properties of ART• stability vs. plasticity:

– attentional system: processing of familiar inputs

– orienting subsystem: controlling search in case

of unfamiliar inputs

• prototypes with self-scaling critical features

• direct access to categories after self-

stabilisation

• attentional vigilance (can be modulated)

• learning in resonant state

May 4, 2016 Lecture 10, P-ITEEA-0033