Professional Documents
Culture Documents
Concepts
SE-805 Advance AI – Lecture
Terminologies
Data
• Traditional
Computer Output
Programming
Program
Data
• Machine Computer
Model
(Program)
Learning
Outputs
(Optional)
Machine
Learning Types
Driverless
cars
Regression Classification
Dimensionality
Continuous Categorical Clustering
Reduction
target variable target variable
Housing price Medial Customer Feature
prediction imaging segmentation selection
1 (cat)
vs
0 (non cat)
Blue
Green
Red
m examples: 𝑥 1 ,𝑦 1 , 𝑥 2 ,𝑦 2 ,…, 𝑥 𝑚 ,𝑦 𝑚
𝑋= 𝑥 1 𝑥 2 𝑥 𝑚 𝑛𝑥 𝑌= 𝑦 1 ,𝑦 2 ,…,𝑦 𝑚
𝑌 ∈ ℝ𝑛𝑦×𝑚
𝑚
𝑋 ∈ ℝ𝑛𝑥 ×𝑚
Khawir Mahmood SE-805 AAI - Machine Learning Concepts 17
Notation
• Sizes:
–𝑚 : number of examples in the dataset
– 𝑛𝑥 : input size (attributes/ features/ dimension)
– 𝑛𝑦 : output size (number of classes)
• Objects:
– 𝑋 ∈ ℝ𝑛𝑥×𝑚 : the input matrix
– 𝑥 (𝑖) ∈ ℝ𝑛𝑥 : the ith example represented as a column vector
– 𝑌 ∈ ℝ𝑛𝑦 ×𝑚 : the label matrix
– 𝑦 (𝑖) ∈ ℝ𝑛𝑦 : the output label of the ith example
– 𝑦ො ∈ ℝ𝑛𝑦 : the predicted output vector
Training set
ML Algorithm
Income,
gender,
age, Credit yes/no
family status, Model (𝒇 )
Credit amount
zipcode
𝑑 𝑥 𝑖 ,𝑥 𝑗
= (𝑥 𝑖 𝑘 −𝑥 𝑗 𝑘 )2
𝑘=1
3-NN
3-NN
ML Algorithm
Income,
gender,
age, Credit yes/no
family status, Model (𝒇 )
Credit amount
zipcode
𝑖=1
• Examples of loss functions
1 𝑖𝑓 𝑠𝑖𝑔𝑛( 𝑦
ො 𝑖 ) ≠ 𝑠𝑖𝑔𝑛(𝑦 𝑖 )
𝑖
ℒ 𝑦ො , 𝑦 𝑖 =ቊ
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
𝑖 𝑖 𝑖 𝑖 2
ℒ 𝑦ො , 𝑦 = 𝑦ො −𝑦
𝑖=1