Skip to content

Fall Detection using OpenPifPaf's Human Pose Estimation model

Notifications You must be signed in to change notification settings

Hackjaku/falldetection_openpifpaf

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fall Detection using Pose Estimation

Introduction

Fall Detection model based on OpenPifPaf

PyPI Library: https://pypi.org/project/openpifpaf/

The detection can run on both GPU and CPU, on multiple videos, RTSP streams, and webcams/USB cameras. Unlike most open-source fall detection models that work on large single subjects, this improved model integrates a person tracker that can detect falls in scenes with more than one person.

Demo Videos

Walking Trip Stubbed Toe Drunk

Video credits: 50 Ways to Fall (Link), ran on a single NVIDIA Quadro P1000

Test Results

UR Fall Detection Dataset (Link), tested on two NVIDIA Quadro GV100s.

  • Precision: 100%
  • Recall: 83.33%
  • F1 Score: 90.91%

Note: Due to lack of available datasets, false positives and true negatives were not tested.

Environment

  • Ubuntu 18.04 x86_64
  • Python 3.7.6
  • Anaconda 3
  • CUDA 10.2

Usage

Setup Conda Environment

$ conda create --name falldetection_openpifpaf python=3.7.6
$ conda activate falldetection_openpifpaf

Clone Repository

$ git clone https://github.com/cwlroda/falldetection_openpifpaf.git

Download OpenPifPaf 0.11.9 (PyPI)

$ pip3 install openpifpaf

Copy Source Files

$ cd {home_dir}/anaconda3/lib/python3.7/site-packages/openpifpaf
Replace ALL files in that folder with the files in falldetection_openpifpaf

Install Dependencies

$ pip3 install -r requirements.txt

Execution

For videos/RTSP streams, navigate to config/config.xml to edit the video/RTSP stream path, then run:

$ python3 -m openpifpaf.video --show
$ (use --help to see the full list of command line arguments)

For webcams/USB cameras, run:

$ python3 -m openpifpaf.video --source {CAMERA_ID} --show
$ (use --help to see the full list of command line arguments)

Citations

PifPaf: Composite Fields for Human Pose Estimation (Link)

@InProceedings{Kreiss_2019_CVPR,
    author = {Kreiss, Sven and Bertoni, Lorenzo and Alahi, Alexandre},
    title = {PifPaf: Composite Fields for Human Pose Estimation},
    booktitle = {Proceedings of the IEEE/CVF Conference on
                Computer Vision and Pattern Recognition (CVPR)},
    month = {June},
    year = {2019}
}

If you use the dataset above, please cite the following work: (Link)

Bogdan Kwolek, Michal Kepski,
Human fall detection on embedded platform using depth maps and wireless accelerometer,
Computer Methods and Programs in Biomedicine,
Volume 117,
Issue 3,
December 2014,
Pages 489-501,
ISSN 0169-2607

About

Fall Detection using OpenPifPaf's Human Pose Estimation model

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%