Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow input path specification and show progress bar #4

Merged
merged 2 commits into from
Feb 6, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Show progress bar using Rich
hugovk committed Feb 6, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit d324ddd4c552af8de725501d6970820c59608272
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -37,6 +37,7 @@ install_requires =
gpxpy
matplotlib
pandas
rich
seaborn
python_requires = >=3.7
package_dir = =src
3 changes: 2 additions & 1 deletion src/strava_py/process_data.py
Original file line number Diff line number Diff line change
@@ -3,6 +3,7 @@
import fit2gpx
import gpxpy
import pandas as pd
from rich.progress import track


# Function for processing (unzipped) GPX and FIT files in a directory (path)
@@ -56,7 +57,7 @@ def process_fit(fitfile):
# Process all files (GPX or FIT)
processed = []

for fpath in glob.iglob(path):
for fpath in track(glob.glob(path), description="Processing:"):
if fpath.endswith('.gpx'):
processed.append(process_gpx(fpath))
elif fpath.endswith('.fit'):