Cognitive Computer Vision

Slides:



Advertisements
Similar presentations
Lecture 16 Hidden Markov Models. HMM Until now we only considered IID data. Some data are of sequential nature, i.e. have correlations have time. Example:
Advertisements

Angelo Dalli Department of Intelligent Computing Systems
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
Hidden Markov Models By Marc Sobel. Lecture Notes for E Alpaydın 2004 Introduction to Machine Learning © The MIT Press (V1.1) 2 Introduction Modeling.
Hidden Markov Model 主講人:虞台文 大同大學資工所 智慧型多媒體研究室. Contents Introduction – Markov Chain – Hidden Markov Model (HMM) Formal Definition of HMM & Problems Estimate.
Hidden Markov Models. A Hidden Markov Model consists of 1.A sequence of states {X t |t  T } = {X 1, X 2,..., X T }, and 2.A sequence of observations.
Lecture 8: Hidden Markov Models (HMMs) Michael Gutkin Shlomi Haba Prepared by Originally presented at Yaakov Stein’s DSPCSP Seminar, spring 2002 Modified.
Introduction to Hidden Markov Models
Hidden Markov Models Bonnie Dorr Christof Monz CMSC 723: Introduction to Computational Linguistics Lecture 5 October 6, 2004.
Page 1 Hidden Markov Models for Automatic Speech Recognition Dr. Mike Johnson Marquette University, EECE Dept.
An Introduction to Hidden Markov Models and Gesture Recognition Troy L. McDaniel Research Assistant Center for Cognitive Ubiquitous Computing Arizona State.
Ch-9: Markov Models Prepared by Qaiser Abbas ( )
Hidden Markov Models Theory By Johan Walters (SR 2003)
1 Hidden Markov Models (HMMs) Probabilistic Automata Ubiquitous in Speech/Speaker Recognition/Verification Suitable for modelling phenomena which are dynamic.
Hidden Markov Models Fundamentals and applications to bioinformatics.
Natural Language Processing Spring 2007 V. “Juggy” Jagannathan.
Apaydin slides with a several modifications and additions by Christoph Eick.
Albert Gatt Corpora and Statistical Methods Lecture 8.
INTRODUCTION TO Machine Learning 3rd Edition
… Hidden Markov Models Markov assumption: Transition model:
ETHEM ALPAYDIN © The MIT Press, Lecture Slides for.
Hidden Markov Models. Hidden Markov Model In some Markov processes, we may not be able to observe the states directly.
1 Hidden Markov Model Instructor : Saeed Shiry  CHAPTER 13 ETHEM ALPAYDIN © The MIT Press, 2004.
Hidden Markov Models David Meir Blei November 1, 1999.
INTRODUCTION TO Machine Learning ETHEM ALPAYDIN © The MIT Press, Lecture Slides for.
Visual Recognition Tutorial1 Markov models Hidden Markov models Forward/Backward algorithm Viterbi algorithm Baum-Welch estimation algorithm Hidden.
Cognitive Computer Vision 3R400 Kingsley Sage Room 5C16, Pevensey III
ETHEM ALPAYDIN © The MIT Press, Lecture Slides for.
Ch10 HMM Model 10.1 Discrete-Time Markov Process 10.2 Hidden Markov Models 10.3 The three Basic Problems for HMMS and the solutions 10.4 Types of HMMS.
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
CS344 : Introduction to Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 21- Forward Probabilities and Robotic Action Sequences.
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
Hidden Markov Models in Keystroke Dynamics Md Liakat Ali, John V. Monaco, and Charles C. Tappert Seidenberg School of CSIS, Pace University, White Plains,
Homework 1 Reminder Due date: (till 23:59) Submission: – – Write the names of students in your team.
ECE 8443 – Pattern Recognition ECE 8423 – Adaptive Signal Processing Objectives: ML and Simple Regression Bias of the ML Estimate Variance of the ML Estimate.
Processing Sequential Sensor Data The “John Krumm perspective” Thomas Plötz November 29 th, 2011.
ECE 8443 – Pattern Recognition ECE 8527 – Introduction to Machine Learning and Pattern Recognition Objectives: Reestimation Equations Continuous Distributions.
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
CS 416 Artificial Intelligence Lecture 17 Reasoning over Time Chapter 15 Lecture 17 Reasoning over Time Chapter 15.
CS Statistical Machine learning Lecture 24
CSC321: Neural Networks Lecture 16: Hidden Markov Models
1 Hidden Markov Model Observation : O1,O2,... States in time : q1, q2,... All states : s1, s2,... Si Sj.
1 Hidden Markov Model Presented by Qinmin Hu. 2 Outline Introduction Generating patterns Markov process Hidden Markov model Forward algorithm Viterbi.
ECE 8443 – Pattern Recognition ECE 8527 – Introduction to Machine Learning and Pattern Recognition Objectives: Elements of a Discrete Model Evaluation.
CPS 170: Artificial Intelligence Markov processes and Hidden Markov Models (HMMs) Instructor: Vincent Conitzer.
Hidden Markov Models (HMMs) –probabilistic models for learning patterns in sequences (e.g. DNA, speech, weather, cards...) (2 nd order model)
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
Albert Gatt Corpora and Statistical Methods. Acknowledgement Some of the examples in this lecture are taken from a tutorial on HMMs by Wolgang Maass.
1 Hidden Markov Models Hsin-min Wang References: 1.L. R. Rabiner and B. H. Juang, (1993) Fundamentals of Speech Recognition, Chapter.
1 Hidden Markov Model Observation : O1,O2,... States in time : q1, q2,... All states : s1, s2,..., sN Si Sj.
EEL 6586: AUTOMATIC SPEECH PROCESSING Hidden Markov Model Lecture Mark D. Skowronski Computational Neuro-Engineering Lab University of Florida March 31,
ECE 8443 – Pattern Recognition ECE 8527 – Introduction to Machine Learning and Pattern Recognition Objectives: Reestimation Equations Continuous Distributions.
ECE 8443 – Pattern Recognition Objectives: Reestimation Equations Continuous Distributions Gaussian Mixture Models EM Derivation of Reestimation Resources:
Cognitive Computer Vision Kingsley Sage and Hilary Buxton Prepared under ECVision Specific Action 8-3
Hidden Markov Models. A Hidden Markov Model consists of 1.A sequence of states {X t |t  T } = {X 1, X 2,..., X T }, and 2.A sequence of observations.
Definition of the Hidden Markov Model A Seminar Speech Recognition presentation A Seminar Speech Recognition presentation October 24 th 2002 Pieter Bas.
Other Models for Time Series. The Hidden Markov Model (HMM)
Cognitive Computer Vision 3R400 Kingsley Sage Room 5C16, Pevensey III
Visual Recognition Tutorial1 Markov models Hidden Markov models Forward/Backward algorithm Viterbi algorithm Baum-Welch estimation algorithm Hidden.
Hidden Markov Models Wassnaa AL-mawee Western Michigan University Department of Computer Science CS6800 Adv. Theory of Computation Prof. Elise De Doncker.
Hidden Markov Models HMM Hassanin M. Al-Barhamtoshy
MACHINE LEARNING 16. HMM. Introduction Lecture Notes for E Alpaydın 2004 Introduction to Machine Learning © The MIT Press (V1.1) 2  Modeling dependencies.
Hidden Markov Models.
EEL 6586: AUTOMATIC SPEECH PROCESSING Hidden Markov Model Lecture
CHAPTER 15: Hidden Markov Models
Hidden Markov Autoregressive Models
CHAPTER 15: Hidden Markov Models
Hidden Markov Model LR Rabiner
LECTURE 15: REESTIMATION, EM AND MIXTURES
Hidden Markov Models By Manish Shrivastava.
Presentation transcript:

Cognitive Computer Vision Kingsley Sage khs20@sussex.ac.uk and Hilary Buxton hilaryb@sussex.ac.uk Prepared under ECVision Specific Action 8-3 http://www.ecvision.org

Lecture 7 (Hidden) Markov Models What are they? What can you do with them?

So why are HMMs relevant to Cognitive CV? Provides a well-founded methodology for reasoning about temporal events One method that you can use as a basis for our model of expectation

Markov Models Markov Models are used to represent and model temporal relationships, e.g.: Motion of objects in a tracker Gestures Interpreting sign language Speech recognition

Markov Models So for MIT’s Smart Room, we can use Markov Models to represent cue gestures that control the behaviour of other agents …

Markov Models What is a Markov Model? Observable and hidden variables The Markov assumption Forward evaluation Order of a Markov Model Observable and hidden variables The Hidden Markov Model (HMM) Viterbi decoding Learning the HMM parameters

What is a Markov Model? The (first order) Markov assumption That the distribution P(XT ) depends solely on the distribution P(XT-1). The present (current state) can be predicted using local knowledge of the past (state at previous time step)

What is a Markov Model? Can represent as a state transition diagram State Transition Matrix Sunny Rain Wet state at time t Sunny Rain Wet 0.6 0.3 0.1 0.2 state at time t-1

What is a Markov Model? Formally a Markov Model  = (, A)  vector is the probability that you are in a state at time t=0 A is the State Transition Matrix You can use this information to calculate the probability for our weather example at any future t using Forward Evaluation …

Forward evaluation (1) t=0 t=1 1.0 Sunny Rain Wet 0.6 0.3 0.1 0.2 t=0 t=1 Sunny 1.0 (1.0*0.6) + (0.0*0.1) + (0.0*0.2) = 0.6 Rain 0.0 (1.0*0.3) + (0.0*0.6) + (0.0*0.2) = 0.3 Wet (1.0*0.1) + (0.0*0.3) + (0.0*0.6) = 0.1

Forward evaluation (2) t=0 t=1 t=2 1.0 0.6 0.0 0.3 0.1 Sunny Rain Wet 0.6 0.3 0.1 0.2 t=0 t=1 t=2 Sunny 1.0 0.6 (0.6*0.6) + (0.3*0.1) + (0.1*0.2) = 0.41 Rain 0.0 0.3 (0.6*0.3) + (0.3*0.6) + (0.1*0.2) = 0.38 Wet 0.1 (0.6*0.1) + (0.3*0.3) + (0.1*0.6) = 0.21

The order of a Markov Model (1) The (N-th order) Markov assumption That the distribution P(XT ) depends solely on the joint distribution P(XT-1,XT-2, … XT-N) The present (current state) can be predicted using only a knowledge of the past (state of N previous time steps) Problem: number of parameters for state transition matrix increases as |S|*|S|N

Before we can discuss Hidden Markov Models (HMMs) … Observable and hidden variables: A variable is observable if its value can be directly measured, or given as an Observation sequence O A variable is hidden if its value cannot be measured directly, but we can infer its value indirectly So …

Before we can discuss Hidden Markov Models (HMMs) … Consider a hermit living in a cage. He cannot see the weather conditions, but he does have a magic crystal which reacts to environmental conditions. The crystal turns one of 3 colours (red, green or blue). The actual weather states (sunny, rainy, wet) are hidden to the hermit, but the crystal states (red, green and blue) are observable.

The Hidden Markov Model (HMM) - model structure Sunny Rain Wet Red Green Blue Observable variables Hidden

What is a Hidden Markov Model? Formally a Hidden Markov Model  = (, A, B)  vector and A matrix as before M observable states Red Green Blue Sunny 0.8 0.1 Rain Wet 0.2 0.6 The B (confusion) matrix Single N * M matrix iff M is discrete. If M is continuous, B is usually represented as set of Gaussian mixtures N hidden states

So what can you do with a HMM? Given  and a sequence of observations O Calculate p(O| ) – forward evaluation Given  and O, calculate the most likely sequence of hidden states (Viterbi decoding) Given O, find  to maximise p(|O) – Baum Welch (model parameter) learning Use  to generate new O (the HMM as a generative model) – stochastic sampling

Forward evaluation (1) Assume  and O = {o1,o2, … ,oT} are given … Red M observable states Red Green Blue Sunny 0.8 0.1 Rain Wet 0.2 0.6 Sunny Rain Wet 0.6 0.3 0.1 0.2 N hidden states Assume  and O = {o1,o2, … ,oT} are given …

Forward evaluation (2)  t=1 Here O = {o1 = red} Sunny 1.0 M observable states Sunny Rain Wet 0.6 0.3 0.1 0.2 Red Green Blue Sunny 0.8 0.1 Rain Wet 0.2 0.6 N hidden states  t=1 Sunny 1.0 1.0 * 0.8 = 0.80 Rain 0.0 0.0 * 0.1 = 0.00 Wet 0.0 * 0.2 = 0.00 time t = 1 is a special case Here O = {o1 = red}

Forward evaluation (3)  t=1 t=2 Here O = {o1 = red, o2 = green} Sunny Blue Sunny 0.8 0.1 Rain Wet 0.2 0.6 Sunny Rain Wet 0.6 0.3 0.1 0.2 N hidden states  t=1 t=2 Sunny 1 0.80 {(0.80*0.6) + (0.00*0.1) + (0.00*0.2)} * 0.1 = 0.048 Rain 0.00 {(0.80*0.3) + (0.00*0.6) + (0.00*0.2)} * 0.8 = 0.192 Wet {(0.80*0.1) + (0.00*0.3) + (0.00*0.6)} * 0.2 = 0.016 Here O = {o1 = red, o2 = green}

Seminar Prior assumption Practical issues in computing the forward evaluation matrix Measure of likelihood per observation symbol Backwards evaluation Reference: “An Introduction to Hidden Markov Models”, L. R. Rabiner & B. H. Juang, IEEE ASSP Magazine, January 1986

Further reading Try reading the Rabiner paper (it’s quite friendly really) … Mixture of Gaussians: many maths books will cover MOG. Non-trivial maths involved … Variable length Markov Models: “The Power of Amnesia”, D. Ron, Y. Singer and N. Tishby, In Advances in Neural Information Processing Systems (NIPS), vol 6, pp 176-183, 1994

Summary An N-th order Markov model incorporates the assumption that the future depends only on the last N timesteps In Markov model reasoning over time, we use a state transition matrix A and a vector  representing the probabilities at time step t=1 We use a matrix B which maps the observation O to the hidden states

Next time … Gaussian mixtures and HMMs with continuous valued data