TA的每日心情 | 衰 2019-11-19 15:32 |
|---|
签到天数: 1 天 [LV.1]初来乍到
|
EDA365欢迎您登录!
您需要 登录 才可以下载或查看,没有帐号?注册
x
! C9 _* Z6 d# i8 |; o" k
一、简介
/ O8 Z5 ]# k% t9 j9 }% g
0 a0 |3 A+ O9 s. K& F& Q1 s3 I基于matlab人脸识别之检测脸、眼、鼻子和嘴
0 [' _* C, n$ H7 s5 F% u5 C" X9 o
7 b) Z% \; l" I( u9 V$ Q( N6 {1 J! G1 ]" z
! i. Q' A/ ~! E1 I: \7 i
二、源代码, B- j4 x' N% n+ Z, m' C# X, i$ q
- ~- i8 F7 n9 m9 l+ X6 v3 f
- 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
- %}4 T' k% Q* Q. g! M6 J
/ U+ L6 k" f7 T- v
% q! x6 [1 k( s2 F. E
三、运行结果: D* [# d; x7 z# ?
) I; l- F( ^1 ]/ k# U
5 s$ y( c: I5 N9 @) V |
|