Skip to main content

PRogramming PROgrams is a Python library for defining training programs.

Project description

PRogramming PROgrams


cov

pr_pro is a Python package for defining training programs. It's main features at a glance are:

  1. Modular and extensible definition of different types of exercises
  2. Export to and import from json files
  3. Automatic computation of weights based on defined max values
  4. Simple visualization in the command line
  5. Ready to deploy streamlit app for each custom program that you define

Simple example

program = get_simple_example_program()
program.compute_values(ComputeConfig(one_rm_calculator=Brzycki1RMCalculator()))
print(program)
--- Workout Test program ---
Best exercise values
  Backsquat: 100
  Bench Press: 80

Workout sessions
--- W1D1 ---
notes: Easy on first day.
Backsquat with 2 sets:
  reps 5, weight 55.0, percentage 0.55, relative_percentage 0.619
  reps 5, weight 55.0, percentage 0.55, relative_percentage 0.619
Pendlay row + Pushup with 2 sets:
  reps 6, percentage 0.6 | reps 10
  reps 6, percentage 0.6 | reps 10
Bench Press with 2 sets:
  reps 8, weight 40.0, percentage 0.5, relative_percentage 0.621
  reps 8, weight 40.0, percentage 0.5, relative_percentage 0.621

pr_pro also allows defining progressions throughout the training block. Look into pr_pro/examples.py for an example of this.

Installation

pip install pr_pro

streamlit visualization

You need to install the visualization dependencies

pip install pr_pro[vis]

Simply define your program and create a file streamlit_app.py with

from pr_pro.streamlit_vis.streamlit_app import run_streamlit_app

program = ...  # Your program
run_streamlit_app(program)

Then run the streamlit app as per usual

streamlit run streamlit_app.py

The app looks like this: Streamlit app example

For a live demo go to https://pr-pro-demo.streamlit.app/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pr_pro-1.0.2.tar.gz (71.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pr_pro-1.0.2-py3-none-any.whl (18.9 kB view details)

Uploaded Python 3

File details

Details for the file pr_pro-1.0.2.tar.gz.

File metadata

  • Download URL: pr_pro-1.0.2.tar.gz
  • Upload date:
  • Size: 71.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.12

File hashes

Hashes for pr_pro-1.0.2.tar.gz
Algorithm Hash digest
SHA256 ff29be9e6f72dd207a77b39b29d51b0f221d3e5df9a207d9b333f73275d59a69
MD5 b5e60be373934255825ab365a52524e3
BLAKE2b-256 8ca2305d4b2ad0a1661397d6497c27196c2a8a56efb65f71529fedb2e56cd1aa

See more details on using hashes here.

File details

Details for the file pr_pro-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: pr_pro-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 18.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.12

File hashes

Hashes for pr_pro-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b840db7cffa7eb6860a5ed60f345b9aa87ca8a112a9e5e772c934b2ecb8bee44
MD5 841cdcab8fcf2285aef0ca909ad95dc5
BLAKE2b-256 caf2b7d57b8eb4c199fc28fc7fcc9fac83c34b399a9947d2be89872e28fd7b85

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page