While using Libor Masek Iris Recognition Code, I'm getting a particular error in segmentris.m while executing?
Mostrar comentarios más antiguos
function [row, col, r] = findcircle(image,lradius,uradius,scaling, sigma, hithres, lowthres, vert, horz)
lradsc = round(lradius*scaling);
uradsc = round(uradius*scaling);
rd = round(uradius*scaling - lradius*scaling);
% generate the edge image
[I2, or] = canny(image, sigma, scaling, vert, horz);
I3 = adjgamma(I2, 1.9);
I4 = nonmaxsup(I3, or, 1.5);
edgeimage = hysthresh(I4, hithres, lowthres);
% perform the circular Hough transform
h = houghcircle(edgeimage, lradsc, uradsc);
maxtotal = 0;
% find the maximum in the Hough space, and hence
% the parameters of the circle
for i=1:rd
layer = h(:,:,i);
[maxlayer] = max(max(layer));
if maxlayer > maxtotal
maxtotal = maxlayer;
r = int32((lradsc+i) / scaling);
[row,col] = ( find(layer == maxlayer) );
row = int32(row(1) / scaling); % returns only first max value
col = int32(col(1) / scaling);
end
end

2 comentarios
Fatima ezzahrae
el 21 de Dic. de 2022
hi please can u send me the source code i had some problems while using labor mask code
Fatima ezzahrae
el 21 de Dic. de 2022
@Jonathan Bonaparte this is my mail fate5213te@gmail.com
Respuestas (1)
Walter Roberson
el 19 de Sept. de 2018
The rd you calculate does not necessarily come out as at least 1. When it does not, then
for i=1:rd
will not execute at all, and row and col and r will not get assigned to.
(It looks to me as if houghcircle() is from some File Exchange contribution.)
It is also possible that no circles are being detected in the input image.
Categorías
Más información sobre Read, Write, and Modify Image en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!