Вы находитесь на странице: 1из 8

EE 224 Lab 5 Report

Kathryn Blesi and Abbey WIlder


Section B

This lab is about convolution. We will be taking images and convolving them with
different filters in order to observe the output. We will be using averaging filters and masks. We
will be filtering an unaltered image and an image that has been altered a couple of different
ways. We are doing this in order to observe how changing the image will affect the images
convolved with the filters.

2.1 Image Filtering Using Repeated One Dimensional Filters

In this section, we created a function that filters every row of a given image. When we
first made the filter, we observed that the output was a bit blurred and there were black bars on
the sides of the picture. The first picture we filtered is shown below.

After this, we created 3 different filters that we put the image through; a 3 point
averaging filter, a 7 point averaging filter, and a [1 2 4 2 1]/10 filter. Below is an image showing
the original picture next to each of the filtered pictures.
2.2 Noise Reduction

In this section, we were given an image that had been corrupted by having noise added
to it. We had to put it through a 3 point averaging filter and a 7 point averaging filter in order to
remove some of the noise from the image ghopper_g. Next to these filters, we had to display a
black rectangle for comparison. The images are in order as shown in the title of the graph.

We had to repeat the experiment on the image ‘ghopper_sp’. Below is an image of our
results. The images are in order as shown in the title of the graph.
With both images, the image became blurrier with each filter. The filtering seems to work better
for ‘hopper_sp’ because the image changes more from original to the 3 point averaging filter.

2.3 Edge Detection

For this section, we had to take the image ‘ghopper’ and put it through the type of filter
called a mask. Our result is shown below. Each graph is labeled by which filter the image is
being processed through.
These filters made the image mostly grey, with some of the grasshopper coming through. The
first filter has the most defined outline of the grasshopper.

Extra Credit:

For the extra credit, we put the images ‘ghopper_g’ and ‘ghopper_sp’ through the same
filters used in section 2.3. Below are our results. The first image is for ‘ghopper_g’ and the
second one is for ‘ghopper_sp’.
These images were very similar to the ones we obtained in section 2.3. However, the ones in
the previous section seem to be more defined than these ones. We believe this is because we
are taking images that have already been altered, and altering them more. Whereas in the
previous section, we took an unaltered image and ran it through the same filters.

This lab gave us a really good visual of convolution. We got to play around and
experiment with different types of altered images as well as different filters. In order to do this,
we had to learn how to convolve an image with a filter using Matlab. We also had to learn about
different filters and what they do. Learning about these filters, and seeing how they changed the
image, helped us understand what convolution looks like when it is applied in many different
scenarios.
Appendix:
2.1:

2.2:
2.3:

Extra Credit: (also used with ghopper_g)


Check off sheet:

Вам также может понравиться