A pyramid is a structure whose outer surfaces are triangular and converge to a single step at the top, making the shape roughly a pyramid in the geometric sense. The base of a pyramid can be trilateral, quadrilateral, or of any polygon shape. As such, a pyramid has at least three outer triangular surfaces. Wikipedia
पिरामिड जैसे ज्यामितीय आकार से मिलती जुलती संरचनाओं को पिरामिड कहते हैं। विश्व में बहुत सी संरचनाएँ पिरैमिड के आकार की हैं जिनमें मिस्र के पिरामिड बहुत प्रसिद्ध हैं। पिरामिड आकार की संरचनाओं की सबसे बड़ी विशेषता यह है कि इसके भार का अधिकांश भाग जमीन के पास होता है
13. Definitions
Derivative: Rate of change
– Speed is a rate of change of a distance
– Acceleration is a rate of change of speed
Average (Mean)
– Dividing the sum of N values by N
16. Discrete Derivative
)
(
)
(
)
(
lim 0 x
f
x
x
x
f
x
f
dx
df
x
)
(
1
)
1
(
)
(
x
f
x
f
x
f
dx
df
)
(
)
1
(
)
( x
f
x
f
x
f
dx
df
17. Discrete Derivative
Finite Difference
)
(
)
1
(
)
1
( x
f
x
f
x
f
dx
df
)
(
)
1
(
)
( x
f
x
f
x
f
dx
df
)
(
)
1
(
)
( x
f
x
f
x
f
dx
df
Backward difference
Forward difference
Central difference
19. Derivatives in 2 Dimensions
)
,
( y
x
f
Given function
y
x
f
f
y
y
x
f
x
y
x
f
y
x
f )
,
(
)
,
(
)
,
(
Gradient vector
2
2
)
,
( y
x f
f
y
x
f
Gradient magnitude
y
x
f
f
1
tan
Gradient direction
22. Correlation
k l
l
j
k
i
h
l
k
f
h
f ,
,
Kernel
Image
f
f
h1 h2 h3
h4 h5 h6
h7 h8 h9
h
f1 f2 f3
f4 f5 f6
f7 f8 f9
9
9
8
8
7
7
6
6
5
5
4
4
3
3
2
2
1
1
*
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
f
23. Convolution
k l
l
j
k
i
h
l
k
f
h
f ,
,
*
Kernel
Image
h
f h7 h8 h9
h4 h5 h6
h1 h2 h3
h9 h8 h7
h6 h5 h4
h3 h2 h1
h1 h2 h3
h4 h5 h6
h7 h8 h9
h
flip
X
flip
Y
f1 f2 f3
f4 f5 f6
f7 f8 f9
1
9
2
8
3
7
4
6
5
5
6
4
7
3
8
2
9
1
*
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
h
f
f
27. Properties of Gaussian
Most common natural model
Smooth function, it has infinite number of
derivatives
Fourier Transform of Gaussian is Gaussian.
Convolution of a Gaussian with itself is a
Gaussian.
There are cells in eye that perform Gaussian
filtering.
28. Alper Yilmaz, Mubarak Shah, UCF
Filtering
Modify pixels based on some function of the
neighborhood
10 30 10
20 11 20
11 9 1
5.7
p
f
29. Linear Filtering
The output is the linear combination of the
neighborhood pixels
1 3 0
2 10 2
4 1 1
Image
1 0 -1
1 0.1 -1
1 0 -1
Kernel
= 5
Filter Output
Alper Yilmaz, Mubarak Shah, UCF
38. MATLAB Functions
conv: 1-D Convolution.
– C = conv(A, B) convolves vectors A and B.
conv2: Two dimensional convolution.
– C = conv2(A, B) performs the 2-D convolution
of matrices A and B.
39. MATLAB Functions
filter2: Two-dimensional digital filter.
– Y = filter2(B,X) filters the data in X with the 2-D
FIR filter in the matrix B.
– The result, Y, is computed using 2-D correlation and is
the same size as X.
– filter2 uses CONV2 to do most of the work. 2-
D correlation is related to 2-D convolution by a
180 degree rotation of the filter matrix.
40. MATLAB Functions
gradient: Approximate gradient.
– [FX,FY] = gradient(F) returns the numerical
gradient of the matrix F. FX corresponds to dF/dx,
FY corresponds to dF/dy.
mean: Average or mean value.
– For vectors, mean(X) is the mean value
(average) of the elements in X.
41. MATLAB Functions
special: Create predefined 2-D filters
– H = fspecial(TYPE) creates a two-dimensional filter H of the
specified type. Possible values for TYPE are:
– 'average' averaging filter;
– 'gaussian' Gaussian lowpass filter
– 'laplacian' filter approximating the 2-D Laplacian operator
– 'log' Laplacian of Gaussian filter
– 'prewitt' Prewitt horizontal edge-emphasizing filter
– 'sobel' Sobel horizontal edge-emphasizing filter
– Example: H=fspecial('gaussian',7,1) creates a 7x7 Gaussian
filter with variance 1.