ridge and bifurcation point count and location coding for Minutiae matching behalf of bellow code...could anyone help?
Show older comments
%Minutiae extraction
s=size(thin_image);
N=3;%window size
n=(N-1)/2;
r=s(1)+2*n;
c=s(2)+2*n;
double temp(r,c);
temp=zeros(r,c);bifurcation=zeros(r,c);ridge=zeros(r,c);
temp((n+1):(end-n),(n+1):(end-n))=thin_image(:,:);
outImg=zeros(r,c,3);%For Display
outImg(:,:,1) = temp .* 255;
outImg(:,:,2) = temp .* 255;
outImg(:,:,3) = temp .* 255;
for x=(n+1+10):(s(1)+n-10)
for y=(n+1+10):(s(2)+n-10)
e=1;
for k=x-n:x+n
f=1;
for l=y-n:y+n
mat(e,f)=temp(k,l);
f=f+1;
end
e=e+1;
end;
if(mat(2,2)==0)
ridge(x,y)=sum(sum(~mat));
bifurcation(x,y)=sum(sum(~mat));
end
end;
end;
% RIDGE END FINDING
[ridge_x ridge_y]=find(ridge==2);
len=length(ridge_x);
%For Display
for i=1:len
outImg((ridge_x(i)-3):(ridge_x(i)+3),(ridge_y(i)-3),2:3)=0;
outImg((ridge_x(i)-3):(ridge_x(i)+3),(ridge_y(i)+3),2:3)=0;
outImg((ridge_x(i)-3),(ridge_y(i)-3):(ridge_y(i)+3),2:3)=0;
outImg((ridge_x(i)+3),(ridge_y(i)-3):(ridge_y(i)+3),2:3)=0;
outImg((ridge_x(i)-3):(ridge_x(i)+3),(ridge_y(i)-3),1)=255;
outImg((ridge_x(i)-3):(ridge_x(i)+3),(ridge_y(i)+3),1)=255;
outImg((ridge_x(i)-3),(ridge_y(i)-3):(ridge_y(i)+3),1)=255;
outImg((ridge_x(i)+3),(ridge_y(i)-3):(ridge_y(i)+3),1)=255;
end
%BIFURCATION FINDING
[bifurcation_x bifurcation_y]=find(bifurcation==4);
len=length(bifurcation_x);
%For Display
for i=1:len
outImg((bifurcation_x(i)-3):(bifurcation_x(i)+3),(bifurcation_y(i)-3),1:2)=0;
outImg((bifurcation_x(i)-3):(bifurcation_x(i)+3),(bifurcation_y(i)+3),1:2)=0;
outImg((bifurcation_x(i)-3),(bifurcation_y(i)-3):(bifurcation_y(i)+3),1:2)=0;
outImg((bifurcation_x(i)+3),(bifurcation_y(i)-3):(bifurcation_y(i)+3),1:2)=0;
outImg((bifurcation_x(i)-3):(bifurcation_x(i)+3),(bifurcation_y(i)-3),3)=255;
outImg((bifurcation_x(i)-3):(bifurcation_x(i)+3),(bifurcation_y(i)+3),3)=255;
outImg((bifurcation_x(i)-3),(bifurcation_y(i)-3):(bifurcation_y(i)+3),3)=255;
outImg((bifurcation_x(i)+3),(bifurcation_y(i)-3):(bifurcation_y(i)+3),3)=255;
end
figure;imshow(outImg);title('Minutiae');
end
12 Comments
indrani dalui
on 1 Jul 2017
Edited: Walter Roberson
on 1 Jul 2017
Walter Roberson
on 1 Jul 2017
You did not include a copy of the error message.
indrani dalui
on 1 Jul 2017
Edited: Walter Roberson
on 10 Jul 2017
Walter Roberson
on 1 Jul 2017
Remove the final "end"
indrani dalui
on 10 Jul 2017
Edited: Walter Roberson
on 10 Jul 2017
Walter Roberson
on 10 Jul 2017
You appear to be missing a "function" keyword at the beginning of that line. But we are guessing, as you have not posted complete code.
Note: in your original code you have
double temp(r,c);
That does the same thing as
double('temp(r,c)');
That is, it takes the string 'temp(r,c)' and converts the characters to double producing a vector such as [115 101 109 ...] . Then because of the ';' at the end of the line, it discards the result of that computation.
That line does not declare temp to be an array of type double() with size r by c. If that was your purpose then you would use
temp = zeros(r,c);
indrani dalui
on 11 Jul 2017
Edited: Walter Roberson
on 11 Jul 2017
indrani dalui
on 11 Jul 2017
Walter Roberson
on 11 Jul 2017
At the time you execute the line
[ S ] = match( M1, M2, display_flag )
you have not defined M1 or M2
indrani dalui
on 12 Jul 2017
indrani dalui
on 13 Jul 2017
Accepted Answer
More Answers (1)
linda Nankabirwa
on 1 Nov 2018
0 votes
hello,can anyone tell how this minutiae extraction algorithm works,i need an explanation please because am trying to use but having problems while matching,thanks
Categories
Find more on Share and Distribute Software in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!