SlideShare a Scribd company logo
Machine Learning: Basics
Applied Machine Learning: Unit 1, Lecture 1
Anantharaman Narayana Iyer
narayana dot Anantharaman at gmail dot com
9th Jan 2016
Types of Learning Algorithms
• Supervised
• Given a set of pairs (x, y) where y is a label (or class) and x is an observation, discover a function that
assigns the correct labels to the x.
• Unsupervised
• The data is unlabelled. We need to explore the data to discover the intrinsic structures in them
• Semi supervised
• Part of the data is labelled while the rest is unlabelled. The labelled data is used to bootstrap. For
example deep learning architectures leverage the vast amount of unlabelled data available over the
web and use a small quantity of labelled data for finetuning.
• Reinforcement
• Reinforcement learning (RL) is learning by interacting with an environment. An RL agent learns from the
consequences of its actions, rather than from being explicitly taught and it selects its actions on basis of
its past experiences (exploitation) and also by new choices (exploration), which is essentially trial and
error learning.
x1
x2
Supervised Learning
L1
L2
L5
L3
L4
Class = True
Class = False
Key Concepts
• Supervised learning is a technique where the classifier is
trained using training examples
• The training examples contain the input attributes
(Features) and the expected outputs.
• In the Fig, X1 and X2 are the features
• The input typically is a n-dimensional vector and output
may have 1 or more dimensions
• A Binary Classifier classifies the input vector in to one of
the two states
• Illustrated by Red and Purple boxes in the fig
• A linearly separable system is one where the class labels
can be separated by a linear decision boundary.
• The straight lines L1, L2, L3, L4, L5 show different
decision boundaries in the Fig
• The example in the Fig is 2 dimensional linearly separable
system. It can be generalized to an n-dimensional system.
The decision surface is then called an Hyperplane
• Each decision surface can be considered to be a Hypothesis
x1
x2
Unsupervised Learning
Cluster = 2
Cluster = 1
Key Concepts
• Unsupervised techniques do not require the
expected outputs to be specified in the
dataset.
• This has an advantage as the availability of
labelled data is scarce relative to the vast
amount of data that is available in Web and
other media.
• Clustering is one of the machine learning
algorithms that belongs to the category of
unsupervised learning
• In the Fig the system finds inputs that can be
logically grouped together as a cluster. The
example shows 2 such clusters.
Classification and Regression Problems
• The term regression refers to a system with a continuous variable as
the output
• Classification is a process by which the machine learning system
partitions the input space in a to discrete set of classes
• Example:
• Credit card approval (Approve, Not approved decisions)
• Credit line limit
• Home loan approval
• Sentiment Polarity (Positive, Negative, Neutral)
• Sentiment as a real number: -1 <= sentiment <= 1
Notations
•
• m = Number of training examples
• n = Number of features in the input example
• x’s = “input” variable / features
• y’s = “output” variable / “target” variable
• The unknown target function f maps the input space to the outputs as:
f: X -> Y
Problem Statement: ML Classifier
• Given a finite set of training
examples and the space of all
applicable hypothesis, select a
hypothesis that best
approximates the unknown
target function.
• The unknown target function f is
the ideal function that
characterizes the underlying
pattern that generated the data
• Training examples are provided to
the ML designer
• The output of this process is a
hypothesis g that approximates f
• The hypothesis set and the
learning algorithm constitutes the
solution set.
Fig from: Yasser Mustafa, Caltech
Let’s begin: Perceptron Learning
• National cricket team selectors choose the team members of the
team and thus play a key role in the performance of the team.
• Suppose we want to build a system that acts as a “virtual selector” by
selecting (or rejecting) a player given the data on his past
performances.
• Let us consider a selector who looks at only 2 input variables: Batting
Average, Bowling Average.
• Here, the features are: x1 = Batting Average, x2 = Bowling Average
• Let us consider PLA for this purpose
Example data
PLAYER BATTING AVERAGE BOWLING AVERAGE SELECTED
Shikhar Dhawan 45.46 -1 Yes
Rohit Sharma 37.89 60.37 Yes
Ajinkya Rahane 29.28 -1 Yes
Virat Kohli 52.61 145.5 Yes
Suresh Raina 35.82 48 Yes
Ambati Rayudu 60 53 Yes
Kedar Jadhav 20 -1 No
Manoj Tiwary 31.62 28.8 No
Manish Pandey -1 -1 No
Murali Vijay 19.46 -1 No
MS Dhoni 52.85 31 Yes
Wriddhiman Saha 13.66 -1 No
Robin Uthappa 26.96 -1 No
Sanju Samson -1 -1 No
Ravindra Jadeja 34.51 32.29 Yes
Akshar Patel 20 20.28 Yes
Stuart Binny 13.33 13 Yes
Parvez Rasool -1 30 Yes
R Ashwin 16.91 32.46 Yes
Karn Sharma -1 -1 No
Amit Mishra 4.8 23.95 No
Kuldeep Yadav -1 -1 No
Ishant Sharma 5.14 31.25 Yes
Bhuvneshwar Kumar 10.4 36.59 Yes
Mohammed Shami 9.12 26.08 Yes
Umesh Yadav 14.66 35.93 Yes
Varun Aaron 8 38.09 No
Dhawal Kulkarni -1 23 No
Mohit Sharma -1 58 No
Ashok Dinda 4.2 51 No
45.46, 100
37.89, 60.37
29.28, 100 52.61, 100
35.82, 48
60, 53
20, 100
31.62, 28.8
0, 100 19.46, 100
52.85, 31
13.66, 100 26.96, 1000, 100
34.51, 32.29
20, 20.28
13.33, 13
0, 30
16.91, 32.46
0, 100
4.8, 23.95
0, 100
5.14, 31.25
10.4, 36.59
9.12, 26.08
14.66, 35.93
8, 38.09
0, 23
0, 58
4.2, 51
0
20
40
60
80
100
120
0 10 20 30 40 50 60 70
Visualization of team performance
PLA Model
x = (x1, x2) where x1, x2 are the features of a given data sample
Select the player if 𝑑 𝑤𝑖 𝑥𝑖 > 𝑡ℎ𝑟𝑒𝑠ℎ𝑜𝑙𝑑 𝑒𝑙𝑠𝑒 𝑟𝑒𝑗𝑒𝑐𝑡
The above can be written as:
ℎ 𝑥 = 𝑠𝑖𝑔𝑛(( 𝑑 𝑤𝑖 𝑥𝑖) – threshold))
ℎ 𝑥 = 𝑠𝑖𝑔𝑛(( 𝑑 𝑤𝑖 𝑥𝑖) + w0))
Let us introduce an artificial input x0
ℎ 𝑥 = 𝑠𝑖𝑔𝑛( 𝑑 𝑤𝑖 𝑥𝑖) where i takes values from 0 to d
In vector form: h(x) = sign(wTx)
Fig from: Yasser Mustafa, Caltech
PLA Training
• Perceptron implements: h(x) = sign(wTx)
• The goal of training is to determine the model parameters
wi’s, given the training data (x1, y1), (x2, y2)…(xn, yn).
• Note: Usually x is a vector and y can be a real number or a vector by
itself
• Training Algorithm:
• Initialize w to small random numbers
• Iterate t = 1, 2, …
• Pick a misclassified point h(𝑥 𝑛) ≠ 𝑦 𝑛
• Update the weight vector: 𝑤 ← 𝑤 + 𝑦 𝑛 𝑥 𝑛
• It can be shown that for linearly separable data the
algorithm converges in a finite number of iterations
• A learning rate α is used to control the increments to the
weight vector
Fig from: Yasser Mustafa, Caltech
Representational Power of Perceptrons
• Equation for the decision hyperplane is 𝑤. 𝑥= 0
• The space of candidate hypothesis 𝐻 = {𝑤 |𝑤 ∈ ℝ(𝑛+1)}
• A perceptron represents a hyperplane decision surface in the n-
dimensional space of data instances where the hyperplane
separates positive examples from the negative ones.
• Not all points in the input space can be separated by this
hyperplane. The ones that can be separated by the perceptron are
called linearly separable.
• Perceptrons can be used to represent many Boolean functions.
• E.g. assume logical 0 to be 0 and logical 1 to be +1. Suppose we want to
represent a 2 input AND function is to set the weights w0 = -1.5, w1 = w2 = 1.
We can design OR logic similarly by setting w0 = -0.3
• Functions like XOR are non linearly separable and so can’t be
represented by perceptrons
• The ability of the perceptrons to represent AND, OR, NAND, NOR is
important complex Boolean functions can be built combining these
-1.5
w1=1 w2=1
x0 x1 x2
-0.5
w1=1 w2=1
x0 x1 x2
Exercise
• Design a perceptron that can represent:
• NAND
• NOR
• NOT
Exercise
• Implement the Perceptron Learning Algorithm to learn the given
training dataset (Cricket player data). Test the classifier using the test
data provided and report the accuracy computed as the percentage
of correct classifications.
• Set maximum iterations to 1000, 10000, 100000
• Does this converge? If so after how many iterations?
• How many misclassified points do you get?
Ad

More Related Content

What's hot (20)

Algorithms Design Patterns
Algorithms Design PatternsAlgorithms Design Patterns
Algorithms Design Patterns
Ashwin Shiv
 
Deep Learning Sample Class (Jon Lederman)
Deep Learning Sample Class (Jon Lederman)Deep Learning Sample Class (Jon Lederman)
Deep Learning Sample Class (Jon Lederman)
Jon Lederman
 
Neural Networks and Deep Learning Basics
Neural Networks and Deep Learning BasicsNeural Networks and Deep Learning Basics
Neural Networks and Deep Learning Basics
Jon Lederman
 
Deep learning with TensorFlow
Deep learning with TensorFlowDeep learning with TensorFlow
Deep learning with TensorFlow
Barbara Fusinska
 
Machine learning Algorithms with a Sagemaker demo
Machine learning Algorithms with a Sagemaker demoMachine learning Algorithms with a Sagemaker demo
Machine learning Algorithms with a Sagemaker demo
Hridyesh Bisht
 
Neural network for machine learning
Neural network for machine learningNeural network for machine learning
Neural network for machine learning
Ujjawal
 
Introduction of Deep Reinforcement Learning
Introduction of Deep Reinforcement LearningIntroduction of Deep Reinforcement Learning
Introduction of Deep Reinforcement Learning
NAVER Engineering
 
Machine Learning Essentials Demystified part1 | Big Data Demystified
Machine Learning Essentials Demystified part1 | Big Data DemystifiedMachine Learning Essentials Demystified part1 | Big Data Demystified
Machine Learning Essentials Demystified part1 | Big Data Demystified
Omid Vahdaty
 
Dimensionality Reduction
Dimensionality ReductionDimensionality Reduction
Dimensionality Reduction
Knoldus Inc.
 
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Sangwoo Mo
 
Machine Learning Essentials Demystified part2 | Big Data Demystified
Machine Learning Essentials Demystified part2 | Big Data DemystifiedMachine Learning Essentials Demystified part2 | Big Data Demystified
Machine Learning Essentials Demystified part2 | Big Data Demystified
Omid Vahdaty
 
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Marina Santini
 
Deep Implicit Layers: Learning Structured Problems with Neural Networks
Deep Implicit Layers: Learning Structured Problems with Neural NetworksDeep Implicit Layers: Learning Structured Problems with Neural Networks
Deep Implicit Layers: Learning Structured Problems with Neural Networks
Sangwoo Mo
 
Ot regularization and_gradient_descent
Ot regularization and_gradient_descentOt regularization and_gradient_descent
Ot regularization and_gradient_descent
ankit_ppt
 
Decision trees
Decision treesDecision trees
Decision trees
Rohit Srivastava
 
Reinforcement Learning and Artificial Neural Nets
Reinforcement Learning and Artificial Neural NetsReinforcement Learning and Artificial Neural Nets
Reinforcement Learning and Artificial Neural Nets
Pierre de Lacaze
 
Deep learning paper review ppt sourece -Direct clr
Deep learning paper review ppt sourece -Direct clr Deep learning paper review ppt sourece -Direct clr
Deep learning paper review ppt sourece -Direct clr
taeseon ryu
 
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
Daiki Tanaka
 
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Chris Ohk
 
Ml10 dimensionality reduction-and_advanced_topics
Ml10 dimensionality reduction-and_advanced_topicsMl10 dimensionality reduction-and_advanced_topics
Ml10 dimensionality reduction-and_advanced_topics
ankit_ppt
 
Algorithms Design Patterns
Algorithms Design PatternsAlgorithms Design Patterns
Algorithms Design Patterns
Ashwin Shiv
 
Deep Learning Sample Class (Jon Lederman)
Deep Learning Sample Class (Jon Lederman)Deep Learning Sample Class (Jon Lederman)
Deep Learning Sample Class (Jon Lederman)
Jon Lederman
 
Neural Networks and Deep Learning Basics
Neural Networks and Deep Learning BasicsNeural Networks and Deep Learning Basics
Neural Networks and Deep Learning Basics
Jon Lederman
 
Deep learning with TensorFlow
Deep learning with TensorFlowDeep learning with TensorFlow
Deep learning with TensorFlow
Barbara Fusinska
 
Machine learning Algorithms with a Sagemaker demo
Machine learning Algorithms with a Sagemaker demoMachine learning Algorithms with a Sagemaker demo
Machine learning Algorithms with a Sagemaker demo
Hridyesh Bisht
 
Neural network for machine learning
Neural network for machine learningNeural network for machine learning
Neural network for machine learning
Ujjawal
 
Introduction of Deep Reinforcement Learning
Introduction of Deep Reinforcement LearningIntroduction of Deep Reinforcement Learning
Introduction of Deep Reinforcement Learning
NAVER Engineering
 
Machine Learning Essentials Demystified part1 | Big Data Demystified
Machine Learning Essentials Demystified part1 | Big Data DemystifiedMachine Learning Essentials Demystified part1 | Big Data Demystified
Machine Learning Essentials Demystified part1 | Big Data Demystified
Omid Vahdaty
 
Dimensionality Reduction
Dimensionality ReductionDimensionality Reduction
Dimensionality Reduction
Knoldus Inc.
 
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Challenging Common Assumptions in the Unsupervised Learning of Disentangled R...
Sangwoo Mo
 
Machine Learning Essentials Demystified part2 | Big Data Demystified
Machine Learning Essentials Demystified part2 | Big Data DemystifiedMachine Learning Essentials Demystified part2 | Big Data Demystified
Machine Learning Essentials Demystified part2 | Big Data Demystified
Omid Vahdaty
 
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Lecture 02: Machine Learning for Language Technology - Decision Trees and Nea...
Marina Santini
 
Deep Implicit Layers: Learning Structured Problems with Neural Networks
Deep Implicit Layers: Learning Structured Problems with Neural NetworksDeep Implicit Layers: Learning Structured Problems with Neural Networks
Deep Implicit Layers: Learning Structured Problems with Neural Networks
Sangwoo Mo
 
Ot regularization and_gradient_descent
Ot regularization and_gradient_descentOt regularization and_gradient_descent
Ot regularization and_gradient_descent
ankit_ppt
 
Reinforcement Learning and Artificial Neural Nets
Reinforcement Learning and Artificial Neural NetsReinforcement Learning and Artificial Neural Nets
Reinforcement Learning and Artificial Neural Nets
Pierre de Lacaze
 
Deep learning paper review ppt sourece -Direct clr
Deep learning paper review ppt sourece -Direct clr Deep learning paper review ppt sourece -Direct clr
Deep learning paper review ppt sourece -Direct clr
taeseon ryu
 
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
[Paper reading] L-SHAPLEY AND C-SHAPLEY: EFFICIENT MODEL INTERPRETATION FOR S...
Daiki Tanaka
 
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Evolving Reinforcement Learning Algorithms, JD. Co-Reyes et al, 2021
Chris Ohk
 
Ml10 dimensionality reduction-and_advanced_topics
Ml10 dimensionality reduction-and_advanced_topicsMl10 dimensionality reduction-and_advanced_topics
Ml10 dimensionality reduction-and_advanced_topics
ankit_ppt
 

Viewers also liked (20)

L05 word representation
L05 word representationL05 word representation
L05 word representation
ananth
 
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
Toshiki Sakai
 
Course - Machine Learning Basics with R
Course - Machine Learning Basics with R Course - Machine Learning Basics with R
Course - Machine Learning Basics with R
Persontyle
 
Natural Language Processing: L03 maths fornlp
Natural Language Processing: L03 maths fornlpNatural Language Processing: L03 maths fornlp
Natural Language Processing: L03 maths fornlp
ananth
 
Introduction To Applied Machine Learning
Introduction To Applied Machine LearningIntroduction To Applied Machine Learning
Introduction To Applied Machine Learning
ananth
 
Natural Language Processing: L02 words
Natural Language Processing: L02 wordsNatural Language Processing: L02 words
Natural Language Processing: L02 words
ananth
 
Deep Learning For Practitioners, lecture 2: Selecting the right applications...
Deep Learning For Practitioners,  lecture 2: Selecting the right applications...Deep Learning For Practitioners,  lecture 2: Selecting the right applications...
Deep Learning For Practitioners, lecture 2: Selecting the right applications...
ananth
 
Overview of TensorFlow For Natural Language Processing
Overview of TensorFlow For Natural Language ProcessingOverview of TensorFlow For Natural Language Processing
Overview of TensorFlow For Natural Language Processing
ananth
 
Natural Language Processing: L01 introduction
Natural Language Processing: L01 introductionNatural Language Processing: L01 introduction
Natural Language Processing: L01 introduction
ananth
 
Big ideas 2015
Big ideas 2015Big ideas 2015
Big ideas 2015
Swati Piramal
 
Secrets of e marketing success 2016 presentation
Secrets of e marketing success 2016 presentationSecrets of e marketing success 2016 presentation
Secrets of e marketing success 2016 presentation
Martha Lord
 
Atlassian User Group, AUG Wiesbaden, 25 October 2012
Atlassian User Group, AUG Wiesbaden, 25 October 2012Atlassian User Group, AUG Wiesbaden, 25 October 2012
Atlassian User Group, AUG Wiesbaden, 25 October 2012
Sarah Maddox
 
Giving feedback & Scrum
Giving feedback & ScrumGiving feedback & Scrum
Giving feedback & Scrum
Johan Hoberg
 
CISOs are from Mars, CIOs are from Venus
CISOs are from Mars, CIOs are from VenusCISOs are from Mars, CIOs are from Venus
CISOs are from Mars, CIOs are from Venus
Barry Caplin
 
Network Security Expert and Risk Analyst
Network Security Expert and Risk AnalystNetwork Security Expert and Risk Analyst
Network Security Expert and Risk Analyst
Ashok K DL
 
Slides for burroughs wellcome foundation ajw100611 sefinal
Slides for burroughs wellcome foundation ajw100611 sefinalSlides for burroughs wellcome foundation ajw100611 sefinal
Slides for burroughs wellcome foundation ajw100611 sefinal
Sean Ekins
 
orchid island 蘭嶼
orchid island 蘭嶼orchid island 蘭嶼
orchid island 蘭嶼
kkjjkevin03
 
Dung Cho Den Ngay Mai
Dung Cho Den Ngay MaiDung Cho Den Ngay Mai
Dung Cho Den Ngay Mai
thuyvu75
 
Test driven infrastructure development
Test driven infrastructure developmentTest driven infrastructure development
Test driven infrastructure development
Tomas Doran
 
CV_akansh doc
CV_akansh docCV_akansh doc
CV_akansh doc
Akansh Jain
 
L05 word representation
L05 word representationL05 word representation
L05 word representation
ananth
 
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
CNN-RNN: A Unified Framework for Multi-label Image Classification@CV勉強会35回CVP...
Toshiki Sakai
 
Course - Machine Learning Basics with R
Course - Machine Learning Basics with R Course - Machine Learning Basics with R
Course - Machine Learning Basics with R
Persontyle
 
Natural Language Processing: L03 maths fornlp
Natural Language Processing: L03 maths fornlpNatural Language Processing: L03 maths fornlp
Natural Language Processing: L03 maths fornlp
ananth
 
Introduction To Applied Machine Learning
Introduction To Applied Machine LearningIntroduction To Applied Machine Learning
Introduction To Applied Machine Learning
ananth
 
Natural Language Processing: L02 words
Natural Language Processing: L02 wordsNatural Language Processing: L02 words
Natural Language Processing: L02 words
ananth
 
Deep Learning For Practitioners, lecture 2: Selecting the right applications...
Deep Learning For Practitioners,  lecture 2: Selecting the right applications...Deep Learning For Practitioners,  lecture 2: Selecting the right applications...
Deep Learning For Practitioners, lecture 2: Selecting the right applications...
ananth
 
Overview of TensorFlow For Natural Language Processing
Overview of TensorFlow For Natural Language ProcessingOverview of TensorFlow For Natural Language Processing
Overview of TensorFlow For Natural Language Processing
ananth
 
Natural Language Processing: L01 introduction
Natural Language Processing: L01 introductionNatural Language Processing: L01 introduction
Natural Language Processing: L01 introduction
ananth
 
Secrets of e marketing success 2016 presentation
Secrets of e marketing success 2016 presentationSecrets of e marketing success 2016 presentation
Secrets of e marketing success 2016 presentation
Martha Lord
 
Atlassian User Group, AUG Wiesbaden, 25 October 2012
Atlassian User Group, AUG Wiesbaden, 25 October 2012Atlassian User Group, AUG Wiesbaden, 25 October 2012
Atlassian User Group, AUG Wiesbaden, 25 October 2012
Sarah Maddox
 
Giving feedback & Scrum
Giving feedback & ScrumGiving feedback & Scrum
Giving feedback & Scrum
Johan Hoberg
 
CISOs are from Mars, CIOs are from Venus
CISOs are from Mars, CIOs are from VenusCISOs are from Mars, CIOs are from Venus
CISOs are from Mars, CIOs are from Venus
Barry Caplin
 
Network Security Expert and Risk Analyst
Network Security Expert and Risk AnalystNetwork Security Expert and Risk Analyst
Network Security Expert and Risk Analyst
Ashok K DL
 
Slides for burroughs wellcome foundation ajw100611 sefinal
Slides for burroughs wellcome foundation ajw100611 sefinalSlides for burroughs wellcome foundation ajw100611 sefinal
Slides for burroughs wellcome foundation ajw100611 sefinal
Sean Ekins
 
orchid island 蘭嶼
orchid island 蘭嶼orchid island 蘭嶼
orchid island 蘭嶼
kkjjkevin03
 
Dung Cho Den Ngay Mai
Dung Cho Den Ngay MaiDung Cho Den Ngay Mai
Dung Cho Den Ngay Mai
thuyvu75
 
Test driven infrastructure development
Test driven infrastructure developmentTest driven infrastructure development
Test driven infrastructure development
Tomas Doran
 
Ad

Similar to Machine Learning Lecture 2 Basics (20)

Intro to machine learning
Intro to machine learningIntro to machine learning
Intro to machine learning
Akshay Kanchan
 
Learning
LearningLearning
Learning
Amar Jukuntla
 
Data Science and Machine Learning with Tensorflow
 Data Science and Machine Learning with Tensorflow Data Science and Machine Learning with Tensorflow
Data Science and Machine Learning with Tensorflow
Shubham Sharma
 
Machine Learning using Support Vector Machine
Machine Learning using Support Vector MachineMachine Learning using Support Vector Machine
Machine Learning using Support Vector Machine
Mohsin Ul Haq
 
Lecture 5 machine learning updated
Lecture 5   machine learning updatedLecture 5   machine learning updated
Lecture 5 machine learning updated
Vajira Thambawita
 
Machine Learning Lecture 3 Decision Trees
Machine Learning Lecture 3 Decision TreesMachine Learning Lecture 3 Decision Trees
Machine Learning Lecture 3 Decision Trees
ananth
 
Explainable algorithm evaluation from lessons in education
Explainable algorithm evaluation from lessons in educationExplainable algorithm evaluation from lessons in education
Explainable algorithm evaluation from lessons in education
CSIRO
 
EssentialsOfMachineLearning.pdf
EssentialsOfMachineLearning.pdfEssentialsOfMachineLearning.pdf
EssentialsOfMachineLearning.pdf
Ankita Tiwari
 
An Introduction to Reinforcement Learning - The Doors to AGI
An Introduction to Reinforcement Learning - The Doors to AGIAn Introduction to Reinforcement Learning - The Doors to AGI
An Introduction to Reinforcement Learning - The Doors to AGI
Anirban Santara
 
Automated attendance system based on facial recognition
Automated attendance system based on facial recognitionAutomated attendance system based on facial recognition
Automated attendance system based on facial recognition
Dhanush Kasargod
 
04 Classification in Data Mining
04 Classification in Data Mining04 Classification in Data Mining
04 Classification in Data Mining
Valerii Klymchuk
 
Unit 3 – AIML.pptx
Unit 3 – AIML.pptxUnit 3 – AIML.pptx
Unit 3 – AIML.pptx
hiblooms
 
Application of Machine Learning in Agriculture
Application of Machine  Learning in AgricultureApplication of Machine  Learning in Agriculture
Application of Machine Learning in Agriculture
Aman Vasisht
 
Machine Learning: Introduction to Neural Networks
Machine Learning: Introduction to Neural NetworksMachine Learning: Introduction to Neural Networks
Machine Learning: Introduction to Neural Networks
Francesco Collova'
 
introduction to machine learning 3c-feature-extraction.pptx
introduction to machine learning 3c-feature-extraction.pptxintroduction to machine learning 3c-feature-extraction.pptx
introduction to machine learning 3c-feature-extraction.pptx
Pratik Gohel
 
Machine Learning on Azure - AzureConf
Machine Learning on Azure - AzureConfMachine Learning on Azure - AzureConf
Machine Learning on Azure - AzureConf
Seth Juarez
 
03 Data Mining Techniques
03 Data Mining Techniques03 Data Mining Techniques
03 Data Mining Techniques
Valerii Klymchuk
 
Week_1 Machine Learning introduction.pptx
Week_1 Machine Learning introduction.pptxWeek_1 Machine Learning introduction.pptx
Week_1 Machine Learning introduction.pptx
muhammadsamroz
 
Learning Method In Data Mining
Learning Method In Data MiningLearning Method In Data Mining
Learning Method In Data Mining
ishaq zaman
 
Machine learning
Machine learningMachine learning
Machine learning
Sukhwinder Singh
 
Intro to machine learning
Intro to machine learningIntro to machine learning
Intro to machine learning
Akshay Kanchan
 
Data Science and Machine Learning with Tensorflow
 Data Science and Machine Learning with Tensorflow Data Science and Machine Learning with Tensorflow
Data Science and Machine Learning with Tensorflow
Shubham Sharma
 
Machine Learning using Support Vector Machine
Machine Learning using Support Vector MachineMachine Learning using Support Vector Machine
Machine Learning using Support Vector Machine
Mohsin Ul Haq
 
Lecture 5 machine learning updated
Lecture 5   machine learning updatedLecture 5   machine learning updated
Lecture 5 machine learning updated
Vajira Thambawita
 
Machine Learning Lecture 3 Decision Trees
Machine Learning Lecture 3 Decision TreesMachine Learning Lecture 3 Decision Trees
Machine Learning Lecture 3 Decision Trees
ananth
 
Explainable algorithm evaluation from lessons in education
Explainable algorithm evaluation from lessons in educationExplainable algorithm evaluation from lessons in education
Explainable algorithm evaluation from lessons in education
CSIRO
 
EssentialsOfMachineLearning.pdf
EssentialsOfMachineLearning.pdfEssentialsOfMachineLearning.pdf
EssentialsOfMachineLearning.pdf
Ankita Tiwari
 
An Introduction to Reinforcement Learning - The Doors to AGI
An Introduction to Reinforcement Learning - The Doors to AGIAn Introduction to Reinforcement Learning - The Doors to AGI
An Introduction to Reinforcement Learning - The Doors to AGI
Anirban Santara
 
Automated attendance system based on facial recognition
Automated attendance system based on facial recognitionAutomated attendance system based on facial recognition
Automated attendance system based on facial recognition
Dhanush Kasargod
 
04 Classification in Data Mining
04 Classification in Data Mining04 Classification in Data Mining
04 Classification in Data Mining
Valerii Klymchuk
 
Unit 3 – AIML.pptx
Unit 3 – AIML.pptxUnit 3 – AIML.pptx
Unit 3 – AIML.pptx
hiblooms
 
Application of Machine Learning in Agriculture
Application of Machine  Learning in AgricultureApplication of Machine  Learning in Agriculture
Application of Machine Learning in Agriculture
Aman Vasisht
 
Machine Learning: Introduction to Neural Networks
Machine Learning: Introduction to Neural NetworksMachine Learning: Introduction to Neural Networks
Machine Learning: Introduction to Neural Networks
Francesco Collova'
 
introduction to machine learning 3c-feature-extraction.pptx
introduction to machine learning 3c-feature-extraction.pptxintroduction to machine learning 3c-feature-extraction.pptx
introduction to machine learning 3c-feature-extraction.pptx
Pratik Gohel
 
Machine Learning on Azure - AzureConf
Machine Learning on Azure - AzureConfMachine Learning on Azure - AzureConf
Machine Learning on Azure - AzureConf
Seth Juarez
 
Week_1 Machine Learning introduction.pptx
Week_1 Machine Learning introduction.pptxWeek_1 Machine Learning introduction.pptx
Week_1 Machine Learning introduction.pptx
muhammadsamroz
 
Learning Method In Data Mining
Learning Method In Data MiningLearning Method In Data Mining
Learning Method In Data Mining
ishaq zaman
 
Ad

More from ananth (11)

Convolutional Neural Networks : Popular Architectures
Convolutional Neural Networks : Popular ArchitecturesConvolutional Neural Networks : Popular Architectures
Convolutional Neural Networks : Popular Architectures
ananth
 
Overview of Convolutional Neural Networks
Overview of Convolutional Neural NetworksOverview of Convolutional Neural Networks
Overview of Convolutional Neural Networks
ananth
 
An Overview of Naïve Bayes Classifier
An Overview of Naïve Bayes Classifier An Overview of Naïve Bayes Classifier
An Overview of Naïve Bayes Classifier
ananth
 
Search problems in Artificial Intelligence
Search problems in Artificial IntelligenceSearch problems in Artificial Intelligence
Search problems in Artificial Intelligence
ananth
 
Introduction to Artificial Intelligence
Introduction to Artificial IntelligenceIntroduction to Artificial Intelligence
Introduction to Artificial Intelligence
ananth
 
Word representation: SVD, LSA, Word2Vec
Word representation: SVD, LSA, Word2VecWord representation: SVD, LSA, Word2Vec
Word representation: SVD, LSA, Word2Vec
ananth
 
Deep Learning For Speech Recognition
Deep Learning For Speech RecognitionDeep Learning For Speech Recognition
Deep Learning For Speech Recognition
ananth
 
Convolutional Neural Networks: Part 1
Convolutional Neural Networks: Part 1Convolutional Neural Networks: Part 1
Convolutional Neural Networks: Part 1
ananth
 
Recurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRURecurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRU
ananth
 
MaxEnt (Loglinear) Models - Overview
MaxEnt (Loglinear) Models - OverviewMaxEnt (Loglinear) Models - Overview
MaxEnt (Loglinear) Models - Overview
ananth
 
Deep Learning Primer - a brief introduction
Deep Learning Primer - a brief introductionDeep Learning Primer - a brief introduction
Deep Learning Primer - a brief introduction
ananth
 
Convolutional Neural Networks : Popular Architectures
Convolutional Neural Networks : Popular ArchitecturesConvolutional Neural Networks : Popular Architectures
Convolutional Neural Networks : Popular Architectures
ananth
 
Overview of Convolutional Neural Networks
Overview of Convolutional Neural NetworksOverview of Convolutional Neural Networks
Overview of Convolutional Neural Networks
ananth
 
An Overview of Naïve Bayes Classifier
An Overview of Naïve Bayes Classifier An Overview of Naïve Bayes Classifier
An Overview of Naïve Bayes Classifier
ananth
 
Search problems in Artificial Intelligence
Search problems in Artificial IntelligenceSearch problems in Artificial Intelligence
Search problems in Artificial Intelligence
ananth
 
Introduction to Artificial Intelligence
Introduction to Artificial IntelligenceIntroduction to Artificial Intelligence
Introduction to Artificial Intelligence
ananth
 
Word representation: SVD, LSA, Word2Vec
Word representation: SVD, LSA, Word2VecWord representation: SVD, LSA, Word2Vec
Word representation: SVD, LSA, Word2Vec
ananth
 
Deep Learning For Speech Recognition
Deep Learning For Speech RecognitionDeep Learning For Speech Recognition
Deep Learning For Speech Recognition
ananth
 
Convolutional Neural Networks: Part 1
Convolutional Neural Networks: Part 1Convolutional Neural Networks: Part 1
Convolutional Neural Networks: Part 1
ananth
 
Recurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRURecurrent Neural Networks, LSTM and GRU
Recurrent Neural Networks, LSTM and GRU
ananth
 
MaxEnt (Loglinear) Models - Overview
MaxEnt (Loglinear) Models - OverviewMaxEnt (Loglinear) Models - Overview
MaxEnt (Loglinear) Models - Overview
ananth
 
Deep Learning Primer - a brief introduction
Deep Learning Primer - a brief introductionDeep Learning Primer - a brief introduction
Deep Learning Primer - a brief introduction
ananth
 

Recently uploaded (20)

Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Middle East and Africa Cybersecurity Market Trends and Growth Analysis Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Preeti Jha
 
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Gary Arora
 
machines-for-woodworking-shops-en-compressed.pdf
machines-for-woodworking-shops-en-compressed.pdfmachines-for-woodworking-shops-en-compressed.pdf
machines-for-woodworking-shops-en-compressed.pdf
AmirStern2
 
Mastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B LandscapeMastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B Landscape
marketing943205
 
DNF 2.0 Implementations Challenges in Nepal
DNF 2.0 Implementations Challenges in NepalDNF 2.0 Implementations Challenges in Nepal
DNF 2.0 Implementations Challenges in Nepal
ICT Frame Magazine Pvt. Ltd.
 
Understanding SEO in the Age of AI.pdf
Understanding SEO in the Age of AI.pdfUnderstanding SEO in the Age of AI.pdf
Understanding SEO in the Age of AI.pdf
Fulcrum Concepts, LLC
 
Computer Systems Quiz Presentation in Purple Bold Style (4).pdf
Computer Systems Quiz Presentation in Purple Bold Style (4).pdfComputer Systems Quiz Presentation in Purple Bold Style (4).pdf
Computer Systems Quiz Presentation in Purple Bold Style (4).pdf
fizarcse
 
May Patch Tuesday
May Patch TuesdayMay Patch Tuesday
May Patch Tuesday
Ivanti
 
accessibility Considerations during Design by Rick Blair, Schneider Electric
accessibility Considerations during Design by Rick Blair, Schneider Electricaccessibility Considerations during Design by Rick Blair, Schneider Electric
accessibility Considerations during Design by Rick Blair, Schneider Electric
UXPA Boston
 
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Vasileios Komianos
 
Building a research repository that works by Clare Cady
Building a research repository that works by Clare CadyBuilding a research repository that works by Clare Cady
Building a research repository that works by Clare Cady
UXPA Boston
 
Best 10 Free AI Character Chat Platforms
Best 10 Free AI Character Chat PlatformsBest 10 Free AI Character Chat Platforms
Best 10 Free AI Character Chat Platforms
Soulmaite
 
Right to liberty and security of a person.pdf
Right to liberty and security of a person.pdfRight to liberty and security of a person.pdf
Right to liberty and security of a person.pdf
danielbraico197
 
Cybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft CertificateCybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft Certificate
VICTOR MAESTRE RAMIREZ
 
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
UXPA Boston
 
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptxDevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
Justin Reock
 
AI x Accessibility UXPA by Stew Smith and Olivier Vroom
AI x Accessibility UXPA by Stew Smith and Olivier VroomAI x Accessibility UXPA by Stew Smith and Olivier Vroom
AI x Accessibility UXPA by Stew Smith and Olivier Vroom
UXPA Boston
 
How Top Companies Benefit from Outsourcing
How Top Companies Benefit from OutsourcingHow Top Companies Benefit from Outsourcing
How Top Companies Benefit from Outsourcing
Nascenture
 
Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)
Kaya Weers
 
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptxIn-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
aptyai
 
Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Middle East and Africa Cybersecurity Market Trends and Growth Analysis Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Middle East and Africa Cybersecurity Market Trends and Growth Analysis
Preeti Jha
 
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Harmonizing Multi-Agent Intelligence | Open Data Science Conference | Gary Ar...
Gary Arora
 
machines-for-woodworking-shops-en-compressed.pdf
machines-for-woodworking-shops-en-compressed.pdfmachines-for-woodworking-shops-en-compressed.pdf
machines-for-woodworking-shops-en-compressed.pdf
AmirStern2
 
Mastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B LandscapeMastering Testing in the Modern F&B Landscape
Mastering Testing in the Modern F&B Landscape
marketing943205
 
Understanding SEO in the Age of AI.pdf
Understanding SEO in the Age of AI.pdfUnderstanding SEO in the Age of AI.pdf
Understanding SEO in the Age of AI.pdf
Fulcrum Concepts, LLC
 
Computer Systems Quiz Presentation in Purple Bold Style (4).pdf
Computer Systems Quiz Presentation in Purple Bold Style (4).pdfComputer Systems Quiz Presentation in Purple Bold Style (4).pdf
Computer Systems Quiz Presentation in Purple Bold Style (4).pdf
fizarcse
 
May Patch Tuesday
May Patch TuesdayMay Patch Tuesday
May Patch Tuesday
Ivanti
 
accessibility Considerations during Design by Rick Blair, Schneider Electric
accessibility Considerations during Design by Rick Blair, Schneider Electricaccessibility Considerations during Design by Rick Blair, Schneider Electric
accessibility Considerations during Design by Rick Blair, Schneider Electric
UXPA Boston
 
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Digital Technologies for Culture, Arts and Heritage: Insights from Interdisci...
Vasileios Komianos
 
Building a research repository that works by Clare Cady
Building a research repository that works by Clare CadyBuilding a research repository that works by Clare Cady
Building a research repository that works by Clare Cady
UXPA Boston
 
Best 10 Free AI Character Chat Platforms
Best 10 Free AI Character Chat PlatformsBest 10 Free AI Character Chat Platforms
Best 10 Free AI Character Chat Platforms
Soulmaite
 
Right to liberty and security of a person.pdf
Right to liberty and security of a person.pdfRight to liberty and security of a person.pdf
Right to liberty and security of a person.pdf
danielbraico197
 
Cybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft CertificateCybersecurity Tools and Technologies - Microsoft Certificate
Cybersecurity Tools and Technologies - Microsoft Certificate
VICTOR MAESTRE RAMIREZ
 
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
Developing Product-Behavior Fit: UX Research in Product Development by Krysta...
UXPA Boston
 
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptxDevOpsDays SLC - Platform Engineers are Product Managers.pptx
DevOpsDays SLC - Platform Engineers are Product Managers.pptx
Justin Reock
 
AI x Accessibility UXPA by Stew Smith and Olivier Vroom
AI x Accessibility UXPA by Stew Smith and Olivier VroomAI x Accessibility UXPA by Stew Smith and Olivier Vroom
AI x Accessibility UXPA by Stew Smith and Olivier Vroom
UXPA Boston
 
How Top Companies Benefit from Outsourcing
How Top Companies Benefit from OutsourcingHow Top Companies Benefit from Outsourcing
How Top Companies Benefit from Outsourcing
Nascenture
 
Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)Design pattern talk by Kaya Weers - 2025 (v2)
Design pattern talk by Kaya Weers - 2025 (v2)
Kaya Weers
 
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptxIn-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
In-App Guidance_ Save Enterprises Millions in Training & IT Costs.pptx
aptyai
 

Machine Learning Lecture 2 Basics

  • 1. Machine Learning: Basics Applied Machine Learning: Unit 1, Lecture 1 Anantharaman Narayana Iyer narayana dot Anantharaman at gmail dot com 9th Jan 2016
  • 2. Types of Learning Algorithms • Supervised • Given a set of pairs (x, y) where y is a label (or class) and x is an observation, discover a function that assigns the correct labels to the x. • Unsupervised • The data is unlabelled. We need to explore the data to discover the intrinsic structures in them • Semi supervised • Part of the data is labelled while the rest is unlabelled. The labelled data is used to bootstrap. For example deep learning architectures leverage the vast amount of unlabelled data available over the web and use a small quantity of labelled data for finetuning. • Reinforcement • Reinforcement learning (RL) is learning by interacting with an environment. An RL agent learns from the consequences of its actions, rather than from being explicitly taught and it selects its actions on basis of its past experiences (exploitation) and also by new choices (exploration), which is essentially trial and error learning.
  • 3. x1 x2 Supervised Learning L1 L2 L5 L3 L4 Class = True Class = False Key Concepts • Supervised learning is a technique where the classifier is trained using training examples • The training examples contain the input attributes (Features) and the expected outputs. • In the Fig, X1 and X2 are the features • The input typically is a n-dimensional vector and output may have 1 or more dimensions • A Binary Classifier classifies the input vector in to one of the two states • Illustrated by Red and Purple boxes in the fig • A linearly separable system is one where the class labels can be separated by a linear decision boundary. • The straight lines L1, L2, L3, L4, L5 show different decision boundaries in the Fig • The example in the Fig is 2 dimensional linearly separable system. It can be generalized to an n-dimensional system. The decision surface is then called an Hyperplane • Each decision surface can be considered to be a Hypothesis
  • 4. x1 x2 Unsupervised Learning Cluster = 2 Cluster = 1 Key Concepts • Unsupervised techniques do not require the expected outputs to be specified in the dataset. • This has an advantage as the availability of labelled data is scarce relative to the vast amount of data that is available in Web and other media. • Clustering is one of the machine learning algorithms that belongs to the category of unsupervised learning • In the Fig the system finds inputs that can be logically grouped together as a cluster. The example shows 2 such clusters.
  • 5. Classification and Regression Problems • The term regression refers to a system with a continuous variable as the output • Classification is a process by which the machine learning system partitions the input space in a to discrete set of classes • Example: • Credit card approval (Approve, Not approved decisions) • Credit line limit • Home loan approval • Sentiment Polarity (Positive, Negative, Neutral) • Sentiment as a real number: -1 <= sentiment <= 1
  • 6. Notations • • m = Number of training examples • n = Number of features in the input example • x’s = “input” variable / features • y’s = “output” variable / “target” variable • The unknown target function f maps the input space to the outputs as: f: X -> Y
  • 7. Problem Statement: ML Classifier • Given a finite set of training examples and the space of all applicable hypothesis, select a hypothesis that best approximates the unknown target function. • The unknown target function f is the ideal function that characterizes the underlying pattern that generated the data • Training examples are provided to the ML designer • The output of this process is a hypothesis g that approximates f • The hypothesis set and the learning algorithm constitutes the solution set. Fig from: Yasser Mustafa, Caltech
  • 8. Let’s begin: Perceptron Learning • National cricket team selectors choose the team members of the team and thus play a key role in the performance of the team. • Suppose we want to build a system that acts as a “virtual selector” by selecting (or rejecting) a player given the data on his past performances. • Let us consider a selector who looks at only 2 input variables: Batting Average, Bowling Average. • Here, the features are: x1 = Batting Average, x2 = Bowling Average • Let us consider PLA for this purpose
  • 9. Example data PLAYER BATTING AVERAGE BOWLING AVERAGE SELECTED Shikhar Dhawan 45.46 -1 Yes Rohit Sharma 37.89 60.37 Yes Ajinkya Rahane 29.28 -1 Yes Virat Kohli 52.61 145.5 Yes Suresh Raina 35.82 48 Yes Ambati Rayudu 60 53 Yes Kedar Jadhav 20 -1 No Manoj Tiwary 31.62 28.8 No Manish Pandey -1 -1 No Murali Vijay 19.46 -1 No MS Dhoni 52.85 31 Yes Wriddhiman Saha 13.66 -1 No Robin Uthappa 26.96 -1 No Sanju Samson -1 -1 No Ravindra Jadeja 34.51 32.29 Yes Akshar Patel 20 20.28 Yes Stuart Binny 13.33 13 Yes Parvez Rasool -1 30 Yes R Ashwin 16.91 32.46 Yes Karn Sharma -1 -1 No Amit Mishra 4.8 23.95 No Kuldeep Yadav -1 -1 No Ishant Sharma 5.14 31.25 Yes Bhuvneshwar Kumar 10.4 36.59 Yes Mohammed Shami 9.12 26.08 Yes Umesh Yadav 14.66 35.93 Yes Varun Aaron 8 38.09 No Dhawal Kulkarni -1 23 No Mohit Sharma -1 58 No Ashok Dinda 4.2 51 No
  • 10. 45.46, 100 37.89, 60.37 29.28, 100 52.61, 100 35.82, 48 60, 53 20, 100 31.62, 28.8 0, 100 19.46, 100 52.85, 31 13.66, 100 26.96, 1000, 100 34.51, 32.29 20, 20.28 13.33, 13 0, 30 16.91, 32.46 0, 100 4.8, 23.95 0, 100 5.14, 31.25 10.4, 36.59 9.12, 26.08 14.66, 35.93 8, 38.09 0, 23 0, 58 4.2, 51 0 20 40 60 80 100 120 0 10 20 30 40 50 60 70 Visualization of team performance
  • 11. PLA Model x = (x1, x2) where x1, x2 are the features of a given data sample Select the player if 𝑑 𝑤𝑖 𝑥𝑖 > 𝑡ℎ𝑟𝑒𝑠ℎ𝑜𝑙𝑑 𝑒𝑙𝑠𝑒 𝑟𝑒𝑗𝑒𝑐𝑡 The above can be written as: ℎ 𝑥 = 𝑠𝑖𝑔𝑛(( 𝑑 𝑤𝑖 𝑥𝑖) – threshold)) ℎ 𝑥 = 𝑠𝑖𝑔𝑛(( 𝑑 𝑤𝑖 𝑥𝑖) + w0)) Let us introduce an artificial input x0 ℎ 𝑥 = 𝑠𝑖𝑔𝑛( 𝑑 𝑤𝑖 𝑥𝑖) where i takes values from 0 to d In vector form: h(x) = sign(wTx) Fig from: Yasser Mustafa, Caltech
  • 12. PLA Training • Perceptron implements: h(x) = sign(wTx) • The goal of training is to determine the model parameters wi’s, given the training data (x1, y1), (x2, y2)…(xn, yn). • Note: Usually x is a vector and y can be a real number or a vector by itself • Training Algorithm: • Initialize w to small random numbers • Iterate t = 1, 2, … • Pick a misclassified point h(𝑥 𝑛) ≠ 𝑦 𝑛 • Update the weight vector: 𝑤 ← 𝑤 + 𝑦 𝑛 𝑥 𝑛 • It can be shown that for linearly separable data the algorithm converges in a finite number of iterations • A learning rate α is used to control the increments to the weight vector Fig from: Yasser Mustafa, Caltech
  • 13. Representational Power of Perceptrons • Equation for the decision hyperplane is 𝑤. 𝑥= 0 • The space of candidate hypothesis 𝐻 = {𝑤 |𝑤 ∈ ℝ(𝑛+1)} • A perceptron represents a hyperplane decision surface in the n- dimensional space of data instances where the hyperplane separates positive examples from the negative ones. • Not all points in the input space can be separated by this hyperplane. The ones that can be separated by the perceptron are called linearly separable. • Perceptrons can be used to represent many Boolean functions. • E.g. assume logical 0 to be 0 and logical 1 to be +1. Suppose we want to represent a 2 input AND function is to set the weights w0 = -1.5, w1 = w2 = 1. We can design OR logic similarly by setting w0 = -0.3 • Functions like XOR are non linearly separable and so can’t be represented by perceptrons • The ability of the perceptrons to represent AND, OR, NAND, NOR is important complex Boolean functions can be built combining these -1.5 w1=1 w2=1 x0 x1 x2 -0.5 w1=1 w2=1 x0 x1 x2
  • 14. Exercise • Design a perceptron that can represent: • NAND • NOR • NOT
  • 15. Exercise • Implement the Perceptron Learning Algorithm to learn the given training dataset (Cricket player data). Test the classifier using the test data provided and report the accuracy computed as the percentage of correct classifications. • Set maximum iterations to 1000, 10000, 100000 • Does this converge? If so after how many iterations? • How many misclassified points do you get?