GithubHelp home page GithubHelp logo

arpshand's Introduction

A Rapid Prototyping System for Hand Gesture Recognition

Nam Hee Gordon Kim and Tim Straubinger

This is a supplementary code for our project: https://sites.google.com/view/arpshand

We used Python 3.6 on Ubuntu 18.04 LTS along with these libraries (not comprehensive):

  • matplotlib
  • scikit-learn
  • imageio
  • tensorflow

Also, an installation of Docker or Singularity is recommended.

Instructions

Step 1: Deploy the 3D hand pose estimator (Zimmermann et al.)

  • We employed a remote server with a GPU and used socket programming to process videos.
  • We provide the Dockerfile used inside the hand3d subdirectory. If running Docker, docker pull namheegordonkim/handgpu should suffice.
  • Use docker shell or similar to access the files inside the container.
  • Once inside the container, run python3 -u server.py to listen to port 3333.
  • If needed, set up an SSH tunnel so the client running on your edge device can communicate with the remote server.

Step 2: Preprocess data

You can download our video data here: https://www.dropbox.com/s/ep8jhys2ie4kjda/smash-g-data.zip?dl=0

Put all the .mp4 files inside a subdirectory named ./data/.

To process all the data in one command, run this inside a bash shell:

for GESTURE in "ok" "thumbs_up" "paper" "scissors" "call_me" "lets_drink"
do
    for i in {00..08}
    do
        python preprocess_video_with_cc.py --input_file ./data/"$GESTURE"$i.mp4 --output_dir ./data/dynamic/$GESTURE/$i/
    done
done

You should be able to visualize the results of the data by using e.g.

python visualize_angles.py --angles_dir ./data/dynamic/paper/00/angles

Step 3: Learn the models

Run these to generate the needed pickle files:

python learn_clutch.py
python learn_clutch_corrector.py
python learn_onedollar.py

Step 4: Run the live predictor

While the 3D hand pose estimator is deployed, run

python live_predictor.py

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.