Skip to content

Latest commit

 

History

History
211 lines (172 loc) · 7.07 KB

README.md

File metadata and controls

211 lines (172 loc) · 7.07 KB

👋 Hand Gesture Recognition

logo

”Hello, Let us help you easily recognize hand gestures 🖐️“


📝 Table of Contents


📙 Overview

  • Hand Gesture Recognition is a machine learning project that aims to recognize hand signs from 0 => 5
  • This project ranked 1st place among 21 teams with 81% accuracy, tested on unseen dataset.
  • Built using Python.
  • Using Libraries
    • opencv
    • numpy
    • matplotlib
    • pandas
    • scikit_image
    • scikit_learn
    • seaborn
    • joblib
  • You can view Data Set which was used to train the model
  • Project Report

🚀 How To Run

pip install -r requirements.txt
  • Add the needed data to test the model in the data folder next to the src folder
├───data
├───src
│   ├───main.py
│   └───predict.py
...
  • Navigate to the src directory
cd src
  • Run the main.py file
python main.py
File Description
Result Classification result of every image by order
Time Time taken for classifying the images
  • Features are saved in ./output.csv

🧱 Project Pipeline

  1. 📷 Read images
  2. 🔁 Preprocessing
  3. 💪 Get features
  4. 🪓 Split Training and Test Data
  5. ✅ Calculate accuracy
  6. 📈 Performance analysis

🤖 Modules

Preprocessing Module

  1. Resize image for faster preprocessing
  2. Apply gamma correction to adjust lighting
  3. Convert image to YCbCr color space
  4. Apply segmentation on the skin color
  5. Skin masking
  6. Convert the segmented & original image to grayscale
  7. Erosion using a 5x5 elliptic kernel
  8. Dilation using a 17x17 elliptic kernel
  9. Region Filling using Contours
  10. Erosion again to clean the image from outside
  11. Masking the eroded image with the original one
  12. Crop image to fit the hand exactly
Input Output

Feature Extraction Module

  1. Apply data augmentation on each image to enhance accuracy
  2. Input each image to the Histogram of Oriented Gradients (HOG)
    1. Resizing
    2. Gradient Computation
    3. Cell Division
    4. Orientation Binning
    5. Histogram Calculations
    6. Block Normalization
    7. Feature Vector
  3. Append array of features of each image in a list

Model Selection

  1. Fitting training data and labels into an SVM model
  2. Dumping model
  3. Getting classified data

✅ Performance Module

Compute Confusion Matrix


👑 Contributors


Abdelrahman Hamdy


Ziad Sherif


Zeyad Tarek


Eslam Ashraf

🔒 License

Note: This software is licensed under MIT License, See License for more information ©AbdelrahmanHamdyy.