Chapter 01 Introduction To Machine Learning
Chapter 01 Introduction To Machine Learning
Dr. ShuvenduRana
SRM University-AP, Amaravati, India
shuvendu.r@srmap.edu.in
1
Machine Learning
Objectives:
1. This course will serve as a comprehensive introduction to
various topics in machine learning.
2. Introduce various algorithms related to classification,
regression, clustering.
Actually
Most work and you know why
3
Marks Distribution
Conducting Final
Final Assessment tool
Marks Conversion
End semester theory
Final exam 100 30
exam
End semester Practical Final Practical/Term
100 20
exam Project
Total 50
4
What is Learning?
Input Input
Machine Machine
Input Output Model
(Program)
Output Output
5
Machine Learning
6
Types of Learning
7
Syllabus: Machine Learning
8
Books: Machine Learning
10
Topics
11
What is Learning?
Input Input
Machine Machine
Input Output Model
(Program)
Output Output
12
Formal Definition
13
Defining the Learning Task
(Well-posed Learning Problem)
Improve on task, T, with respect to
performance metric, P, based on experience, E.
Example
T: Playing checkers
P: Percentage of games won against an arbitrary
opponent
E: Playing practice games against itself
Example
T: Recognizing hand-written words
P: Percentage of words correctly classified
E: Database of human-labeled images of handwritten
words
14
Defining the Learning Task
(Well-posed Learning Problem)
Improve on task, T, with respect to
performance metric, P, based on experience, E.
Example:
T: Driving on four-lane highways using vision sensors
P: Average distance traveled before a human-judged
error
E: A sequence of images and steering commands
recorded while observing a human driver.
Example
T: Categorize email messages as spam or legitimate.
P: Percentage of email messages correctly classified.
E: Database of emails, some with human-given labels
15
Types of Learning
16
Types of Learning?
17
Types of Learning?
18
Types of Learning?
19
Types of Learning?
20
Types of Learning
21
Types of Learning?
22
Task solved using Supervised Learning
23
Classification (Examples)
• Assign object/event to one of a given finite set of
categories.
– Medical diagnosis
– Credit card applications or transactions
– Fraud detection in e-commerce
– Worm detection in network packets
– Spam filtering in email
– Recommended articles in a newspaper
– Recommended books, movies, music, or jokes
– Financial investments
– DNA sequences
– Spoken words
– Handwritten letters
– Astronomical images
24
Task solved using Supervised Learning
25
Regression (Linear/Non-linear)
• Prediction/Curve fitting
– Weather forecasting/prediction
– Predicting market value of a share
– Predicting the price for real estate
26
Features
27
Features Space (2D)
28
Supervised Approach (Details)
29
Hypothesis Space
30
Hypothesis Space
31
Inductive Learning
32
Inductive Learning Hypothesis
33
Bias and Variance
34
Overfitting and Underfitting
35
Representation (Models)
36
Representation (Models)
37
Representation (Models)
38
Problem Solving / Planning / Control
• Performing actions in an environment in order to
achieve a goal.
– Solving calculus problems
– Playing checkers, chess, or backgammon
– Balancing a pole
– Driving a car or a jeep
– Flying a plane, helicopter, or rocket
– Controlling an elevator
– Controlling a character in a video game
– Controlling a mobile robot
39
Related Disciplines
• Artificial Intelligence
• Data Mining
• Probability and Statistics
• Information theory
• Numerical optimization
• Computational complexity theory
• Control theory (adaptive)
• Psychology (developmental, cognitive)
• Neurobiology
• Linguistics
• Philosophy
40
Issues: Designing a Learning System
• Choose the training experience (Database)
• Choose exactly what is to be learned. (Target
function).
• Choose how to represent the target function
(Models).
• Choose a learning algorithm to infer the target
function from the experience.
Learner
Environment/
Experience Knowledge
Performance
Element 41
Evaluation of Learning Systems
• Experimental
– Conduct controlled cross-validation experiments to
compare various methods on a variety of benchmark
datasets.
– Gather data on their performance, e.g. test accuracy,
training-time, testing-time.
– Analyze differences for statistical significance
(ANOVA).
• Theoretical
– Analyze algorithms mathematically and prove theorems
about their:
• Computational complexity
• Ability to fit training data
• Sample complexity (number of training examples needed to
learn an accurate function)
42
Measuring Performance
43
Measuring Performance
44
How to evaluate the Classifier’s
Generalization Performance?
• Accuracy = (TP+TN)/(P+N)
• Error = (FP+FN)/(P+N)
• Precision = TP/(TP+FP)
• Recall/TP rate = TP/P
• FP Rate = FP/N
Predicted class
Pos Neg
Actual Pos TP FN P
class N
Neg FP TN
How to Estimate the Metrics?
• We can use:
– Training data;
– Independent test data;
– Hold-out method;
– k-fold cross-validation method;
– Leave-one-out method;
– Bootstrap method;
– And many more…
Estimation with Training Data
• The hold-out method splits the data into training data and test
data (usually 2/3 for train, 1/3 for test). Then we build a
classifier using the train data and test it using the test data.
Classifier
Data
• The hold-out method is usually used when we have thousands
of instances, including several hundred instances from each
class.
Making the Most of the Data
+
- Final Evaluation
+
Final Test Set Classifier -
56
History of Machine Learning (cont.)
• 1980s:
– Advanced decision tree and rule learning
– Explanation-based Learning (EBL)
– Learning and planning and problem solving
– Utility problem
– Analogy
– Cognitive architectures
– Resurgence of neural networks (connectionism, backpropagation)
– Valiant’s PAC Learning Theory
– Focus on experimental methodology
• 1990s
– Data mining
– Adaptive software agents and web applications
– Text learning
– Reinforcement learning (RL)
– Inductive Logic Programming (ILP)
– Ensembles: Bagging, Boosting, and Stacking
– Bayes Net learning
57
History of Machine Learning (cont.)
• 2000s
– Support vector machines
– Kernel methods
– Graphical models
– Statistical relational learning
– Transfer learning
– Sequence labeling
– Collective classification and structured outputs
– Computer Systems Applications
• Compilers
• Debugging
• Graphics
• Security (intrusion, virus, and worm detection)
– Email management
– Personalized assistants that learn
– Learning in robotics and vision
58
Thank You
59