pytrainer/pytrainer — pull request #42 by privong (2014-10-05 03:43:50+00:00)
Title: smoothelevation module

This is a start at addressing issue #21. I adapated some of the fixelevation.py extension infrastructure and wrote some new code to do the smoothing and elevation updating. Based on my testing, the code seems to accurately pull out the elevation data, and smooth it using a gaussian with a sigma of ~4 GPS datapoints. However, the module appears to fail at trying to overwrite the old GPX file, and I have not been able to figure out why. (It also fails when trying to write to a new file).

Since it does not currently work, I am mostly submitting this PR to get feedback on the module. Let me know if you have any comments...

There are some obvious future additions. But possibly with the exception of the first two, they would be "nice to have"::
* user-selectable width
* smooth the output of the "fixelevation" elevations instead of the original GPX data
* smoothing with a window defined in time instead of in the number of points
* user-selectable window shape