ggps is a python library for speed and pace calculations for sports like running and cycling
Project description
ggps - gps file utilities for garmin connect and garmin devices
Features
Parse gpx and tcx files downloaded from Garmin Connect
The GPX parsed Trackpoint data includes additional/augmented values, including as “seq” and “elapsedtime”.
The TCX parsed Trackpoint data additionally includes additional/augmented values, such as “altitudefeet”, “distancemiles”, “distancekilometers”, and “runcadencex2”.
Quick start
Installation:
$ pip install ggps
Use:
>>> import ggps
>>> import ggps
>>> infile = 'data/new_river_50k.gpx'
>>> handler = ggps.GpxHandler.parse(infile)
>>> trackpoints = handler.trackpoints
>>> len(trackpoints)
2636
>>> print(trackpoints[-1].values)
{
"elapsedtime": "05:42:18",
"latitudedegrees": "36.715144934132695",
"longitudedegrees": "-80.9767899569124",
"seq": "2636",
"time": "2015-10-17T17:42:30.000Z",
"type": "Trackpoint"
}
>>> infile = 'data/twin_cities_marathon.tcx'
>>> handler = ggps.TcxHandler.parse(infile)
>>> trackpoints = handler.trackpoints
>>> len(trackpoints)
2256
>>> print(trackpoints[-1].values)
{
"altitudefeet": "864.82941635",
"altitudemeters": "263.6000061035156",
"distancekilometers": "42.6354492187",
"distancemeters": "42635.44921875",
"distancemiles": "26.4924399126",
"elapsedtime": "04:14:24",
"heartratebpm": "161",
"latitudedegrees": "44.95180849917233",
"longitudedegrees": "-93.10493202880025",
"runcadence": "77",
"runcadencex2": "154",
"seq": "2256",
"speed": "3.5460000038146977",
"time": "2014-10-05T17:22:17.000Z",
"type": "Trackpoint"
}
Source Code
See ggps at GitHub .
Includes sample data files.
Changelog
Version 0.1.4
2016/11/06. Version 0.1.4, refactored ggps/ dir. nose2 for tests.
2015/11/07. Version 0.1.3, README.rst
2015/11/07. Version 0.1.1.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file ggps-0.1.5.tar.gz
.
File metadata
- Download URL: ggps-0.1.5.tar.gz
- Upload date:
- Size: 13.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8c82ae6f92518836fd8ec11c8ecae44dd63f42e0c128fd08c6e0625fab8c7331 |
|
MD5 | f65ff3ef695d94115b77c50e4fa08737 |
|
BLAKE2b-256 | 6cb3d1a67a7bbd426c30746dc7f9488160edd62c2fa431d174f71fb1768220d7 |