Code for Fingure Print in Matlab

Embed Size (px)

Citation preview

  • 8/12/2019 Code for Fingure Print in Matlab

    1/5

    INTRODUCTION:

    Implementation of a verification identification System is a

    major issue when it comes to human personality identificationand verification. This can be done by using Matlab and its

    components like Image Processing.

    METHOD OF IMPLEMENTATION:

    Implementation of the recognition system is containing foursteps:

    1. Image reading from database.2. Edge detection.

    3. Comparison of images.

    4. Decision making.

    1. IMAGE READING FROM DATABASE

    Image can be read from database that is downloaded from thewebsite of AMERICAN UNIVERSITY OF BEIRUT in TIF (Tagged imagefile) format.

    Here we have taken two images for detection of difference

    between images and similarity between them.

    2. EDGE DETECTION.Edge detection is a fundamental tool in image processing,

    machine vision and computer vision, particularly in the areasof feature detection and feature extraction, which aim at

    identifying points in a digital image at which the imagebrightness changes sharply or, more formally, has

    discontinuities.

    The basic concept is:

  • 8/12/2019 Code for Fingure Print in Matlab

    2/5

    The image is normally gray scaled and it is converted intobinary one that means the value.

    255 for black dots

    0 for white dots

    3. COMPARISON OF IMAGES.

    Comparison of images is based on algorithm of matching

    black and white points that are present in the fingerprintimage and hence compared using for Matlab basic scripting to

    compare the black and white dots. Decision making is done

    on the basis of no. of dots black or white in the part offingerprint image.

    4. DECISION MAKING.

    The decision making is dependent on the basis of the

    percentage of image matched, i.e. if

    More than 90% matched: Images are matched.

    Less than 90% matched: Images are different.

    Matlab Program:clc; clear all; close all;

    pic1 = imread('A:\PROJECT\db\1.tif');pic2 = imread('A:\PROJECT\db\2.tif');

    figuresubplot(1,2,1);imshow(pic1)subplot(1,2,2);imshow(pic2)

    %so that we obtain white and black points and edges of the objects present %in the picture.

    edge_det_pic1 = edge(pic1,'prewitt');%applying edge detection on firstpicture

    %so that we obtain white and black points and edges of the objects present %in the picture.

    edge_det_pic2 = edge(pic2,'prewitt');%%applying edge detection on secondpicture

  • 8/12/2019 Code for Fingure Print in Matlab

    3/5

    figuresubplot(1,2,1);imshow(edge_det_pic1) subplot(1,2,2);imshow(edge_det_pic2)

    OUTPUT_MESSAGE = ' Hence the pictures have been matched, SAME PICTURES ';

    OUTPUT_MESSAGE2 = ' Hence the pictures have not been matched, DIFFERENTPICTURES ';

    %initialization of different variables usedmatched_data = 0;white_points = 0;black_points = 0;x=0;y=0;l=0;m=0;

    %for loop used for detecting black and white points in the picture. fora = 1:1:256

    forb = 1:1:256if(edge_det_pic1(a,b)==1)

    white_points = white_points+1;else

    black_points = black_points+1;end

    endend

    %for loop comparing the white (edge points) in the two pictures fori = 1:1:256

    forj = 1:1:256if(edge_det_pic1(i,j)==1)&&(edge_det_pic2(i,j)==1)

    matched_data = matched_data+1;else

    ;end

    endend

    %calculating percentage matching.total_data = white_points;total_matched_percentage = (matched_data/total_data)*100;

    %outputting the result of the system.if(total_matched_percentage >= 90) %can add flexability at thispoint by reducing the amount of matching.

    total_matched_percentage OUTPUT_MESSAGE

    else

  • 8/12/2019 Code for Fingure Print in Matlab

    4/5

    total_matched_percentageOUTPUT_MESSAGE2

    end

    Images:

    Results And Outputs:

    With different fingerprints:

    total_matched_percentage =

    7.5049

    OUTPUT_MESSAGE2 =

    Hence the pictures have not been matched, DIFFERENT PICTURES

    With same fingerprints:

    total_matched_percentage =

    100

    http://1.bp.blogspot.com/-0LCcmng5WCg/UKPw_IbNkKI/AAAAAAAAA0A/fQaiaIxFYOA/s1600/fingerprint.png
  • 8/12/2019 Code for Fingure Print in Matlab

    5/5

    OUTPUT_MESSAGE =

    Hence the pictures have been matched, SAME PICTURES