Lecture 10 Image
Lecture 10 Image
Modified by:
Assoc. Prof. Dr Hossam Mahmoud Moftah
Faculty of computers and artificial intelligence– Beni-Suef
University
Boundary Descriptors Techniques (lab assignment using python)
There are several simple geometric measures that can be
useful for describing a boundary
Length
the number of pixels along a boundary gives a rough approximation of
its
Diameter (Major Axis)
Minor Axis
the line perpendicular to the major axis
Eccentricity
Ratio of major axis to minor axis
unsupervised learning:
they are unknown
training the classifier: is the process of using data to
determine the best set of features for a classifier
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009
Difference between Classification and Regression in Machine
Learning
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009,
Statistical classification
Parametric Methods:
Consider the case where there are just two classes
class 1 (ω1) and class 2 (ω2), and a single feature, x.
We have a training set, i.e. representative examples
from both classes,
so that we can measure the feature for both classes and
construct probability distributions for each
These are formally known as the probability density
functions or class-conditional probabilities (Appendix
B.3)
p(x|ω1) and p(x|ω2), i.e. the probabilities of measuring
the value x, given that the feature is in class 1 or class
2, respectively.
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009,
Statistical classification
Parametric Methods:
If we have a large number of examples in each class,
then the probability density functions will be Gaussian
in shape (the Central Limit Theorem)
The classification problem is: given another feature
measurement, x, to which class does this feature
belong?
the posterior probability, P(ωi|x), i.e. the probability
that given a feature value of x, the feature belongs to
class ωi.
Probability theory, and specifically Bayes’ Rule, relates
the posterior probabilities to the class-conditional
probabilities or likelihoods (the derivation is given in
Appendix B.3):
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009,
Statistical classification
Parametric Methods:
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009,
Statistical classification
Parametric Methods:
Adapted from Geoff Dougherty, Image Processing for Medical Applications, CAMBRIDGE, 2009,
Statistical classification
Nonparametric
In Non-Parametric methods, there is no need to make
any assumption of parameters for the given population
or the population we are studying.
To classify a new input vector x, examine the k-closest training data points to x and assign the object to the most frequently occurring class
Adapted from David Sontag, New York University and Vibhav Gogate, Carlos Guestrin,
Mehryar Mohri, & Luke Zettlemoyer
k-nearest-neighbor (k-NN) classifier
Adapted from David Sontag, New York University and Vibhav Gogate, Carlos Guestrin,
Mehryar Mohri, & Luke Zettlemoyer
k-nearest-neighbor (k-NN) classifier
P1 7 7 BAD
P2 7 4 BAD
P3 3 4 GOOD
P4 1 4 GOOD
P5 3 7 ?
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
Euclidean Distance From Each Point
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
3 Nearest NeighBour
P1 P2 P3 P4
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
KNN Classification
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
KNN pseudocode
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
Unsupervised methods
Adapted from Anand Bhosale presentation, international institude of information technology,innovation and leadership
Measuring Classification Performance
Adapted https://en.wikipedia.org/wiki/Receiver_operating_characteristic
Confusion Matrix example
Adopted from Poornima Singh, Sanjay Singh, and Gayatri S Pandi-Jain, Effective heart disease prediction system using
data mining techniques, Int J Nanomedicine, 2018
The End