GithubHelp home page GithubHelp logo

chetanmreddy / hand-gesture-recognition Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 2.0 7 KB

This project implements a hand recognition and hand gesture recognition system using OpenCV on Python 3.5.The detected hand is then processed and modelled by finding contours and convex hull

Python 100.00%

hand-gesture-recognition's Introduction

Hand-gesture-recognition

INTRODUCTION

This project implements a hand recognition and hand gesture recognition system using OpenCV on Python 3.5. A histogram based approach is used to separate out a hand from the background image. Background cancellation techniques are used to obtain optimum results. The detected hand is then processed and modelled by finding contours and convex hull to recognize finger and palm positions and dimensions. Finally, a gesture object is created from the recognized pattern which is compared to a defined gesture dictionary.

Platform: Python 3.5

Libraries: OpenCV 3, Numpy

Hardware Requirements: Camera/Webcam

USAGE

Run HandRecognition.py to begin the program.

Note for Windows users: Remove this line from all .py files: '#!/usr/bin/python' or else you might get some error.

You will find a window that shows your camera feed. Notice a rectangular frame on the right side of the window. That's the frame where all the detection and recognition works.

To begin, keep your hand and body outside the frame, so as to capture just the background environment, and press 'b'. This will capture the background and create a model of it. This model will be used to remove background from every frame captured once the program setup is complete.

Now, you have to capture your hand histogram. Place your hand over the 9 small boxes in the frame so as to capture the maximum range of shades of your hand. Don't let any shadow or air gap show on the boxed areas for best results. Press 'c' to capture the hand and generate a histogram.

The setup is now complete. Now you will see, by keeping your hand inside the rectangular frame, it gets detected and you will notice a circle inside your palm area, with lines projecting out from it towards your fingers. Try moving your hands, hiding a few fingers or giving it one of the sample gestures implemented in the program.

They are:

  1. "V" with your index and middle finger

  2. A flipped "L" with thumb and index finger

  3. Pointing with your index finger in vertical position

Note: Press 'q' at any time to stop the program or 'r' to restart the program.

hand-gesture-recognition's People

Contributors

chetanmreddy avatar

Stargazers

Nishan B avatar

Watchers

James Cloos avatar Eric Yum avatar  avatar

Forkers

kriti26 zhijguo

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.