Introduction to AI and ML – Day 1
Gururajan Narasimhan Erode
Day 1 - Agenda
• Introduction to Artificial Intelligence – AI
• Human actions corresponding AI actions - What constitutes AI
• Strong AI and weak AI – Introduction and examples
• Introduction to Machine Learning and the idea of Learning
• Overview of Neural Networks and its role in AI
• Complete Machine Learning cycle
• Supervised and Unsupervised learning
• Semi-supervised learning and Reinforcement learning
What is AI – Section 1
Artificial Intelligence
Humans Computers
1) We see 1) Computer Vision
2) We speak and we listen to other people 2) Speech recognition / voice
speak
recognition
3) We read from a given text, understand and
write text 3) Natural Language Processing (NLP)
4) We smell 4) Nothing still, may be possible
5) We touch, move and run 5) Kinematics and robotics
6) We think, reason, make decisions in real 6) General AI – just starting
time based on current inputs and
experience, learn, extract useful 7) Nothing still, is it really possible?
information from data, perform cognitive
functions such as problem solving,
7) We feel
Artificial Intelligence – General Intelligence – Strong AI – Broad
AI
• Machines that mimic the cognitive functions that humans associate with
other human minds, such as “complete learning” and “problem solving”.
• This is Strong AI or Full AI
• General AI or Full AI is the complete cognitive abilities and decision
making sensory range of properties that human’s have.
• Nobody in the world has successfully make products in General AI, the
likes of – think Arnold Schwarzenegger in terminator or Chitti in Robot 1
Artificial Intelligence - Examples of Applied AI – Weak AI –
Narrow AI
• Domain specific chat bots like the Wipro's helpline or in
general any immigration help system
• Amazon’s recommendation Engine
• deep blue the first computer based chess playing champion
• The Advanced Driver Assistance Systems (ADAS)
Artificial Intelligence - Examples of Applied AI – Weak AI –
Narrow AI
• Amazon’s “echo dot” and “echo plus” voice recognition
systems
• NEST home connectivity startup acquired by google in 2014
• Pandora Internet Radio is a music streaming service and
automated music recommendation service powered by
the Music Genome Project
• Deep mind of google is now in Applied AI, but they want to
keep their mind on General AI as well
https://deepmind.com/about/
Artificial Neural Networks and Deep Learning
• An artificial neuron network (ANN) is a computational model based on the
structure and functions of biological neural networks. Information that
flows through the network affects the structure of the ANN because a
neural network changes - or learns, in a sense - based on that input and
output.
• ANNs are considered nonlinear statistical data modeling tools where the
complex relationships between inputs and outputs are modeled or
patterns are found. ANN is also known as a neural network.
• Deep learning is the technology that uses neural networks where there
are more than two hidden layers
Quick Quiz
• Auto Car Parking assist system is an example for
• Broad AI touches upon
• What are the domains that come under Artificial Intelligence
Introduction to Machine
Learining – Section 2
What is Machine Learning – Tom Mitchell
• The field of machine learning is concerned with the question of how to
construct computer programs that automatically improve with or LEARN from
experience
• Tom M. Mitchell provided a widely quoted and more formal definition of the
algorithms studied in the machine learning field: "A computer program is
said to learn from experience E with respect to some class of tasks T
and performance measure P if its performance at tasks in T, as
measured by P, improves with experience E. … “
• The key word here is Learning
• What do mean by saying “ I am Learning”
• The ability to understand and improve my work based on previous experience
https://ion.icaew.com/itcounts/b/weblog/posts/theaccountinganddatascienceworldsmeet
y = f(x)
Learning (Training)
output prediction Image
function feature
Features: Features: Features:
1. Color: 1. Sky Blue 1. Yellow
Radish/Red 2. Logo: 2. Fruit
2. Type : Fruit 3. Texture : 3. Texture :
3. Texture : Soft 4.Shape Soft
4. Shape etc… 4.Shape
etc… What do you mean by Apple? etc…
The machine learning framework
• Apply a prediction function to a feature representation of the image to get the
desired output:
f( ) = “ apple”
f( ) = “ tomato”
f( ) = “ cow”
Training: given a training set of labeled examples {(x1,y1), …, (xN,yN)}, estimate
the prediction function f by minimizing the prediction error on the training set
Testing: apply f to a never before seen test example x and output the predicted
value y = f(x)
Slide credit: L. Lazebnik
What is what in ML
• In machine learning the pictures or words or actual numbers are the –
DATA – this is ‘x’ the input variable
• The names you gave for those pictures – LABELS or OUTPUT -- labeled
output
• Program writing in Python, R or C++ -- LEARNING ALGORITHM -- this
is the program you write in python
• The equations which you have built – the model of an apple you have in
mind - MODEL – The model is also the function “ f “
• Then when a real apple is then shown to you, then you say it is an apple,
this is the PREDICTED OUTPUT – ‘ y’
Machine Learning - Terminology
• Features
• The number of features or distinct traits that can be used to describe each item in a quantitative manner
• Samples
• A sample is an item to process (e.g. classify). It can be a document, a picture, a sound, a video, a row in
database or CSV file, or whatever you can describe with a fixed set of quantitative traits.
• Feature vector
• is an n-dimensional vector of numerical features that represent some object.
• Feature extraction
• Preparation of feature vector
• transforms the data in the high-dimensional space to a space of fewer dimensions.
• Training/Evolution set
• Set of data to discover potentially predictive relationships.
Machine Learning – How it is done?
Training
Training Labels
Training Images
Image Learned
Training
Features model
Testing
Image Learned
Prediction
Features model
Test Image Slide credit: D. Hoiem and L. Lazebnik
Quick Quiz
• In the context of machine learning the word learning means ……
• In machine learning data is divided in to ----- set, ---- set and ---- set.
• In ML, what do features mean?
Different Kinds of
Learning – Section 3
http://sungsoo.github.io/2017/03/28/three-things-you-need-to-know-about-machine-
learning.html
Supervised Learning
• Supervised learning is the machine learning task of inferring a function
from labeled training data. The training data consist of a set of training
examples.
• In supervised learning, each example is a pair consisting of an input
object (typically a vector) and a desired output value (also called the
supervisory signal)
Unsupervised Learning
• Unsupervised learning is a type of machine learning algorithm used to
draw inferences from datasets consisting of input data without labeled
responses.
• The most common unsupervised learning method is cluster analysis,
which is used for exploratory data analysis to find hidden patterns or
grouping in data.
Semi-Supervised Learning
• Semi-supervised learning is a class of supervised learning tasks and
techniques that also make use of unlabeled data for training – typically a
small amount of labeled data with a large amount of unlabeled data
Reinforcement Learning
• Reinforcement learning, in the context of artificial intelligence, is a type of
dynamic programming that trains algorithms using a system of reward
and punishment.
• A reinforcement learning algorithm, or agent, learns by interacting with its
environment. The agent receives rewards by performing correctly and
penalties for performing incorrectly. The agent learns without intervention
from a human by maximizing its reward and minimizing its penalty.
Quick Quiz
• Four important kinds of learning are
• Semi-supervised learning is used in …..
• Reinforcement learning is learning from
Different Kinds of
Learning – Section 3
References
• https://www.bistasolutions.com/resources/blogs/5-statistical-methods-for-for
ecasting-quantitative-time-series
/
• Machinelearningmastery.com