CyberMaryVer / workout-app

Example of pose recognition and workout repetition counting using Mediapipe framework

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Workout App

Workout app with pose estimation

img

Requirements

Use pip install -r mpipe_requirements.txt to install all required packages

App installation

git clone https://github.com/CyberMaryVer/workout-app.git
cd workout_web

Examples of usage:


You can try it yourself on your video in colab


  • test camera
python mp_workout.py --test
  • workout DUMBBELL LATERAL RAISE
    • visualize with symmetry mode and full skeleton
python mp_workout.py --mode symmetry --skeleton 1 --config dumbbell_lateral_raise
  • workout DUMBBELL SHOULDER PRESS
    • visualize with gravity-center mode without skeleton
python mp_workout.py --mode gravity-center --skeleton 0
  • by default - workout DUMBBELL LATERAL RAISE
    • visualize with headless skeleton
python mp_workout.py 

Types of workouts

(more types will be added in the future)

DUMBBELL LATERAL RAISE img

DUMBBELL SHOULDER PRESS img

Example of different visualization parameters:

  1. --mode symmetry --skeleton 1

  2. --mode gravity_center --skeleton 2

  3. --mode angles --skeleton 0

  4. --mode angles --skeleton 2

img

Options

The program runs as a command-line script. Below you can see the list of available options. You can always go back to them using the --help flag.

  -h, --help            show this help message and exit
  
  # GENERAL PARAMETERS
  --repetitions         How many repetitions you want to do (by default 4)
  --weight              Your weight in kilograms (by default 55 kg)
  --config              Workout config (by default dumbbell_lateral_raise)
  --save_video          Save video file (result.mp4 - by default).
  
  # VISUALISATION SETTINGS
  --skeleton            If set to 0 shows only keypoints, 1 - default, 2 - headless.
  --mode                Mode: [gravity_center, angles, symmetry].
  
  # DEBUG OPTIONS
  --test                Test camera

About

Example of pose recognition and workout repetition counting using Mediapipe framework

License:GNU General Public License v3.0


Languages

Language:Python 99.4%Language:HTML 0.6%