Hand detection using PS3-EYE webcam

Yakov lanczner, Merav Joseph

Our project creates an interface enabling a hand detection algorithm in linux environment using HSV representation of the frame

Demonstration:

In the short clip demonstrating our project we are using the low cost PS3-EYE webcam.
The Blue circles
indicates the fingers that were detected according to the algorithm,

the Green polygon
indicates the convex hull surrounding the hand.

Code:

The original code can be found Here.
Our Main code can be found Here.
Our anylsis code can be found Here.

Equipment:

PS3-EYE webcam

Workspace:

Algorithm description:

  1. This is a clear frame captured by the webcam with no algorithm activated.

  2. The first phase is to create a black and white mask according to suitable HSV skin color.

  3. The next phase is dilate the mask in order to remove noise.

  4. The next phase is erosion on the mask.

  5. Final mask after all the phases and after blurring the mask.

  6. Final result after finding the convex hull(green polygon), all potential points (yellow circles)
    and choosing the best candidates “suspected” to be fingers (red circles).

Imporvments to the original code:

  1. The code had a lot of “magic numbers” with no suitable explenation that were replaced with variables
  2. The video had to have a hand in the frame otherwise it freezed or terminated which was fixed
    adding the option to detect whater there is a hand in the frame or not.
  3. OpenCV libraries version mismatch causing compilation errors.
    The issue was fixed by searching for the suitable and updated libraries including correct api’s usage.
  4. Adding modularity to the code and graphicel symbols for the fingers detected (blue circles).
  5. Adding a script for performance analysis and export the data to csv file.
  6. Adding diffrent input modes for running the algorithm
    (video, still image/s, graphics included or excluded view).
  7. Adding the ability to record a video from the worksapce
  8. Adding 101 pictures to create a valid data base for the performance anylsis.
    data such as : “number of fingers”, “finger coordinates” and “Is there a hand in the frame”
    were manulay added to each picture.

Performence anylsis results:

Based on the data base of 101 pictures.

  • Hand Detection accuracy: 99.01%
    (Is there a hand in the frame or not)
  • Fingers Detection accuracy: 92.08%
    (The accuracy of the amount of fingers detected in the frame)

Contact Us:
Yakov lanczner: yakovlan88@gmail.com
Merav joseph: meravtyt@gmail.com

Accessibility
Close Close