how to find the landmark location in a face by EBGM algorithm

3 views (last 30 days)
please provide the code for finding the landmark points in the face.
  3 Comments
himanshu sharma
himanshu sharma on 29 Apr 2015
Edited: Walter Roberson on 4 May 2015
A=imread('aa.jpg'); %import image
figure,image(A);
title('original image'); %show original image
I = rgb2gray(A); %convert into gray scale
%figure(1);
imshow(I);
title('Original gray scale image');
NormalizedImage=(I-min(I(:)))*(255/range(I(:)));
figure(2) ,
imshow(NormalizedImage);
imwrite(NormalizedImage,'D:\a.jpg');
FDetect = vision.CascadeObjectDetector;
X = imread('D:\a.jpg');
BB = step(FDetect,I);
figure,
imshow(X); hold on
for i = 1:size(BB,1)
rectangle('Position',BB(i,:),'LineWidth',5,'LineStyle','-','EdgeColor','r');
end
title('Face Detection');
hold off;
Y=imcrop(X,BB);
figure,imshow(Y);
//this is my actual code after cropping the face from an image i want to find the landmark location or landmark points.so i am finding the code for localizing the points.
please help me out i have to submit my project by tommorow.
Thomas Koelen
Thomas Koelen on 29 Apr 2015
Good luck if you have to finish a project of that size by tomorrow! Maybe have a look at this mfile: http://www.mathworks.com/matlabcentral/fileexchange/47713-facial-landmarks
I highly suggest that you start your work earlier next time, also do your homework!

Sign in to comment.

Answers (1)

Dima Lisin
Dima Lisin on 29 Apr 2015
That depends on how you define landmarks. You can use vision.CascadeObjectDetector to detect eyes, nose, and mouth, which can be considered landmarks. Alternatively, you can use one of the interest point detector functions, such as detectHarrisFeatures, detectMinEigenFeatures, detectFASTFeatures, detectSURFFeatures, or detectBRISKFeatures.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!