EP375 Computational Physics

Slides:



Advertisements
Similar presentations
Pixels and Digital Images Yrd. Doc. Dr. Ahmet Sayar Kocaeli Universitesi Bilgisayar Muhendisligi Ileri Bilgisayar Grafikleri.
Advertisements

L.Ghadah R. Hadba CT1514-L1.  Computer Graphics :refers to processing of creating a new image from Geometry, Lighting parameters, Materials and Textures.Using.
Insight Through Computing 22. Working with Image Files imread, imwrite, imshow, uint8, rgb2gray.
Introduction to Computer Graphics
How Images are Represented Bitmap images (Dots used to draw the image) Monochrome images 8 bit grey scale images 24 bit colour Colour lookup tables Vector.
Color Names All standards-compliant browsers should handle these color names These color names can be used with the CSS properties of color and background-color.
COMP Bitmapped and Vector Graphics Pages Using Qwizdom.
Module Code: CU0001NI Technical Information on Digital Images Week -2.
Lab #5-6 Follow-Up: More Python; Images Images ● A signal (e.g. sound, temperature infrared sensor reading) is a single (one- dimensional) quantity that.
TOPIC 4 INTRODUCTION TO MEDIA COMPUTATION: DIGITAL PICTURES Notes adapted from Introduction to Computing and Programming with Java: A Multimedia Approach.
Image Processing & Perception Sec 9-11 Web Design.
Foundations of Web Design I Photoshop CS5 Michael Daniel
Introduction to MATLAB
© 1999 Rochester Institute of Technology Introduction to Digital Imaging.
Addison Wesley is an imprint of © 2010 Pearson Addison-Wesley. All rights reserved. Chapter 5 Working with Images Starting Out with Games & Graphics in.
CS112 Scientific Computation Department of Computer Science Wellesley College Numb3rs Number and image types.
1 © 2010 Cengage Learning Engineering. All Rights Reserved. 1 Introduction to Digital Image Processing with MATLAB ® Asia Edition McAndrew ‧ Wang ‧ Tseng.
Bitmap Graphics. Bitmap Basics Bitmap Graphic Bitmap Graphic Paint Software Paint Software.
Multimedia. What is a graphic?  A graphic can be a: Chart Drawing Painting Photograph Logo Navigation button Diagram.
1 Computer Science 631 Multimedia Systems Prof. Ramin Zabih Computer Science Department CORNELL UNIVERSITY.
CMPS1371 Introduction to Computing for Engineers IMAGES.
L23. Working with Image Files imread, imwrite, imshow, uint8, rgb2gray.
8 Graphics Digital Media I. What is a graphic? A graphic can be a:  Chart  Drawing  Painting  Photograph  Logo  Navigation button  Diagram.
Image File Formats By Dr. Rajeev Srivastava 1. Image File Formats Header and Image data. A typical image file format contains two fields namely Dr. Rajeev.
Lecture 27: Image Processing
TOPIC 4 INTRODUCTION TO MEDIA COMPUTATION: DIGITAL PICTURES Notes adapted from Introduction to Computing and Programming with Java: A Multimedia Approach.
Image Editing Vocabulary Words Pioneer Library System Norman Public Library Nancy Rimassa, Trainer Thanks to Wikipedia ( help.
Chapter 1 Definitions & Basics of Digital Image 1.Image 2.Digital Image 3.Raster 4. Vector 5.Image Editing 1.
Introduction to MATLAB Ehsan Adeli M. Iran University of Science and Technology, E-Learing Center, Fall 2008 (1387)
Scanner Scanner Introduction: Scanner is an input device. It reads the graphical images or line art or text from the source and converts.
MA/CS375 Fall MA/CS 375 Fall 2002 Lecture 5.
An Introduction to Digital Image Processing Dr.Amnach Khawne Department of Computer Engineering, KMITL.
Coin Recognition Using MATLAB - Emad Zaben - Bakir Hasanein - Mohammed Omar.
Hank Childs, University of Oregon April “29 th”, 2015 CIS 330: _ _ _ _ ______ _ _____ / / / /___ (_) __ ____ _____ ____/ / / ____/ _/_/ ____/__ __ / /
Image Processing F34IMP lecture 1
Chapter 14 Working with Graphics
Images and Graphics.
What is a digital image ? 1.
BITMAPPED IMAGES & VECTOR DRAWN GRAPHICS
Computer Application in Engineering Design
(Project) by:- ROHAN HIMANSHU ANUP 70282
Graphics 1 Graphics 2 Color 2 I Spy 1pt 1 pt 1 pt 1pt 1 pt 2 pt 2 pt
Data Representation Images.
Image Processing Objectives To understand pixel based image processing
Images and 2D Graphics COMP
Digital imaging.
Vocabulary byte - The technical term for 8 bits of data.
How to Convert Pictures into Numbers
Image Processing & Perception
Compression (of this 8-bit 397,000 pixel image):
Introduction To Photo Editing SHIELA MAE A. AQUINO SRNHS.
DIP 9 65 Original 210 Eye Zoomed.
Vocabulary byte - The technical term for 8 bits of data.
Chapter I Digital Imaging Fundamentals
COMS 161 Introduction to Computing
Introduction to Computer Graphics
EEE3112 Introduction to Multimedia Application & Technology Chapter 1: Image Development by Muhazam Mustapha, September 2012.
6th Lecture – Rectangles and Regions, and intro to Bitmap Images
Representing Images 2.6 – Data Representation.
Introduction to Media Computation
Fourth Year – Software Engineering
COMS 161 Introduction to Computing
COMS 161 Introduction to Computing
EP375 Computational Physics
Digital Image Processing
Multimedia System Image
Hank Childs, University of Oregon
Basic Concepts of Digital Imaging
Non-numeric Data Representation
Lecture 4 - Introduction to Computer Graphics
Presentation transcript:

EP375 Computational Physics Topic 15 IMAGE PROCESSING Department of Engineering Physics University of Gaziantep July 2013

Content Introduction Boundary Value Problems Eigen-Value Problems Schrödinger Equation Example Applications

Introduction We have seen 2D or 3D plots of basic data. In this chapter we will discus some of the elementary processes that can be applied to images.

Nature of Image An image is a two-dimensional sheet on which the color at any point can have essentially infinite variability. Images are taken mostly by digital sensors. 2-D images are M x N array of points usually referred to as picture elements, or pixels, where M and N are the number of rows and columns respectively. Each pixel is “painted” by blending variable amounts of the three primary colors: red, green, and blue => RGB.

The resolution (quality) of a picture is measured by the number of pixels per unit of picture width and height. The color resolution is measured by the number of bits in the words containing RGB components. Typically, 8 bits (values 0–255) are assigned to each color.

By combining the three color values, we have 224 combinations of “true colors”. The human eye can distinguish many more possible combinations!

Image Types Sources of images are data files captured by cameras, scanners and etc. Image files are provided in a wide variety of formats. MATLAB identifies the files in TIFF, PNG, HDF, BMP, JPEG (JPG), GIF, PCX, XWD, CUR, and ICO formats.

True Color Images stored as an M x N x 3 array the first layer contains the red value, the second layer the green value, the third layer the blue value. R: 255 G: 255 B: 255 R: 0 G: 0 B: 0 R: 120 G: 55 B: 142 R: 255 G: 0 B: 0 R: 0 G: 255 B: 0 R: 0 G: 0 B: 255

Gray Scale Images stored the black-to-white intensity value for each pixel as a single value rather than three values. The value 0 corresponds to black and 255 to white.

Reading, Displaying and Writing Images where the result, p, is an M x N x 3 uint8 array of pixel color values. >> p = imread('myFigure.jpg'); >> imshow(p) >> imwrite(p, 'new.png', 'png')

Examples Her we will examine some functions defined for image processing in MATLAB.

% ip1.m clear; clc; figure v = imread('ok.jpg'); image(v) row = input('which row? '); red = v(row, :, 1); gr = v(row, :, 2); bl = v(row, :, 3); plot(red, 'r'); hold on plot(gr, 'g'); plot(bl, 'b');

% ip2.m % convert to gray-scale and black & white A = imread('cicek.jpg'); B = imresize(A,[256,256]); C = rgb2gray(A); D = im2bw(A); subplot(2,2,1); imshow(A) subplot(2,2,2); imshow(B) subplot(2,2,3); imshow(C) subplot(2,2,4); imshow(D)

% ip3.m % invert an image im1 = imread('cameraman.gif'); [m n]=size(im1); im2 = zeros(m,n); for i=1:m-1 for j=1:n-1 im2(i,j)=im1(m-i,n-j); end subplot(1,2,1); imshow(im1); subplot(1,2,2); imshow(uint8(im2));

% ip4.m clear;clc I = imread('cameraman.jpg'); subplot(2,2,1); imshow(I); title('Original Image'); H = fspecial('motion',20,45); MotionBlur = imfilter(I,H,'replicate'); subplot(2,2,2); imshow(MotionBlur);title('Motion Blurred Image'); H = fspecial('disk',10); blurred = imfilter(I,H,'replicate'); subplot(2,2,3); imshow(blurred); title('Blurred Image');

% ip5.m % Finding diffreence between two images clear;clc i1 = imread('planes1.jpg'); i2 = imread('planes2.jpg'); dif= imabsdiff(i1,i2); subplot(2,2,1); imshow(i1); subplot(2,2,2); imshow(i2); subplot(2,2,3); imshow(dif);

% ip6.m % detect edges clear;clc I = imread('coins.png'); BW1 = edge(I,'sobel'); BW2 = edge(I,'canny'); subplot(2,2,1); imshow(I) subplot(2,2,3); imshow(BW1) subplot(2,2,4); imshow(BW2)

% ip7.m % convert frames to movie clear;clc count=0; Nframe = 3; Dframe = 5; mov = avifile('example.avi','compression','None'); for i=1:Nframe name = strcat(num2str(i),'.bmp'); v = imread(name); while count<Dframe count = count + 1; imshow(v); F = getframe(gca); mov = addframe(mov,F); end count = 0; mov = close(mov);

Homework Using MATLAB image processing tool, measure the angle between the Connections for the following figures.

References: [1]. Numerical Methods for Engineers, 6th Ed. S.C. Chapra, Mc Graw Hill (2010) [2]. http://www.mathworks.com/products/matlab [3]. Numerical Methods in Engineering with MATLAB, J. Kiusalaas, Cambridge University Press (2005) [4]. Essential MATLAB for Engineers and Scientist, 3rd Ed Hahn B., Valentine D.T. (2007) [5]. Computational Physics, Giordano J.N. Prentice Hall (1997) [6]. http://en.wikipedia.org/wiki/Infinite_quantum_well [7]. http://en.wikipedia.org/wiki/Harmonic_oscillator_(quantum) [8]. http://en.wikipedia.org/wiki/Lenard-Jones_potential