(2024-25 EVEN)
UTA027
Artificial Intelligence
Machine Learning
(Introduction)
Thapar Institute of Engineering and Technology
(Deemed to be University)
Machine Learning
Introduction
Raghav B. Venkataramaiyer
Thapar Institute of Engineering and Technology
(Deemed to be University)
Ref
Artificial Intelligence: Structures and Strategies for Complex Problem Solving
By: Luger & Stubblefield
PRML
Notations
Concepts
Set Notation:�{a,b,c,…} (e.g. set of vertices)�{a,b} ≡ {b,a}�{a∈ℕ : a even.}
Vectors:�Row Vectors: (w1,…,wM) OR [w1,…,wM]�Column Vectors: w = [w1,…,wM]T�Closed/Open Intervals: [a,b],(a,b),[a,b)
Matrices: M (uppercase bold letters)�M×M Identity (Unit) Matrix: IM� IM ⊢ Iij = 1 if i=j; Iij = 0 if i≠j
Probability:�Expectation: 𝔼[X], Variance: Var(X)�Conditionals: 𝔼x[f(x)|z], Varx(f(x)|z)
Set Partition:
Given set S≡{a,b,c,…}
Partitions of S:�S1,S2,S3,…⊆S, ⋃iSi=S ⊢�∀i,j i≠j → Si∩Sj=∅�(pairwise disjoint subsets that span the space)
PS:
World of discourse
Pattern Recognition
What is this?
Pattern Recognition
What is this?
Supervision
Settings (or Context)
Curve Fitting
TreadWill.Org
Curve Fitting
Partition
See also:
52 partitions of a set with 5 elements.
Image Courtesy: �Wikipedia
Formulation
Example: MNIST Classification
Formulation�MNIST Classification
Inputs
m rows
n columns
Formulation�MNIST Classification
Inputs
m rows
n columns
Formulation�MNIST Classification
Inputs
m rows
n columns
Formulation�MNIST Classification
Inputs
m rows
n columns
Formulation�MNIST Classification
Inputs
Bound and Continuous:
H × W
Formulation�MNIST Classification
Outputs
0
1
2
3
4
5
6
7
8
9
Input
X∈ℝm×n
y=6
Formulation�MNIST Classification
Outputs
0
1
2
3
4
5
6
7
8
9
Input
X∈ℝm×n
y=6
0
1
2
3
4
5
6
7
8
9
y=5
X∈ℝm×n
Formulation�MNIST Classification
Outputs
0
0
0
0
0
0
1
0
0
0
0
1
2
3
4
5
6
7
8
9
y=6
Input
X∈ℝm×n
0
1
2
3
4
5
6
7
8
9
y=5
X∈ℝm×n
Formulation�MNIST Classification
Outputs
0
0
0
0
0
0
1
0
0
0
0
1
2
3
4
5
6
7
8
9
y=6
Input
X∈ℝm×n
0
0
0
0
0
1
0
0
0
0
0
1
2
3
4
5
6
7
8
9
y=5
X∈ℝm×n
Formulation�MNIST Classification
Outputs
0
0
0
0
0
0
1
0
0
0
0
1
2
3
4
5
6
7
8
9
y=6
0
0
0
0
0
1
0
0
0
0
0
1
2
3
4
5
6
7
8
9
y=5
Input
X∈ℝm×n
X∈ℝm×n
Formulation�MNIST Classification
Outputs
0
0
0
0
0
0
1
0
0
0
0
1
2
3
4
5
6
7
8
9
y=6
0
0
0
0
0
1
0
0
0
0
0
1
2
3
4
5
6
7
8
9
y=5
Input
X∈ℝm×n
X∈ℝm×n
Formulation�MNIST Classification
Outputs
=0 everywhere except x=0
The value at zero satisfies:
Area under the curve is 1.
x discrete
Formulation�MNIST Classification
Dirac-delta Indicator Equivalence
Formulation�MNIST Classification
Model (x∈ℝm×n, y∈ℤ)
Formulation�MNIST Classification
Model (x∈ℝm×n, y∈ℤ)
Formulation�MNIST Classification
Model (x∈ℝm×n, y∈ℤ)
Formulation�MNIST Classification
Model (x∈ℝm×n, y∈ℤ)
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
(aka. evidence)
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
Sample x (from data)
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
Sample x and y (from data)
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
Conditional distribution of y given x.
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
Using the model, estimate y given x.
Formulation�MNIST Classification
Model
x∈ℝm×n
y∈ℤ
Data
Optimal case.
Formulation�MNIST Classification
Model
0
0
0
0
0
0
1
0
0
0
0
1
2
3
4
5
6
7
8
9
y=6
x∈ℝm×n
Formulation�MNIST Classification
Model
0
0
0
0
0
0
1
0
0
0
x∈ℝm×n
0
1
2
3
4
5
6
7
8
9
as per evidence
Formulation�MNIST Classification
Model
0
0
0
0
0
0
1
0
0
0
x∈ℝm×n
0
1
2
3
4
5
6
7
8
9
as per evidence
as per estimate
Formulation�MNIST Classification
Model
0
0
0
0
0
0
1
0
0
0
x∈ℝm×n
0
1
2
3
4
5
6
7
8
9
as per evidence
Optimally.
Formulation�MNIST Classification
Model
0
0
0
0
0
0
1
0
0
0
x∈ℝm×n
0
1
2
3
4
5
6
7
8
9
as per evidence
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then the difference between them may be expected to be miniscule
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then the DISTANCE between them may be EXPECTED to be MINIMUM
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then the DISTANCE between them may be EXPECTED to be MINIMUM
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then the EXPECTED VALUE of the DISTANCE between them shall be MINIMUM
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then MINIMISE the EXPECTED VALUE of the DISTANCE between them.
Formulation�MNIST Classification
Objective
x∈ℝm×n
If the two values are approximately the same,
Then the optimal params shall MINIMISE the EXPECTED VALUE of the DISTANCE between them.
Thank you!