{"id":16519426,"url":"https://github.com/fgebhart/sportgems","last_synced_at":"2025-07-11T20:34:25.473Z","repository":{"id":42060238,"uuid":"321108482","full_name":"fgebhart/sportgems","owner":"fgebhart","description":"Find valuable gems 💎 in your 🚴 activities!","archived":false,"fork":false,"pushed_at":"2023-07-26T20:21:30.000Z","size":1996,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-01T12:45:32.650Z","etag":null,"topics":["activity","parser","pip","python","rust","sports","sports-data"],"latest_commit_sha":null,"homepage":"https://sportgems.fgebhart.dev","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fgebhart.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-12-13T16:26:53.000Z","updated_at":"2022-09-08T20:29:10.000Z","dependencies_parsed_at":"2022-08-12T03:40:50.070Z","dependency_job_id":null,"html_url":"https://github.com/fgebhart/sportgems","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgebhart%2Fsportgems","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgebhart%2Fsportgems/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgebhart%2Fsportgems/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fgebhart%2Fsportgems/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fgebhart","download_url":"https://codeload.github.com/fgebhart/sportgems/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238614507,"owners_count":19501474,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["activity","parser","pip","python","rust","sports","sports-data"],"created_at":"2024-10-11T16:46:45.231Z","updated_at":"2025-02-13T07:31:06.632Z","avatar_url":"https://github.com/fgebhart.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sportgems\n\n[![PyPI](https://badge.fury.io/py/sportgems.svg)](https://badge.fury.io/py/sportgems) [![Python](https://img.shields.io/pypi/pyversions/sportgems.svg?style=plastic)](https://badge.fury.io/py/sportgems) [![Build Status](https://github.com/fgebhart/sportgems/workflows/Test/badge.svg)](https://github.com/fgebhart/sportgems/actions?query=workflow%3ATest) [![Deploy Docs](https://github.com/fgebhart/sportgems/actions/workflows/deploy_docs.yml/badge.svg)](https://github.com/fgebhart/sportgems/actions/workflows/deploy_docs.yml)\n\nSportgems finds valuable gems 💎 in your activities 🚴\n\n\n## What is it?\nSportgems lets you efficiently parse your activity data. It will search and find your\nsections with either max velocity or max climb (see below). It will determine the start,\nend and speed of whatever desired sections you are interested in, e.g. 1km, 2km, 10km\nand others. \n\nSportgems is used in [workoutizer](https://github.com/fgebhart/workoutizer) to find your\nfastest 1km (and other 💎) in all your activities and visualize it. See for example this\nscreenshot of an activity in workoutizer, with the fastest 3km section being highlighted\nin yellow:\n\n\u003cimg src=\"https://i.imgur.com/nOYiFm6.png\" width=\"800\"\u003e\n\n## Installation\nSportgems is written in rust and bundled in a python package using [pyo3](https://pyo3.rs/). Simply\ninstall it using pip:\n```\npip install sportgems\n```\n\n## Documentation\n[sportgems.fgebhart.dev](https://sportgems.fgebhart.dev/)\n\n## How to use it?\n\nIn order to search for gems 💎 in your activity, pass a path and desired distance to e.g.\n`find_fastest_section_in_fit` like:\n\n```python\nfrom sportgems import find_fastest_section_in_fit\n\ndesired_distance = 1_000  # in meter\npath_to_fit_file = \"tests/data/2019-09-14-17-22-05.fit\"\nresult = find_fastest_section_in_fit(desired_distance, path_to_fit_file)\n```\nThe result will be a python object with the following attributes:\n```python\nprint(f'Found fastest section, from {result.start=} to {result.end=} with {result.velocity=} m/s')\n```\n\nwhich prints:\n```\nFound fastest section, from result.start=635 to result.end=725 with result.velocity=2.898669803146783 m/s\n```\n\n## Changelog\nhttps://fgebhart.github.io/sportgems/changelog.html\n\n## Running the tests\n\nIn order to run the rust unit tests simply run\n```\ncargo test --no-default-features\n```\nTo run the python tests, you first need to install the requirements\n```\npip install -r requirements.txt\n```\nand build and install sportgems itself, by compiling it using\n```\nmaturin build --interpreter python3.8 --compatibility manylinux2014 --skip-auditwheel\n```\nthen installing the wheel with\n```\npip install target/wheels/sportgems-*.whl\n```\nand subsequently run the tests\n```\npytest tests/\n```\n\n## Contributing\nContributions are welcome!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffgebhart%2Fsportgems","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffgebhart%2Fsportgems","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffgebhart%2Fsportgems/lists"}