GithubHelp home page GithubHelp logo

leeyongchao / online-realtime-action-recognition-based-on-openpose Goto Github PK

View Code? Open in Web Editor NEW

This project forked from lzqtheplane/online-realtime-action-recognition-based-on-openpose

0.0 1.0 0.0 67.81 MB

A skeleton-based real-time online action recognition project, classifying and recognizing base on framewise joints, which can be used for safety surveilence.

License: Apache License 2.0

Python 99.17% Shell 0.83%

online-realtime-action-recognition-based-on-openpose's Introduction

Online-Realtime-Action-Recognition-based-on-OpenPose

A skeleton-based real-time online action recognition project, classifying and recognizing base on framewise joints, which can be used for safety monitoring..
(The code comments are partly descibed in chinese)


Introduction

The pipline of this work is:

  • Realtime pose estimation by OpenPose;
  • Online human tracking for multi-people scenario by DeepSort algorithm;
  • Action recognition with DNN for each person based on single framewise joints detected from Openpose.

Dependencies

  • python >= 3.5
  • Opencv >= 3.4.1
  • sklearn
  • tensorflow & keras
  • numpy & scipy
  • pathlib

Usage

  • Download the openpose VGG tf-model with command line ./download.sh(/Pose/graph_models/VGG_origin) or fork here, and place it under the corresponding folder;
  • python main.py, it will start the webcam. (you can choose to test video with command python main.py --video=test.mp4, however I just tested the webcam mode)
  • By the way, you can choose different openpose pretrained model in script.
    VGG_origin: training with the VGG net, as same as the CMU providing caffemodel, more accurate but slower, mobilenet_thin: training with the Mobilenet, much smaller than the origin VGG, faster but less accurate.
    However, Please attention that the Action Dataset in this repo is collected along with the VGG model running.

Training with own dataset

  • prepare data(actions) by running main.py, remember to uncomment the code of data collecting, the origin data will be saved as a .txt.
  • transforming the .txt to .csv, you can use EXCEL to do this.
  • do the training with the traing.py in Action/training/, remember to change the action_enum and output-layer of model.

Test result

  • actions detection

  • work surveilence

  • multi people


Note

  • Action recognition in this work is framewise based, so it's technically "Pose recognition" to be exactly;
  • Action is actually a dynamic motion which consists of sequential static poses, therefore classifying framewisely is not a good solution.
  • Considering of using RNN(LSTM) model to classify actions with dynamic sequential joints data is the next step to improve this project.

Acknowledge

Thanks to the following awesome works:

online-realtime-action-recognition-based-on-openpose's People

Contributors

lzqtheplane avatar yurochang avatar

Watchers

James Cloos avatar

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.