StudentShare
Contact Us
Sign In / Sign Up for FREE
Search
Go to advanced search...
Free

Methods Used to Complete Convolution Process - Coursework Example

Summary
This coursework "Methods Used to Complete Convolution Process" focuses on completing the convolution process. The variables of the function were determined by inputting the data in the Matlab file with the aim of obtaining a function that will filter the results and obtain NewpixelValue…
Download full paper File format: .doc, available for editing
GRAB THE BEST PAPER97.5% of users find it useful

Extract of sample "Methods Used to Complete Convolution Process"

Multimedia Communications Speech and Image Communications Student’s Name Course Title: Date: Convolution process Method used to complete convolution process—in completing the convolution process, the variables of the function were determined by inputting the data in matlab file CALCONV.M with the aim of obtaining a function that will filter the results and obtain NewpixelValue = CalConv (imSegment, filter). This was arrived by obtaining the newpixelvalue through a calculation of the sum of convolution of the filter with the image. The input was iSegment which ended up obtaining the number multiple. This is done by identifying the signals in a form of a matrix that would be used. In identifying the signals in identifying the signals we obtained two vectors that were necessary to obtain convolution function. After the vectors, we defined the range at which convolution was going to take. In the equation w is taken as an image which needs to be masked using a filtering matrix which would be obtained in the process of calculation. A mask matrix of 3 by 3 will be determined which will be used in the filtering process. The library functions are used to carry out multiplication as well as additions for each mask. This has been done in the file ConvImageFilt.m Iteration in the development of the code To begin with a space was allocated for convolution result where iterate for the values of k was done. The values of (b) and (a) as well as (x) and (h) have been identified as a=0:5; then enter will read to the next line where another code will be put. This will have more than fore iteration. The second case will be b= 0:5; then enter where the next line will appear for more codes taking up to five iterations. Testing the resulting code In order for one to test whether the codes are correct, the input and output are tested. The key to successful, efficient testing is producing good test cases—test cases that are most likely to expose bugs. This task is hard because the input possibilities accepted by a nontrivial program are, for all practical purposes, infinite. Thus we must find a way to reduce the number of possible test cases into a smaller, more manageable set that is still effective at exposing any potential bugs. The basic idea behind equivalence partitioning is that if two inputs test the same portions of code, you only need one of the inputs in your test set. From a testing standpoint, the two inputs are equivalent. For example, suppose you are developing a calculator program. You have just implemented the addition operation and you are developing test cases to make sure addition works properly before implementing other operations. You try the test cases 1 + 2, 2 +1, 0 + 3, and 0 + 0. The calculator produces the correct sums for these test cases. If test case 1 + 2 worked, test case 1 + 3 will work. A good test case to add would be -1 + 3. This case is in a new equivalence class because the first operand is negative. The self-check exercises ask you to develop additional test cases for the calculator program that are in new equivalence classes. One of the most common strategies is boundary testing. The motivation for boundary testing is that program bugs occur most often at boundaries. Furthermore, if the code works properly at the boundaries, it probably works correctly elsewhere. One analogy sometimes used is that if you can walk along an edge of a cliff on a plateau without falling off, you can probably walk in the middle of the plateau. There are several types of boundaries depending on the code. There are loop boundaries—does the loop do the right thing at the beginning and the end; data boundaries—does the code do the right thing when handling data that is at the boundary of allowable values; and capacity boundaries—does the code correctly handle the situation when the array is full and empty. Low and high pass filters Filter_a and filter_b are low pass filters as they are shown above. In this case, the image has almost similar features with the original accept a few changes. Filter_c and filter_d are high pass filters as shown in the images above. Image that comes from filter_c has generalized the features while the output from filter_d has edge enlargement with discontinuities in some of the features. The two filters have modified the image radically by emphasizing the edges. The output image of the two is blurred to the point it cannot be recognized properly. High pass filter as shown above helps in detecting the edge. Effects and application of the filters The first image will have its edges softened and some craters will fade away. In the second case the edges will become sharp, some features standout while others will not change. The third image some original features will disappear but others will remain. Low pass and high pass filters are used in designing images and detecting their edges. It is important when the objects are blurred. One would be in a position to determine on what to change on an image so that it may look clear. High pass filter in the examples above can be reduced in an image due to come unnecessary while maintaining the most important features. Low pass filter are usually used in enhancing some features which may not be very clear. However, practically it is to reduce the size of the image and the noise of the amplifier. It can also be used in enhancing the color of images Two images The two images that have been identified with high pass where edge detection works well and does not work well are shown below. The first image edge was well detected and in the second image the edge was not detected. Two images with edge detection and with no edge detection The first images that edges were well detected as compared to the left image. Creating and applying personalized filter As my student number is 570732. In this case, the filter will be shown as follows:- From this case it shows that my student number is a low pass filters. This produces an image whose edges are not properly detected. It resembles the original image. The image is as shown below Effects of my personal filter on the image When the image was filtered using my personal filter the resultant image had their color change as well the edges disappeared. The image had a lot of light meaning that the personal filtered allowed light to go through. The image was more blurred than in other cases as shown above. This means my personal filter reduced the sharpness of the image and the colors of the image. This filter is used in modeling optical length which can be used in blurring objects. It is also used in designing equipments which can reduce noise of the image. If the image obtained after filtering is added to the original image a clear and sharper image will be made. Reference Trucco, E. & Verri, A., 1998. “Introductory Techniques for 3-D Computer Vision”, Edge detection. Available from:. [Accessed 15 November, 2012]. Appendix – codes >> im = imread('ID-1008575.jpg'); >> if size(im,3) == 3 im = rgb2gray(im); end >> imshow(im) >> fprintf('Displaying original image\n'); Displaying original image >> Pause; >> m = size(im,2); >> n = size(im,1); >> a = floor(size(filter,2)/2); >> x = 1:m >> for y = 1:n for x = 1:m if (xm-a) || (yn-b) imout(y,x) = 0; else imSegment = double(im(y-b:y+b,x-a:x+a)); imout(y,x) = CalcConv(imSegment,filter); end a = floor(size(filter,2)/2); b = floor(size(filter,1)/2); filter_a = [1 1 1;1 1 1;1 1 1]; filter_a = [1 1 1;1 1 1;1 1 1]; filter_b = [1 3 1;3 16 3;1 3 1]; filter_c = [1 1 1;1 -8 1;1 1 1]; filter_d = [0 1 0;1 -4 1;0 1 0]; output_mat =(im, filter_a); >> output_mat =im(filter_a); >> filter_a = [1 1 1;1 1 1;1 1 1]; >> filter_b = [1 3 1;3 16 3;1 3 1]; >> filter_c = [1 1 1;1 -8 1;1 1 1]; >> filter_d = [0 1 0;1 -4 1;0 1 0]; >> output_mat =im(filter_a); >> outputIm = mat2gray(output_mat, [0 255]); >> imwrite(outputIm,'outIm_a.jpg'); >> imshow(outputIm); >> fprintf('Displaying filtered image\n'); Displaying filtered image >> output_mat =im(filter_b); >> outputIm = mat2gray(output_mat, [0 255]); >> imwrite(outputIm,'outIm_b.jpg'); >> imshow(outputIm); >> fprintf('Displaying filtered image\n'); Displaying filtered image >> filter_c = [1 1 1;1 -8 1;1 1 1]; >> outputIm = mat2gray(output_mat, [0 255]); >> imwrite(outputIm,'outIm_c.jpg'); >> imshow(outputIm); >> fprintf('Displaying filtered image\n'); Displaying filtered image >> imwrite(outputIm,'outIm_d.jpg'); >> imshow(outputIm); >> fprintf('Displaying filtered image\n'); Displaying filtered image Read More

CHECK THESE SAMPLES OF Methods Used to Complete Convolution Process

Design And Analysis Of Algorithms For Obtaining Super Resolution Satellite Images

Secondly, the pixels from the LR images are used to sparsely populate some of the pixels of the high resolution image.... Iterative reconstruction entails iterative algorithms which are used to reconstruct 2-dimensional and 3-dimensional images into certain imaging techniques.... Then, median filter is used to remove the outliers.... Bilinear interpolation is then used to reconstruct the result of median filter (Xiang-guang, 2008)....
18 Pages (4500 words) Essay

Factors affecting quality of MRI image.Benefits of circular or square spiral EPI methods

As seen in figure 10, it is thus necessary to complete the sampling of image data from k-space data before these can be consolidated (Mueller et al.... Spirals are specifically used to decrease the time needed to cover the entire k-space.... The consolidation of measured and estimated k-space data is then used to produce the image (Figure 10).... However, the rf must not be too fast for the imaging process to miss out obtaining all samples necessary to make a good quality image....
10 Pages (2500 words) Essay

Neural Networks for handwriting recognition

16 Pages (4000 words) Essay

The Increasing Importance of Complexity in International Relations

This concept is used to describe the fragility and susceptibility of apparently large systems to collapse or large-scale change (Clemens, 16).... The concept of self-organized criticality can be used to explain the collapse of the USSR.... It can be used to appreciate that even states that appear large and powerful can be extremely vulnerable to apparently small changes in the environment.... Krasner (2009) states how punctuated equilibrium can be used to explain the effects of Western imperialism on various societies....
12 Pages (3000 words) Essay

Remote Sensing and Image Analysis

and ratios are used to restrain lighting differences attributable to surface “albedo, look angle and topographic effects.... (Parkinson) Training areas generally minute and isolated judged against to the bursting image are used to “train” the categorization algorithm to distinguish land cover module based on their shadowy signatures, as found in the picture.... This work called "Remote Sensing and Image Analysis" describes the main steps in the remote sensing process....
9 Pages (2250 words) Assignment

The Increasing Importance of Complexity in International Relations

This concept is used to describe the fragility and susceptibility of apparently large systems to collapse or large-scale change13.... he concept of self-organized criticality can be used to explain the collapse of the USSR.... It can be used to appreciate that even states that appear large and powerful can be extremely vulnerable to apparently small changes in the environment.... Krasner (2009) states how punctuated equilibrium can be used to explain the effects of Western imperialism on various societies....
16 Pages (4000 words) Report

Analysis of Surfaces Using an Atomic Force Microscope

Piezoelectric elements are used to facilitate the precise motion of electrons to enable accurate scanning.... It can greatly assist a learner to understand how atomic force microscopy is used to produce high-resolution images of specimens for scientific or industrial applications.... tomic force microscopy (AFM) or scanning probe microscopy (SPM) is an imaging technique used to obtain images as well as other information from a sample at a very high resolution....
8 Pages (2000 words) Lab Report

Effects of Personalized Filter and Its Use

ethod applied to complete convolution process- Matlab has conv as in-built function to solve the convolution equations.... with the aim of completing the convolution process and create a function of the new pixel.... A new variable will be introduced to the convolution process which will be used in filtering.... This will make the end of the convolution process where the new pixel values will be obtained as NewPixelValue = normalised; ...
4 Pages (1000 words) Assignment
sponsored ads
We use cookies to create the best experience for you. Keep on browsing if you are OK with that, or find out how to manage cookies.
Contact Us