Introduction to Machine
Learning
Rift Valley University, Shashamane Campus
Department of Computer Science
Nov, 2024
Outline
What is Machine Learning (ML)?
Examples of ML applications
Related to the course
Major classes of ML Algorithms
ML Vs AI
Questions about ML
11/2/2024 2
What is Machine Learning ?
Machine Learning: is a 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 class of task T and performance measure P, if
its performance at task in T, as measured by P, improves with
experience E. (Tom Mitchell – 1998)
11/2/2024 3
What is Machine Learning ?
What is ML: building computational artifacts that learn over
time based on experience.
It includes:
The mathematics behind it
The science behind it (systematic and logical approach,
knowledge base on demonstrable)
The engineering behind it (the application of mathematics and
science)
The computing behind it (using computer technology)
11/2/2024 4
Examples of ML Application
Some examples of tasks best solved by learning algorithms.
Recognizing patterns:
Object in real scenes
Facial identities or facial expressions
Spoken words
Recognizing anomalies:
Unusual sequences of credit card transactions
Unusual patterns of sensor readings in a nuclear power plant
Prediction:
Future stock price or currency exchange rates
Which movies will a person like?
11/2/2024 5
Examples of ML Application
Some application of ML in Google:
Page ranking (RankBrain)
Spam identification in email
Speech recognition (language recognition)
Software in Cars (Autonomous and self driving cars)
Recommender system
Google voice search
Gmail inbox’s smart replay
Google photos
Google Cloud Vision API
Virtual reality etc…
11/2/2024 6
ML related to this Course
The course can be:
More of theoretical :
More of practical:
Balancing the theory and the application
11/2/2024 7
ML related to this Course
Some prerequisite :
Programming (python, matlab, R etc…)
Probability and Statistics;
Mathematics (Linear Algebra, Matrix, Vector, differential
calculus, and integral calculus)
Curiosity of working with data etc…
ML – it is all about learning from examples (data).
We take features and produced labels.
11/2/2024 8
Learning Path
Generally, the learning path includes:
Math skills
Programming skills
Data Engineering skills
Machine learning algorithms
Machine learning frameworks
11/2/2024 9
Learning Path
Generally, the learning path includes: Math skills
11/2/2024 10
Learning Path
Generally, the learning path includes: Programming skills
11/2/2024 11
Learning Path
Generally, the learning path includes: Data Engineering skills
11/2/2024 12
Learning Path
Generally, the learning path includes: ML algorithms
11/2/2024 13
Learning Path
Generally, the learning path includes: ML Framework
11/2/2024 14
Major Classes of ML
Algorithms
11/2/2024 15
Supervised Learning
11/2/2024 16
Supervised Learning
Supervised learning: (function approximation) [labels data
well]
Input 1 2 3 4 5 6 9
Output 1 4 9 16 25 36 ?
output <- input2
Learn to predict an output when given an input vector.
E.g.: Features: age, gander, smoking, drinking etc…
Labels : having the disease , does not have the disease
11/2/2024 17
Supervised Learning
Supervised Learning:
Regression Problem: numerical / continuous value.
Given some data, you assume that those values come from some
sort of function and try to find out what the function is.
It is a problem of function approximation or interpolation.
Classification Problem: nominal / discrete value.
Grouping the data into predetermined classes.
11/2/2024 18
Supervised Learning
Supervised learning: making predictions using data.
Example : is a given email “spam” or “ham”.
There is an outcome; we are trying to predict.
Classification
11/2/2024 19
Unsupervised Learning
Unsupervised learning :
Unsupervised (concise description) [cluster scores well]
The aim of unsupervised learning is to find clusters of
similar inputs in the data without being explicitly told that some
data points belong to one class and the other in other classes.
The algorithm has to discover this similarity by itself.
Discover a good internal representation of the input.
11/2/2024 20
Unsupervised Learning
11/2/2024 21
Unsupervised Learning
Unsupervised learning: extracting structure from data.
Example: segment grocery store shopper into clusters that exhibit
similar behaviors.
There is no “right answer”
Clustering
11/2/2024 22
Reinforcement Learning
Reinforcement learning :
Reinforcement (stimulus/state, action, reward) [behavior scores
well] – reward maximization.
The algorithm searches over the state space of possible inputs and
outputs in order to maximize a reward.
Learn to select an action to maximize payoff.
11/2/2024 23
Machine Learning Vs AI
Machine learning : is more of induction (from specific to
generalization)
Abebe is mortal, Almaz is mortal
Kebede is mortal,
Then, all humans are mortal
Artificial Intelligence: more of deduction (from general to
specific – reasoning )
A implies B
Having “A”, you can infer “B”
11/2/2024 24
Machine Learning Vs AI
Machine learning can be:
Unsupervised (description) -> summaries -> Supervised (function
approximation) -> Labels
Data is the key in ML:
The difference b/n solving a problem as AI or ML person is:
As a AI person: the algorithm is central
As a ML person: the data is central (get the priority)
11/2/2024 25
Machine Learning Application
Machine learning can be applied:
What are the serious of steps I need to do in order to solve some
problem?
If I tried to describe this problem in a particular way, is it
solvable?
11/2/2024 26
Machine Learning
What is Machine Learning?
Machine learning is the semi-automated extraction of knowledge
from data?
Knowledge from data: Starts with a question that might be
answerable using data.
Automated extraction: A computer provides the insight.
Semi-automated: Requires many smart decisions by a human.
11/2/2024 27
Machine Learning
How does ML “work”?
High-level steps of supervised learning:
First, train a machine learning model using labeled data.
“Labeled data” has been labeled with the outcome.
“ML model” learns the relationship b/n the attributes of the data and
its outcome.
Then, make predictions on new data for which the label is
unknown.
Example: segment grocery store shopper into clusters that exhibit
similar behaviors.
11/2/2024 28
Machine Learning
Questions about ML?
How do I choose which attributes of my data to include in the
model?
How do I choose which model to use?
How do I optimize the model for best performance?
How do I ensure that I’m building a model that will generalize to
unseen data?
Can I estimate how well my model is likely to perform on unseen
data?
11/2/2024 29