UNIT-1
INTRODUCTION TO MACHINE
LEARNI
NG
Prepared by
Ms.S.Kiruthik
a
Assistant Professor,
Sri Ramakrishna College of
Arts&Science, Coimbatore.
WHAT IS MACHINE LEARNING?
“Machine learning is a subfield of
artificial intelligence, which is broadly
defined as the capability of a machine to
imitate intelligent human behavior”.
BRANCHES OF ML
MACHINE
LEARNING
SUPERVISED
UNSUPERVISED
REINFORCEMENT
DATA
SCIENCE
STATISTICS
PROBABILITY
LINEAR
ALGORITHM
DEEP
LEARNING
MULTI NN
DYNAMIC NN
RECURRENT NN
CONVOLUTIONAL
NN
WHY MACHINE LEARNING?
• Lets take a problem … .
• Write a code to differentiate Orange and Apple.
WHY MACHINE LEARNING?
• How would you write code for identify the black and white image?
WHY MACHINE LEARNING?
What will be the behavior of your Algorithm for other images with
Different shapes?
WHY MACHINE LEARNING?
• SOLUTION:
• CLASSIFIER
• FUNCTION TAKES INPUT, CLASSIFY AND LABELS THE DATA AS
OUTPUT
• Y=F(X)
• X- INPUT/FEATURE
• Y- OUTPUT/ LABELS
MACHINE LEARNING
PROCESS
LANGUAGE FOR MACHINE
LEARNING
TYPES OF MACHINE
LEARNING
TYPES OF MACHINE
LEARNING
SUPERVISED LEARNING
SUPERVISED LEARNING
SUPERVISED LEARNING
REAL TIME EXAMPLE FOR
SUPERVISED LEARNING
UNSUPERVISED LEARNING
UNSUPERVISED LEARNING
REAL TIME EXAMPLE FOR
UNSUPERVISED LEARNING
REAL TIME EXAMPLE FOR
UNSUPERVISED LEARNING
Superv'ised vs. Unsupervised
Learning
up ervised L ear nin
• Goal: A program that performs. a task as good as
humans.
• T'
A
SK — well defined (the target function).
• EXPERIENCE — training data provided by. a human
• PERFORMSNCE - error/accuracy on the.task
' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' " 2
'"'"
REINFORCEMENT LEARNING
REINFORCEMENT LEARNING
REAL TIME EXAMPLE OF
REINFORCEMENT LEARNING
MACHINE LEARNING-
CONCLUSION
CONCLUSION
CONCLUSION
CONCLUSION
APPLICATIONS OF MACHINE
LEARNING?
MACHINE LEARNING FOR
BUSINESS
MACHINE LEARNING
FOR HEALTHCARE
MACHINE LEARNING FOR
BANKING
Credit Card Fraud Detection:
FEW MORE APPLICATIONS
• GOOGLE MAPS
• - Used to predict fastest and shortest route based on the historic data and
current user experience.
• -Users also provide their current locations, speed etc…
FEW MORE APPLICATIONS
• AUTOMATIC FRIEND TAGGING
SUGGESTION IN FACEBOOK
• - It uses face and image recognition to identify faces in all images and
profile pictures
• - The model it uses is Deep face- Deep learning
• - Based on image recognized it automatically suggest the people.
FEW MORE APPLICATIONS
• UBER AND INDIAN RAILWAYS
• - Uber uses Machine Learning Algorithm to suggest customers with
locations to travel and also predict ETA (Estimated time arrival) of cabs.
• - Indian Railway also uses smart ETA prediction algorithm to calculate
delay time of trains based on traffic patterns of trains.
MACHINE LEARNING TOOLS
GPPL
High Level Language
INTERPERTED LANGUAGE
Developers
Libraries
Companies
Areas
Applications
Most popular Languages on
Git Hub
PYTHON IDLE
SPYDER (ANACONDA
DISTRIBUTION)
VS CODE
Why it is Python?
Author: GUIDO VAN ROSSUM
Big fan of “Monty Python’s Flying Circus”
Applications
What is Python?
►Python is an Object Oriented, High-level
programming language with integrated
dynamic semantic primarily for web and
app development.
MACHINE LEARNING TOOLS
MACHINE LEARNING TOOLS
• Predictive Analysis,Machine Learning,
Data mining
□R is a language for statistical
computing and data analysis.
□It is an open source language,
extremely popular in the academic
community – especially among
statisticians and data miners.
□R is considered as a variant of S, a GNU
project which was developed at Bell
Laboratories.
□Currently, it is supported by the R
Foundation for statistical computing.
□R is a very simple programming language with a
huge set of libraries available for different stages
of machine learning.
□Some of the libraries standing out in terms of
popularity are plyr/dplyr (for data
transformation), caret (‘Classification and
Regression Training’ for classification), RJava
(to facilitate integration with Java), tm (for text
mining), ggplot2 (for data visualization).
□Other than the libraries, certain packages like
Shiny and R Markdown have been developed
around R to develop interactive web
applications, documents and dashboards on R
without much effort.
MACHINE LEARNING TOOLS
□MATLAB (matrix laboratory) is a licenced commercial
software with a robust support for a wide range of
numerical computing.
□MATLAB has a huge user base across industry and
academia.
□MATLAB is developed by MathWorks, a company
founded in 1984.
□Being proprietary software, MATLAB is developed much
more professionally, tested rigorously, and has
comprehensive documentation.
□MATLAB also provides extensive support of statistical
functions and has a huge number of machine learning
algorithms in-built.
□ It also has the ability to scale up for large datasets by
parallel processing on clusters and cloud
MACHINE LEARNING TOOLS
□SAS (earlier known as ‘Statistical Analysis System’) is
another licensed commercial software which provides
strong support for machine learning functionalities.
□Developed in C by SAS Institute, SAS had its first release in
the year 1976.
□SAS is a software suite comprising different components.
□The basic data management functionalities are embedded
in the Base SAS component whereas the other components
like SAS/INSIGHT, Enterprise Miner, SAS/STAT, etc. help
in specialized functions related to data mining and
statistical analysis.
MACHINE LEARNING TOOLS
MACHINE LEARNING TOOLS
MACHINE LEARNING TOOLS
MACHINE LEARNING TOOLS
ISSUES IN MACHINE
LEARNING
1. Inadequate Training Data
2. Poor quality of data
3. Non-representative training data
4. Monitoring and maintenance
5. Getting bad recommendations
6. Lack of skilled resources
7. Data Bias
8. Slow implementations and results
SUMMARY
• Machine learning imbibes the philosophy of human learning, i.e.
learning from expert guidance and from experience.
• The basic machine learning process can be divided into three parts.
Data Input: Past data or information is utilized as a basis for future
decision-making.
• Abstraction: The input data is represented in a summarized way
• Generalization: The abstracted representation is generalized to
form a framework for making decisions.
• Before starting to solve any problem using machine learning, it
should be decided whether the problem is a right problem to be
solved using machine learning.
SUMMARY
• Machine learning can be classified into three broad categories:
Supervised learning: Also called predictive learning. The objective
of this learning is to predict class/value of unknown objects based
on prior information of similar objects.
• Examples: predicting whether a tumour is malignant or benign,
price prediction in domains such as real estate, stocks, etc.
• Unsupervised learning: Also called descriptive learning, helps in
finding groups or patterns in unknown objects by grouping similar
objects together. Examples: customer segmentation, recommender
systems, etc.
• Reinforcement learning: A machine learns to act on its own to
achieve the given goals. Examples: self-driving cars, intelligent
robots, etc.
SUMMARY
• Machine learning has been adopted by various industry domains
such as Banking and Financial Services, Insurance, Healthcare, Life
Sciences, etc. to solve problems.
• Some of the most adopted platforms to implement machine
learning include Python, R, MATLAB, SAS, SPPSS, etc.
• To avoid ethical issues, the critical consideration is required before
applying machine learning and using any outcome from machine
learning
POSSIBLE QUESTIONS
SHORT-ANSWER TYPE QUESTIONS (5 MARKS EACH):
• What is human learning? Give any two examples.
• What are the types of human learning? Are there equivalent forms of machine learning?
• What is machine learning? What are key tasks of machine learning?
• Explain the concept of penalty and reward in reinforcement learning.
• What are concepts of learning as search?
• What are different objectives of machine learning? How are these related with human learning?
• Define machine learning and explain the different elements with a real example.
• Explain the process of abstraction with an example.
• What is generalization? What role does it play in the process of machine learning?
• What is classification? Explain the key differences between classification and regression.
• What is regression? Give example of some practical problems solved using regression.
• Explain the process of clustering in details.
• Write short notes on any two of the following:
– Application of machine learning algorithms
– Supervised learning
– Unsupervised learning
– Reinforcement learning
POSSIBLE QUESTIONS
LONG-ANSWER TYPE QUESTIONS (10 MARKS QUESTIONS):
• What is machine learning? Explain any two business applications of machine learning. What are the possible ethical issues of
machine learning applications?
• Explain how human learning happens:
– Under direct guidance of experts
– Under indirect guidance of experts
– Self-learning
• Explain the different forms of machine learning with a few examples.
• Compare the different types of machine learning.
• What do you mean by a well-posed learning problem? Explain important features that are required to well-define a learning
problem.
• Can all problems be solved using machine learning? Explain your response in detail.
• What are different tools and technologies available for solving problems in machine learning? Give details about any two of
them.
• What are the different types of supervised learning? Explain them with a sample application in each area.
• What are the different types of unsupervised learning? Explain them difference with a sample application in each area.
• Explain, in details, the process of machine learning.
– Write short notes on any two:
• MATLAB
• Application of machine learning in Healthcare
• Market basket analysis
• Simple linear regression
– Write the difference between (any two):
• Abstraction and generalization
• Supervised and unsupervised learning
• Classification and regression

Introduction to Machine Learning_ UNIT 1

  • 1.
    UNIT-1 INTRODUCTION TO MACHINE LEARNI NG Preparedby Ms.S.Kiruthik a Assistant Professor, Sri Ramakrishna College of Arts&Science, Coimbatore.
  • 2.
    WHAT IS MACHINELEARNING? “Machine learning is a subfield of artificial intelligence, which is broadly defined as the capability of a machine to imitate intelligent human behavior”.
  • 3.
  • 4.
    WHY MACHINE LEARNING? •Lets take a problem … . • Write a code to differentiate Orange and Apple.
  • 5.
    WHY MACHINE LEARNING? •How would you write code for identify the black and white image?
  • 6.
    WHY MACHINE LEARNING? Whatwill be the behavior of your Algorithm for other images with Different shapes?
  • 7.
    WHY MACHINE LEARNING? •SOLUTION: • CLASSIFIER • FUNCTION TAKES INPUT, CLASSIFY AND LABELS THE DATA AS OUTPUT • Y=F(X) • X- INPUT/FEATURE • Y- OUTPUT/ LABELS
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
    REAL TIME EXAMPLEFOR SUPERVISED LEARNING
  • 16.
  • 17.
  • 18.
    REAL TIME EXAMPLEFOR UNSUPERVISED LEARNING
  • 19.
    REAL TIME EXAMPLEFOR UNSUPERVISED LEARNING
  • 20.
    Superv'ised vs. Unsupervised Learning upervised L ear nin • Goal: A program that performs. a task as good as humans. • T' A SK — well defined (the target function). • EXPERIENCE — training data provided by. a human • PERFORMSNCE - error/accuracy on the.task ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' ' " 2 '"'"
  • 21.
  • 22.
  • 23.
    REAL TIME EXAMPLEOF REINFORCEMENT LEARNING
  • 24.
  • 25.
  • 26.
  • 27.
  • 28.
  • 29.
  • 30.
  • 33.
  • 34.
    FEW MORE APPLICATIONS •GOOGLE MAPS • - Used to predict fastest and shortest route based on the historic data and current user experience. • -Users also provide their current locations, speed etc…
  • 35.
    FEW MORE APPLICATIONS •AUTOMATIC FRIEND TAGGING SUGGESTION IN FACEBOOK • - It uses face and image recognition to identify faces in all images and profile pictures • - The model it uses is Deep face- Deep learning • - Based on image recognized it automatically suggest the people.
  • 36.
    FEW MORE APPLICATIONS •UBER AND INDIAN RAILWAYS • - Uber uses Machine Learning Algorithm to suggest customers with locations to travel and also predict ETA (Estimated time arrival) of cabs. • - Indian Railway also uses smart ETA prediction algorithm to calculate delay time of trains based on traffic patterns of trains.
  • 37.
  • 38.
  • 39.
  • 40.
  • 41.
  • 42.
  • 43.
  • 44.
  • 45.
  • 46.
  • 48.
  • 49.
  • 51.
  • 52.
    Why it isPython? Author: GUIDO VAN ROSSUM Big fan of “Monty Python’s Flying Circus”
  • 53.
  • 54.
    What is Python? ►Pythonis an Object Oriented, High-level programming language with integrated dynamic semantic primarily for web and app development.
  • 55.
  • 56.
    MACHINE LEARNING TOOLS •Predictive Analysis,Machine Learning, Data mining
  • 57.
    □R is alanguage for statistical computing and data analysis. □It is an open source language, extremely popular in the academic community – especially among statisticians and data miners. □R is considered as a variant of S, a GNU project which was developed at Bell Laboratories. □Currently, it is supported by the R Foundation for statistical computing.
  • 59.
    □R is avery simple programming language with a huge set of libraries available for different stages of machine learning. □Some of the libraries standing out in terms of popularity are plyr/dplyr (for data transformation), caret (‘Classification and Regression Training’ for classification), RJava (to facilitate integration with Java), tm (for text mining), ggplot2 (for data visualization). □Other than the libraries, certain packages like Shiny and R Markdown have been developed around R to develop interactive web applications, documents and dashboards on R without much effort.
  • 60.
  • 61.
    □MATLAB (matrix laboratory)is a licenced commercial software with a robust support for a wide range of numerical computing. □MATLAB has a huge user base across industry and academia. □MATLAB is developed by MathWorks, a company founded in 1984. □Being proprietary software, MATLAB is developed much more professionally, tested rigorously, and has comprehensive documentation. □MATLAB also provides extensive support of statistical functions and has a huge number of machine learning algorithms in-built. □ It also has the ability to scale up for large datasets by parallel processing on clusters and cloud
  • 62.
  • 63.
    □SAS (earlier knownas ‘Statistical Analysis System’) is another licensed commercial software which provides strong support for machine learning functionalities. □Developed in C by SAS Institute, SAS had its first release in the year 1976. □SAS is a software suite comprising different components. □The basic data management functionalities are embedded in the Base SAS component whereas the other components like SAS/INSIGHT, Enterprise Miner, SAS/STAT, etc. help in specialized functions related to data mining and statistical analysis.
  • 64.
  • 65.
  • 66.
  • 67.
  • 68.
    ISSUES IN MACHINE LEARNING 1.Inadequate Training Data 2. Poor quality of data 3. Non-representative training data 4. Monitoring and maintenance 5. Getting bad recommendations 6. Lack of skilled resources 7. Data Bias 8. Slow implementations and results
  • 70.
    SUMMARY • Machine learningimbibes the philosophy of human learning, i.e. learning from expert guidance and from experience. • The basic machine learning process can be divided into three parts. Data Input: Past data or information is utilized as a basis for future decision-making. • Abstraction: The input data is represented in a summarized way • Generalization: The abstracted representation is generalized to form a framework for making decisions. • Before starting to solve any problem using machine learning, it should be decided whether the problem is a right problem to be solved using machine learning.
  • 71.
    SUMMARY • Machine learningcan be classified into three broad categories: Supervised learning: Also called predictive learning. The objective of this learning is to predict class/value of unknown objects based on prior information of similar objects. • Examples: predicting whether a tumour is malignant or benign, price prediction in domains such as real estate, stocks, etc. • Unsupervised learning: Also called descriptive learning, helps in finding groups or patterns in unknown objects by grouping similar objects together. Examples: customer segmentation, recommender systems, etc. • Reinforcement learning: A machine learns to act on its own to achieve the given goals. Examples: self-driving cars, intelligent robots, etc.
  • 72.
    SUMMARY • Machine learninghas been adopted by various industry domains such as Banking and Financial Services, Insurance, Healthcare, Life Sciences, etc. to solve problems. • Some of the most adopted platforms to implement machine learning include Python, R, MATLAB, SAS, SPPSS, etc. • To avoid ethical issues, the critical consideration is required before applying machine learning and using any outcome from machine learning
  • 73.
    POSSIBLE QUESTIONS SHORT-ANSWER TYPEQUESTIONS (5 MARKS EACH): • What is human learning? Give any two examples. • What are the types of human learning? Are there equivalent forms of machine learning? • What is machine learning? What are key tasks of machine learning? • Explain the concept of penalty and reward in reinforcement learning. • What are concepts of learning as search? • What are different objectives of machine learning? How are these related with human learning? • Define machine learning and explain the different elements with a real example. • Explain the process of abstraction with an example. • What is generalization? What role does it play in the process of machine learning? • What is classification? Explain the key differences between classification and regression. • What is regression? Give example of some practical problems solved using regression. • Explain the process of clustering in details. • Write short notes on any two of the following: – Application of machine learning algorithms – Supervised learning – Unsupervised learning – Reinforcement learning
  • 74.
    POSSIBLE QUESTIONS LONG-ANSWER TYPEQUESTIONS (10 MARKS QUESTIONS): • What is machine learning? Explain any two business applications of machine learning. What are the possible ethical issues of machine learning applications? • Explain how human learning happens: – Under direct guidance of experts – Under indirect guidance of experts – Self-learning • Explain the different forms of machine learning with a few examples. • Compare the different types of machine learning. • What do you mean by a well-posed learning problem? Explain important features that are required to well-define a learning problem. • Can all problems be solved using machine learning? Explain your response in detail. • What are different tools and technologies available for solving problems in machine learning? Give details about any two of them. • What are the different types of supervised learning? Explain them with a sample application in each area. • What are the different types of unsupervised learning? Explain them difference with a sample application in each area. • Explain, in details, the process of machine learning. – Write short notes on any two: • MATLAB • Application of machine learning in Healthcare • Market basket analysis • Simple linear regression – Write the difference between (any two): • Abstraction and generalization • Supervised and unsupervised learning • Classification and regression