联系方式

  • QQ:99515681
  • 邮箱:99515681@qq.com
  • 工作时间:8:00-21:00
  • 微信:codinghelp

您当前位置:首页 >> Python编程Python编程

日期:2019-02-26 09:23

CS 659 Image Processing

Exam One

Name: Student ID #:

Covering Lectures 1~6. There are 4 questions. Each is 25 points.

1. (a) (10 points) Determine the convolution and correlation of the two sequences shown below.

Note that, black dots represent value 1 and white dots represent value 0. Underline the pixel at

the origin. Note that the answers are 4 by 4 matrices.


(b) (15 points) Perform the convolution

f g

and the correlation

f g

. Assume the origin is

located at the lower-left corner. Underline the pixel at the origin. Note that the answers are 3 by 4

matrices.

3 5 1 2 1

: , :

6 2 1 3

2. (a) (10 points) Apply contrast stretching to the image below using

2, 1, 5, 7. r1 = s1 = r2 = s2 =

Show your computation and the output image. Note that using rounding to be all integers.

1 1 0 0 0 0 0 1

1 1 1 1 0 1 0 1

1 3 4 4 5 5 0 0

0 3 4 4 5 5 5 5

2 4 4 4 4 5 7 0

1 1 4 5 6 5 6 1

1 0 4 4 1 5 6 1

1 0 1 1 1 0 5 0

(b) (15 points)

Let the input pixels {y(m)}={2, 3, 8, 4, 2} and the window W = [-1, 0, 1]. What is the median

filter output {v(m)}? Let W contain an even number of pixels, say W = [-1, 0, 1, 2]. What is the

median filter output {v(m)}? Note that let the boundary pixels stay the same (i.e., without the

median computation). Note that using floating-point numbers (i.e., DO NOT round into

integers).

3. (10 points) (a) Given a template f, find the location of exact match in the image g by using

Correlation of fg minus Correlation of f'g. Show your calculations and mark the matched

locations.

(b) (15 points) Is it possible to perform the matching by using only one correlation (f and g are

shown below)? If the answer is Yes, show the modified template and your calculations, and

mark the matched locations. If the answer is No, describe your opinion why it cannot work.

f:

0 1 0

1 0 1

0 1 0

g:

0 0 0 0 0 0 0 0

0 0 1 0 1 0 0 0

0 1 0 1 1 1 1 0

0 0 1 0 1 0 0 0

0 0 0 0 1 1 1 0

0 1 1 0 0 0 1 0

0 1 1 0 0 0 1 0

0 0 0 0 0 0 0 0

4. (25 points) Apply histogram equalization to the image below. Let the output gray levels are in

the range of [0, 7]. Show your step-by-step calculations, the input/output pixel mapping, and

the resulting output image.

1 1 5 5 0 0 1 0

1 1 2 2 0 1 0 1

1 7 6 6 5 5 0 0

0 7 6 7 5 5 5 5

4 7 6 7 3 5 7 0

1 1 4 1 6 5 6 1

2 2 4 1 1 5 1 1

1 2 2 0 0 0 0 5


版权所有:编程辅导网 2021 All Rights Reserved 联系方式:QQ:99515681 微信:codinghelp 电子信箱:99515681@qq.com
免责声明:本站部分内容从网络整理而来,只供参考!如有版权问题可联系本站删除。 站长地图

python代写
微信客服:codinghelp