TA的每日心情 | 衰 2019-11-19 15:32 |
---|
签到天数: 1 天 [LV.1]初来乍到
|
EDA365欢迎您登录!
您需要 登录 才可以下载或查看,没有帐号?注册
x
8 R# z; _" p W6 s一、简介
2 M% X5 W; D/ U0 r2 z Y7 t. z! J ~: Y4 B4 A% B, \6 J
基于matlab人脸识别之检测脸、眼、鼻子和嘴
/ C# n/ Z( f" p/ ~
. O; `0 }8 Y4 y% j6 E) M
3 `) Z) Q P+ o
% m' g7 Z. Q R- q0 R7 @
4 z9 b+ c1 w3 P1 E9 S
二、源代码/ ?! i: }. E' c
- b$ Y ?$ b0 R7 p7 d- reqToolboxes = {'Computer Vision System Toolbox', 'Image Processing Toolbox'};
- if( ~checkToolboxes(reqToolboxes) )
- error('detectFaceParts requires: Computer Vision System Toolbox and Image Processing Toolbox. Please install these toolboxes.');
- end
- img = imread('lena.png');
- detector = buildDetector();
- [bbox bbimg faces bbfaces] = detectFaceParts(detector,img,2);
- figure;imshow(bbimg);
- for i=1:size(bbfaces,1)
- figure;imshow(bbfaces{i});
- end
- % Please uncoment to run demonstration of detectRotFaceParts
- %{
- img = imrotate(img,180);
- detector = buildDetector(2,2);
- [fp bbimg faces bbfaces] = detectRotFaceParts(detector,img,2,15);
- figure;imshow(bbimg);
- for i=1:size(bbfaces,1)
- figure;imshow(bbfaces{i});
- end
- %}
% x! k7 X4 R5 Q
& H/ c: S9 e% F$ g# o; y) I
. A% o7 {/ q4 y$ M5 e+ R% J三、运行结果- U) y! T$ y2 `0 x* q9 l
2 N! V5 L, L6 \
+ W; L6 z' q, S2 i. F) y2 B8 K. ^ |
|