What Is Machine Learning
What Is Machine Learning
Machine Learning is the science (and art) of programming computers so they can learn from
data.
Here is a slightly more general definition:
Machine Learning is the field of study that gives computers the ability to learn without being
explicitly programmed. —Arthur Samuel, 1959
A computer program is said to learn from experience E with respect to some task T and some
performance measure P, if its performance on T, as measured by P, improves with experience E.
—Tom Mitchell, 1997
For example, your spam filter is a Machine Learning program that can learn to flag spam given
examples of spam emails (e.g., flagged by users) and examples of regular (nonspam, also called
“ham”) emails. The examples that the system uses to learn are called the training set. Each
training example is called a training instance (or sample).
In this case, the task T is to flag spam for new emails, the experience E is the training data, and
the performance measure P needs to be defined; for example, you can use the ratio of correctly
classified emails. This particular performance measure is called accuracy and it is often used in
classification tasks.
1. First you would look at what spam typically looks like. You might notice that some words or
phrases (such as “4U,” “credit card,” “free,” and “amazing”) tend to come up a lot in the subject.
Perhaps you would also notice a few other patterns in the sender’s name, the email’s body, and so
on.
2. You would write a detection algorithm for each of the patterns that you noticed, and your
program would flag emails as spam if a number of these patterns are detected.
3. You would test your program, and repeat steps 1 and 2 until it is good enough.
Since the problem is not trivial, your program will likely become a long list of complex
rules—pretty hard to maintain.
In contrast, a spam filter based on Machine Learning techniques automatically learns which
words and phrases are good predictors of spam by detecting unusually frequent patterns of words
in the spam examples compared to the ham examples. The program is much shorter, easier to
maintain, and most likely more accurate.
Supervised/Unsupervised Learning
Batch and Online Learning
Instance-Based Versus Model-Based Learning
Supervised/Unsupervised Learning
Machine Learning systems can be classified according to the amount and type of supervision
they get during training. There are four major categories: supervised learning, unsupervised
learning, semisupervised learning, and Reinforcement Learning.
Supervised learning: In supervised learning, the training data you feed to the algorithm includes
the desired solutions, called labels.
A typical supervised learning task is classification. The spam filter is a good example of this: it is
trained with many example emails along with their class (spam or ham), and it must learn how to
classify new emails.
For example, say you have a lot of data about your blog’s visitors. You may want to run a
clustering algorithm to try to detect groups of similar visitors. At no point do you tell the
algorithm which group a visitor belongs to: it finds those connections without your help. For
example, it might notice that 40% of your visitors are males who love comic books and generally
read your blog in the evening, while 20% are young sci-fi lovers who visit during the weekends,
and so on. If you use a hierarchical clustering algorithm, it may also subdivide each group into
smaller groups. This may help you target your posts for each group.
Deep belief networks (DBNs) are based on unsupervised components called restricted
Boltzmann machines (RBMs) stacked on top of one another.
Reinforcement Learning
Reinforcement Learning is a very different beast. The learning system, called an agent in this
context, can observe the environment, select and perform actions, and get rewards in return or
penalties in the form of negative rewards.
For example, many robots implement Reinforcement Learning algorithms to learn
how to walk.DeepMind’s AlphaGo program is also a good example of Reinforcement
Learning: it made the headlines in May 2017 when it beat the world champion Ke Jie
at the game of Go. It learned itswinning policy by analyzing millions of games, and
then playing many games against itself.