Alex Glow
Published

Face Detection with OpenVINO on Raspberry Pi

Get started using a Pi 3 with Intel's Neural Compute Stick 2, to detect objects and faces.

IntermediateProtip7,342
Face Detection with OpenVINO on Raspberry Pi

Things used in this project

Story

Read more

Code

Face detection example log

Python
Sample feedback from running the face detection tutorial.
pi@f3n:~/openvino $ ./armv7l/Release/object_detection_sample_ssd -m face-detection-retail-0004.xml -d MYRIAD -i images/cam0.jpg
[ INFO ] InferenceEngine:
	API version ............ 2.1
	Build .................. custom_releases/2020/1_d349c3ba4a2508be72f413fa4dee92cc0e4bc0e1
	Description ....... API
Parsing input parameters
[ INFO ] Files were added: 1
[ INFO ]     images/cam0.jpg
[ INFO ] Loading Inference Engine
[ INFO ] Device info:
	MYRIAD
	myriadPlugin version ......... 2.1
	Build ........... 37988
[ INFO ] Loading network files:
	face-detection-retail-0004.xml
	face-detection-retail-0004.bin
[ INFO ] Preparing input blobs
[ INFO ] Batch size is 1
[ INFO ] Preparing output blobs
[ INFO ] Loading model to the device
[ INFO ] Create infer request
[ WARNING ] Image is resized from (3280, 2464) to (300, 300)
[ INFO ] Batch size is 1
[ INFO ] Start inference
[ INFO ] Processing output blobs
[0,1] element, prob = 1    (896,449)-(1752,1637) batch id : 0 WILL BE PRINTED!
[1,1] element, prob = 0.034668    (3132,2297)-(3260,2464) batch id : 0
[2,1] element, prob = 0.0209961    (2998,2035)-(3228,2334) batch id : 0
[3,1] element, prob = 0.0200195    (3135,2065)-(3244,2270) batch id : 0
[4,1] element, prob = 0.0170898    (2919,1963)-(3255,2420) batch id : 0
[5,1] element, prob = 0.0170898    (3137,2187)-(3262,2418) batch id : 0
[6,1] element, prob = 0.015625    (2463,-81)-(3247,1302) batch id : 0
[7,1] element, prob = 0.015625    (1335,791)-(1652,1216) batch id : 0
[8,1] element, prob = 0.0146484    (1915,199)-(3299,2394) batch id : 0
[9,1] element, prob = 0.0146484    (3147,1601)-(3252,1880) batch id : 0
[10,1] element, prob = 0.0136719    (2836,-46)-(3286,1030) batch id : 0
[11,1] element, prob = 0.0136719    (2500,726)-(3286,2199) batch id : 0
[12,1] element, prob = 0.0136719    (3030,2077)-(3177,2265) batch id : 0
[13,1] element, prob = 0.0126953    (1174,881)-(1376,1096) batch id : 0
[14,1] element, prob = 0.0126953    (2387,1822)-(2721,2282) batch id : 0
[15,1] element, prob = 0.0126953    (2528,1817)-(2868,2282) batch id : 0
[16,1] element, prob = 0.0126953    (3015,1959)-(3134,2106) batch id : 0
[17,1] element, prob = 0.0126953    (2991,1906)-(3199,2190) batch id : 0
[18,1] element, prob = 0.0117188    (2717,443)-(3031,1004) batch id : 0
[19,1] element, prob = 0.0117188    (1526,892)-(1792,1290) batch id : 0
[20,1] element, prob = 0.0117188    (3174,1980)-(3263,2139) batch id : 0
[21,1] element, prob = 0.0117188    (2713,1934)-(3084,2432) batch id : 0
[22,1] element, prob = 0.0117188    (834,2054)-(1084,2461) batch id : 0
[23,1] element, prob = 0.0107422    (1588,1118)-(1742,1346) batch id : 0
[24,1] element, prob = 0.0107422    (2440,1620)-(2677,1940) batch id : 0
[25,1] element, prob = 0.0107422    (2330,1419)-(3083,2163) batch id : 0
[26,1] element, prob = 0.0107422    (2126,1247)-(3228,2426) batch id : 0
[27,1] element, prob = 0.0107422    (3014,1823)-(3129,1977) batch id : 0
[28,1] element, prob = 0.0107422    (2974,1750)-(3182,2044) batch id : 0
[29,1] element, prob = 0.0107422    (2802,1527)-(3305,2461) batch id : 0
[30,1] element, prob = 0.0107422    (3116,1943)-(3238,2198) batch id : 0
[31,1] element, prob = 0.0107422    (2296,1828)-(3113,2473) batch id : 0
[32,1] element, prob = 0.0107422    (2770,2027)-(3020,2340) batch id : 0
[33,1] element, prob = 0.0107422    (3054,2038)-(3289,2478) batch id : 0
[ INFO ] Image out_0.bmp created!
[ INFO ] Execution successful

[ INFO ] This sample is an API example, for any performance measurements please use the dedicated benchmark_app tool
pi@f3n:~/openvino

Credits

Alex Glow

Alex Glow

149 projects • 1584 followers
The Hackster team's resident Hardware Nerd. I love robots, music, EEG, wearables, and languages. FIRST Robotics kid.

Comments