0:11
[Music] hello River and welcome to this NPTEL
course on an introduction to machine learning in
0:22
this course we will have a quick introduction to
machine learning and this will not be very deep in
0:31
a mathematical sense but it will have some amount
of mathematical rigor and what we will be doing
0:36
in this course is covering different paradigms
of machine learning and with special emphasis on
0:43
classification and regression tasks and also will
introduce you to various other machine learning
0:49
paradigms in this introductory lecture set of
lectures I will give a very quick overview of the
0:58
different kinds of machine learning paradigms and
therefore I call this lectures machine learning a
1:04
brief introduction with emphasis on brief right so
the rest of the course would be a more elongated
1:11
introduction to machine learning right so what
is machine learning so I'll start off with a
1:19
canonical definition put out by Tom Mitchell in 97
and so a machine or an agent I deliberately leave
1:30
the beginning undefined because you could also
apply this to non machines like biological agents
1:37
so an agent is said to learn from experience
with respect to some class of tasks right
1:43
and the performance measure P if the learners
performance tasks in the class as measured by
1:52
P improves with experience so what we get from
this first thing is we have to define learning
2:00
with respect to a specific class of tasks right it
could be answering exams in a particular subject
2:07
right or it could be diagnosing patients of a
specific illness right so but we have to be very
2:15
careful about defining the set of tasks on which
we are going to define this learning right and the
2:22
second thing we need is kind of a performance
measure P so in the absence of a performance
2:28
measure P you would start to make vague statement
like oh I think something is happening right that
2:34
seems to be a change and something learnt there
is some learning going on and stuff like that
2:38
so if you want to be more clear about measuring
whether learning is happening or not you first
2:46
need to define some kind of performance criteria
right so for example if you talk about answering
2:52
questions in an exam your performance criterion
could very well be the number of marks that you
2:57
get or if you talk about diagnosing illness then
there then your performance measure would be the
3:05
number of patients that you save or the number of
patients who didn't have adverse reaction to the
3:11
drugs you gave them there could be a variety of
ways of defining performance measures depending
3:16
on what you are looking for right and the third
important component here is experience right so
3:23
with experience the performance has to improve and
so what we mean by experience here in the case of
3:30
writing exams it could be writing more exams right
so the more the number of exams you write the
3:35
better you write it better you get it test taking
or it could be patience in the case of diagnosing
3:42
illnesses like the more patients that you look at
the better you become at diagnosing illness right
3:49
so so these are the three components so you need a
class of tasks you need a performance measure and
3:55
you need some well-defined experience so this kind
of learning rate where you're learning to improve
4:04
your performance based on experience it's known
as this kind of learning where you are trying
4:13
to where you learn to improve your performance
with experience is known as inductive learning
4:17
and and the basis of inductive learning goes back
several centuries people have been debating about
4:26
inductive learning for hundreds of years now and
it's only more recently we have started to have
4:33
more quantified mechanisms of learning right so
but one thing I always point out to people is
4:43
that you should take this definition with a pinch
of salt so for example you could think about the
4:50
task as fitting your foot comfortably right so you
could talk about whether a slipper fits your foot
5:01
comfortably or little so I always say that you
should take this definition with a pinch of salt
5:11
because let's take the example of a slipper you
know so the slipper is supposed to give protection
5:19
to your foot right and a performance measure for
this slipper would be whether it is fitting the
5:25
leg comfortably or not or whether it is you know
as people say there is biting your leg or is it
5:31
Chaffin your feet right and with experience
you know as the slipper knows more and more
5:37
about your foot as you keep wearing the slipper
for longer periods of time it becomes better at
5:41
the task of fitting your footprint as measured by
whether it is shattering your foot or whether it
5:47
is biting your foot or not right so would you say
that the slipper is learned to fit your foot well
5:55
by this definition yes right so we have to take
this with a pinch of salt and so not every system
6:03
that confirms to this definition of learning can
be set to learn usually okay so going on so there
6:13
are different machine learning paradigms that we
will talk about and the first one is supervised
6:19
learning where you learn an input to output map
right so you're given some kind of an input it
6:26
could be a description of the patient who comes
to comes to the clinic and the output that have
6:31
to produce is whether the patient has a certain
disease or not so this they had to learn this
6:36
kind of an input to output map or the input could
be some kind of a question right and then output
6:41
would be the answer to the question or it could be
a true or false question I give you a description
6:45
of the question you have to give me true or
false is the output and in supervised learning
6:49
what you essentially do is learn and mapping from
these inputs to the required output okay if the
6:55
output that you are looking for happens to be a
categorical output like whether he has a disease
7:01
or doesn't have a disease or whether the answer is
true or false then the supervised learning problem
7:05
is called the classification problem right and
if the output happens to be a continuous value
7:11
like so how long will this product last before
it fails right or what is the expected rainfall
7:18
tomorrow right so those kinds of problems they
would be called as regression problems these are
7:24
supervised learning problems where the output
is is a continuous value and these are called
7:30
as regression problems so we look at in more
detailed classification and regression as we
7:34
go on right so the second class of problems
are known as unsupervised learning problems
7:39
right where the goal is not really to produce an
output in response to an input but given a set of
7:45
in data right we have to discover patterns in the
data so that is more of the Tuscola unsupervised
7:52
learning there is no real desired output that we
are looking for right we're more interested in
7:57
finding patterns in the data so clustering is one
task one unsupervised learning task where you're
8:05
interested in finding cohesive groups among
the input pattern rights for example I might
8:11
be looking at customers who come to my shop right
and I want to figure out if there are categories
8:16
of customers like so maybe college students could
be one category and sewing IT professionals could
8:21
be another category and so on so forth and when
I'm looking at this kinds of grouping in my data
8:25
so I would call that a clustering task right
so the other a popular unsupervised learning
8:30
paradigm is known as Association rule mining or
frequent pattern mining where you are interested
8:36
in finding a frequent co-occurrence of items
right in in in the data that is given to you
8:43
so whenever a comes to my shop B also comes to
my shop right so those kinds of co-occurrence so
8:49
I can always say that okay if I see a then that
is likely very likely that B is also in my shop
8:56
somewhere you know so so I can learn these kinds
of associations between data right and again we
9:01
look at this later in more detail and these are I
mean there many different variants on supervised
9:07
and unsupervised learning but these are the
main ones that we look at so the third form
9:12
of learning which is called reinforcement learning
it's neither supervised nor unsupervised in nature
9:17
and typically these are problems where you are
learning to control the behavior of a system and
9:23
I will give you more intuition into reinforcement
learning now in one of the later modules so like I
9:33
said earlier so for every task right so you need
to have some kind of performance measure so if
9:38
you're looking at classification the performance
measure is going to be classification error so
9:43
typically right so we will talk about many many
different performance measures in the duration of
9:49
this course but the typical performance measure
you would want to use is classification error
9:53
right so how many of the items or how many
of the patients did I get incorrect so how
9:59
many of them who are not having the disease did
I predict had the disease and how many of those
10:04
that had the disease that I missed right so that
would be one of the measures that I would use and
10:07
that would be the measure that we want to use but
we will see later that often that's not it's not
10:15
possible to actually learn directly with respect
to this measure so we use other forms right and
10:21
likewise for regression again so we have the
the prediction error suppose I say it's going
10:26
to rain like 23 millimeters and then it ends
up raining like 49 centimeters I don't know
10:34
so that's a huge huge prediction error right and
in terms of clustering so this is little becomes
10:42
a little trickier to define performance measures
we don't know what is a good clustering algorithm
10:49
because we don't know what how to measure the
quality of clusters so people come up with all
10:53
different kinds of measures and so one of the more
popular ones is a scatter or spread of the cluster
10:59
that essentially tells you how how spread out the
points are that belong to a single group if you
11:07
remember we are supposed to find cohesive groups
so if the group is not that cohesive it's not all
11:12
of them are not together then you would say the
clustering is of a poorer quality and if you have
11:18
ways of measuring things like like was telling you
so if you know that people are college students
11:25
right and then you can figure out that how many
what fraction of your cluster or college students
11:31
so you can do these kinds of external evaluations
so one measure that people use popularly there
11:36
is known as purity right and in Association rule
mining we use variety of measures called support
11:41
and confidence it takes a little bit of work to
explain support in confidence so I'll defer it
11:46
until I talk about Association rules in in detail
and in more in the reinforcement learning task so
11:53
if we remember I told you it's learning to control
so you're going to have a cost for controlling the
11:58
system and there so the measure here is cost and
you would like to minimize the cost that you're
12:05
going to accrue while controlling the system so
these are the basic machine learning tasks so
12:09
there are several challenges when you are trying
to build a build a machine learning solution right
12:15
so a few of these I have listed on this slide
right the first one is you have to think about
12:20
how good is a model that he have learned right
so I talked about a few measures on the previous
12:26
slide but often those are not sufficient there
are other practical considerations that come
12:31
into play and we look at some of these towards
the middle of the course somewhere right and the
12:40
bulk of the time would be spent on answering
the second question which is how do I choose
12:45
a model right so given some kind of data which
will be the experience that we are talking about
12:51
so given this experience how would I choose how
would I choose a model right that somehow learns
12:57
what I want to do right so how that improves
itself with experience and so on so how do I
13:01
choose this model and how do I actually find
the parameters of the model that gives me the
13:06
right answer right so this is what we will spend
most of our time on in this course and then there
13:12
are a whole bunch of other things that you really
have to answer to be able to build useful machine
13:19
useful data analytics or data mining solutions
questions like do I have enough data do I have
13:25
enough experience to say that my model is good
right it's the data is is of sufficient quality
13:32
could be errors in the data right suppose I have
medical data and a is recorded as 225 so what does
13:38
that mean it could be 225 days in which case it's
a reasonable number it could be twenty two point
13:44
five years again it's a reasonable number or
twenty two point five months is reasonable but
13:49
it is 225 years it's not a reasonable number so
there's something wrong in the data right so how
13:54
do you handle these things or noise in images
right or missing values so I'll talk briefly
14:00
about handling missing values later in the course
but this is I say mentioned in the beginning is a
14:06
machine learning course right and this is not it's
not primarily it's it's primarily concerned about
14:13
the algorithms of machine learning and the and
the math and the intuition behind those and not
14:18
necessarily about the questions of building
a practical systems based on this so I will
14:23
be talking about many of these issues during the
course but just that I want to reiterate that'll
14:29
not be the focus and so the next challenge
I have listed here is how confident can I be
14:36
of the results and about that I certainly will
talk a little bit because the whole premise of
14:44
reporting machine learning results depends on how
confident you can be of the results right and the
14:51
last question am i describing the data correctly
okay so that's a very very domain dependent and
14:58
and and the question that you can answer only
with your experience as a machine learning or
15:05
a data data scientist professional with time
right so but there are typical questions that
15:12
you would like to ask that are there on the
slides so from the neck in the next module
15:17
we look at the different learning paradigms
in in slightly more detail [Music] [Applause]