Thursday, May 27, 2010
Identify and track the center of the logical object
after morphological operation.
check if the area of blob is greater than a threshold
sedisk = strel('square',15);
fg = imclose(fg, sedisk);
fg = imfill(fg,'holes');
RLL = bwlabel(fg);
stats = regionprops(RLL,'basic','Centroid');
figure(1),imshow(fr_bw)
hold on
for n = 1:length(stats)
if(stats(n).Area > 100)
plot(stats(n).Centroid(1), stats(n).Centroid(2),'r*')
end
end
Problem: can track less 50% of the cars, however there are too many outiners because of the transformation done during stabilization. also hard to determine the area, i did it using trial and error to get the best fit
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment