ML Module2-Chapter 1
ML Module2-Chapter 1
Introduction to
Machine Learning
NEED FOR MACHINE LEARNING
Mitchell
Deep learning
• Deep learning is a subbranch of machine learning. In deep
learning, the models are constructed using neural network
technology. Neural networks are based on the human neuron
models. Many neurons form a network connected with the
activation functions that trigger further neurons to perform
tasks.
2. Machine Learning, Data Science, Data Mining, and Data
Analytics
• Data science is an ‘Umbrella’ term that encompasses many
fields.
• Data science and machine learning are interlinked.
• Data science deals with gathering of data for analysis.
• It is a broad field that includes:
1. Big Data
2. Data Mining
3. Data Analytics
4. Pattern Recognition
Big Data
• Data science concerns about collection of data. Big data is a
field of data science that deals with data’s following
characteristics:
– Volume: Huge amount of data is generated by big
companies like Facebook, Twitter, YouTube.
– Variety: Data is available in variety of forms like images,
videos, and in different formats.
– Velocity: It refers to the speed at which the data is
generated and processed.
• Big data is used by many machine learning algorithms for
applications such as language translation and image
recognition
Data Mining
• Data mining’s original genesis is in the business.
• Like while mining the earth one gets into precious
resources, it is often believed that unearthing of the
data produces hidden information that otherwise
would have eluded the attention of the management.
• Nowadays, many consider that data mining and
machine learning are same.
• There is no difference between these fields except that
data mining aims to extract the hidden patterns that
are present in the data, whereas, machine learning
aims to use it for prediction.
Data Analytics
• It is an engineering field.
• It uses machine learning algorithms to extract the features for
pattern analysis and pattern classification.
• One can view pattern recognition as a specific application of
machine learning
3. Machine Learning and Statistics
• Statistics is a branch of mathematics.
• Like ML, it can learn from data. But the difference between
statistics and ML is that statistical methods look for regularity in
data called patterns.
• Initially, statistics sets a hypothesis and performs experiments to
verify and validate the hypothesis in order to find relationships
among data.
• It is mathematics intensive and models are often complicated
equations and involve many assumptions.
• It has strong theoretical foundations and interpretations that
require a strong statistical knowledge.
• Machine learning, comparatively, has less assumptions and
requires less statistical knowledge.
TYPES OF MACHINE LEARNING
• There are four types of machine learning as shown in Figure
1.5.
Labeled and Unlabelled Data
• Data is a raw fact.
• The data is represented in the form of a table.
• Data also can be referred to as a data point, sample, or an
example.
• Each row of the table represents a data point.
• Features are attributes or characteristics of an object.
• The columns of the table are attributes. One important
attribute present is called a label.
• Label is the feature that we aim to predict.
• Thus, there are two types of data – labeled and unlabelled.
Labeled Data
• To illustrate labeled data, let us take one example dataset
called Iris flower dataset or Fisher’s Iris dataset.
• The dataset has 50 samples of Iris – with four attributes, length
and width of sepals and petals.
• The target variable is called class. There are three classes – Iris
setosa, Iris virginica, and Iris versicolor.
• A dataset need not be always numbers. It can be images or video
frames.
• Deep neural networks can handle images with labels. In the
following Figure 1.6, the deep neural network takes images of
dogs and cats with labels for classification.
Supervised Learning
• Supervised algorithms use labeled dataset.
• As the name suggests, there is a supervisor or teacher
component in supervised learning.
• A supervisor provides labeled data so that the model is
constructed and generates test data.
• In supervised learning algorithms, learning takes place in two
stages.
• In simple terms, during the first stage, the teacher
communicates the information to the student that the student is
supposed to master. The student receives the information and
understands it.
• During this stage, the teacher has no knowledge of whether the
information is grasped by the student.
• This leads to the second stage of learning. The teacher then
asks the student a set of questions to find out how much
information has been grasped by the student. Based on these
questions, the student is tested, and the teacher informs the
student about his assessment.
• This kind of learning is called supervised learning.
• Supervised learning has two methods:
– Classification
– Regression
Classification (supervised learning)
• Classification is a supervised learning method.
• The input attributes of the classification algorithms are called
independent variables.
• The target attribute is called label or dependent variable.
• The relationship between the input and target variable is
represented in the form of a structure which is called a
classification model.
• The focus of classification is to predict the ‘label’ that is in a
discrete form (a value from the set of finite values).
• In classification, learning takes place in two stages.
• Training stage, the learning algorithm takes a labeled dataset and
starts learning. After the training set, samples are processed and
the model is generated. In the second stage, the constructed
model is tested with test or unknown sample and assigned a label.
This is the classification process.
• This is illustrated in the above Figure 1.7. Initially, the classification
learning algorithm learns with the collection of labeled data and
constructs the model. Then, a test case is selected, and the model
assigns a label.
• Similarly, in the case of Iris dataset, if the test is given as (6.3, 2.9,
5.6, 1.8, ?), the classification will generate the label for this. This is
called classification.
• The classification models can be categorized based on the
implementation technology like decision trees, probabilistic
methods, distance measures, and soft computing methods.
• Classification models can also be classified as generative
models and discriminative models.
• Generative models deal with the process of data generation
and its distribution. Probabilistic models are examples
of generative models.
• Discriminative models do not care about the generation of
data. Instead, they simply concentrate on classifying the given
data.
• Some of the key algorithms of classification are:
– Decision Tree
– Random Forest
– Support Vector Machines
– Naïve Bayes
– Artificial Neural Network and Deep Learning networks like
CNN
Regression Models (supervised learning)
• Regression models predict continuous variables like price (it is
a number). A fitted regression model is shown in Figure 1.8 for
a dataset that represent weeks input x and product sales y.
• The regression model takes input x and generates a model in
the form of a fitted line of the form y = f(x).
• Here, x is the independent variable that may be one or more
attributes and y is the dependent variable.
• In Figure 1.8, linear regression takes the training set and tries
to fit it with a line – product sales = 0.66 * Week + 0.54.
• Here, 0.66 and 0.54 are all regression coefficients that are
learnt from data.
• The advantage of this model is that prediction for product
sales (y) can be made for unknown week data (x).
• For example, the prediction for unknown eighth week can be
made by substituting x as 8 in that regression formula to get y.
• Both regression and classification models are
supervised algorithms.
• The main difference is that regression models predict
continuous variables such as product price, while
classification concentrates on assigning labels such as
class.
Unsupervised Learning
7 Games Game programs for Chess, GO, and Atari video games
8 Natural Google Translate, Text summarization, and sentiment
Language
Translation analysis
9 Identification of access patterns, detection of e-mail spams, viruses,
Web Analysis personalized web services, search engines like
and Services Google, detection of promotion of user websites, and finding loyalty
of users after web page layout modification
10 Medicine Prediction of diseases, given disease symptoms as cancer or
diabetes. Prediction of effectiveness of the treatment using patient
history and Chabot to interact with patients like IBM Watson uses
machine learning technologies.
11 Multimedia Face recognition/identification, biometric projects like identification
and Security of a person from a large image or video
database, and applications involving multimedia retrieval
12 Scientific Discovery of new galaxies, identification of groups of houses based
on house type/geographical location, identification of earthquake
epicenters, and identification of similar land use
Domain