Raspberry Pi 3 - Camera Face Detection - ??? Build error: C compiler produced errors. See the Build Log for further details.
1 次查看(过去 30 天)
显示 更早的评论
Dear all,
I am trying to run a standalone application of face detection using a raspberry pi and a camera. I am using the package runOnHardware and during the generation of the C/C++ code I got this error:
>> mypi = raspi('xx.xx.xx.xx','pi','raspberry');
>> runOnHardware(mypi,'faceDetection')
------------------------------------------------------------------------
Function TAR tried to add two files as "types_c.h".
------------------------------------------------------------------------
??? Build error: C compiler produced errors. See the Build Log for further details.
Code generation failed: View Error Report
Error using codegen
Error in runOnHardware (line 52)
codegen('-config ',cfg,fcnName,'-report');
This is my simple faceDetection function:
function faceDetection()
%#codegen
w = matlab.raspi.webcam(0,[320,240]);
d = matlab.raspi.SDLVideoDisplay;
for k = 1:1000
img = snapshot(w);
fD = vision.CascadeObjectDetector();
bbox = step(fD, img);
coder.varsize('bbox',[20 4]);
imageOut = insertObjectAnnotation(img,'rectangle',bbox,'face');
displayImage(d,imageOut);
end
release(w);
release(d);
end
Could you please tell me how to solve the problem? Is vision.CascadeObjectDetector System object compatible with such procedure?
Many Thanks in advance.
Ale
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Computer Vision Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!