Skip to content

Commit 9cc95f1

Browse files
committedJul 17, 2020
warn when no face is detected
Signed-off-by: Mpho Mphego <mpho112@gmail.com>
1 parent a0e535e commit 9cc95f1

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed
 

‎README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ Implementation: https://github.com/mmphego/computer-pointer-controller/blob/bb5f
2828
![face_Detection](https://user-images.githubusercontent.com/7910856/87830444-4a3bf080-c881-11ea-993a-7f76c979449f.gif)
2929

3030
- [Facial Landmarks Detection](https://docs.openvinotoolkit.org/latest/_models_intel_landmarks_regression_retail_0009_description_landmarks_regression_retail_0009.html).
31+
3132
Implementation: https://github.com/mmphego/computer-pointer-controller/blob/bb5f13c6d2567c0856407db6c35b3fa6345f97c2/src/model.py#L239
3233

3334
![facial_landmarks](https://user-images.githubusercontent.com/7910856/87830446-4c05b400-c881-11ea-90a5-d1b80d984f01.gif)
@@ -40,7 +41,6 @@ Implementation: https://github.com/mmphego/computer-pointer-controller/blob/bb5f
4041

4142
- [Gaze Estimation](https://docs.openvinotoolkit.org/latest/_models_intel_gaze_estimation_adas_0002_description_gaze_estimation_adas_0002.html)
4243

43-
Using the above outputs as inputs.
4444
Implementation: https://github.com/mmphego/computer-pointer-controller/blob/bb5f13c6d2567c0856407db6c35b3fa6345f97c2/src/model.py#L422
4545

4646
![all](https://user-images.githubusercontent.com/7910856/87830436-47d99680-c881-11ea-8c22-6a0a7e17c78d.gif)
@@ -233,12 +233,13 @@ bash -c "\
233233
234234
## Edge Cases
235235
- Multiple People Scenario: If we encounter multiple people in the video frame, it will always use and give results one face even though multiple people detected,
236-
- No Head Detection: it will skip the frame and inform the user
236+
- No Face Detection: it will skip the frame and inform the user
237237
238238
## Future Improvement
239+
- [Intel® DevCloud](https://devcloud.intel.com/edge/get_started/guide/): Benchmark the application on various devices to ensure optimum perfomance.
239240
- [Intel® VTune™ Profiler](https://software.intel.com/content/www/us/en/develop/tools/vtune-profiler/choose-download.html): Profile my application and locate any bottlenecks.
240241
- Gaze estimations: We could revisit the logic of determining and calculating the coordinates as it is a bit flaky.
241-
- lighting condition: We might use HSV based pre-processing steps to minimize error due to different lighting conditions.
242+
- Lighting condition: We might use HSV based pre-processing steps to minimize error due to different lighting conditions.
242243
243244
## Reference
244245
- [OpenCV Face Recognition](https://www.pyimagesearch.com/2018/09/24/opencv-face-recognition/)

‎main.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,9 @@ def main(args):
190190

191191
if args.enable_mouse:
192192
mouse_controller.move(gaze_vector["x"], gaze_vector["y"])
193+
else:
194+
if count % 10 ==0:
195+
logger.warning("Could not detect face in the frame.")
193196

194197
if args.debug:
195198
if face_bboxes:

0 commit comments

Comments
 (0)