jovandeginste / workout-tracker

A workout tracking web application for personal use (or family, friends), geared towards running and other GPX-based activities
Other
945 stars 31 forks source link

Add option to read time from filename #57

Closed el-tiuri closed 5 months ago

el-tiuri commented 6 months ago

Hey, first of all very nice project! I was excited to try it, exported my activities from Strava, and promptly noticed I had a suspicious number of activities listed today. It seems like it only looks at the file modified (or created?) date, and not at the file titles. I think it might be useful to also look at file names, since exported data will often have incorrect modified dates.

jovandeginste commented 6 months ago

It should take the time inside the gpx file; maybe there is something missing in your exports?

el-tiuri commented 6 months ago

I just checked the files, there are valid and correct timestamps in them. They were converted from .tcx though, so something might have gone wrong there. I’ll retry using non-converted files, hopefully it fixes the problem.

jovandeginste commented 6 months ago

Okay 👍

jovandeginste commented 5 months ago

@el-tiuri did you get somewhere with the files?

wills106 commented 5 months ago

I have been downloading walks / rides out of Map My Ride / Walk which is a painful process! Then converted the tcx to gpx using Garmin BaseCamp but they are all showing as being walked today.

I am guessing it's using the time and not the time?

I can upload a file if you want? Perhaps there could be a toggle when importing to use first time instead of ?

Would it be much work to support importing the tcx files directly?

jovandeginste commented 5 months ago

Feel free to upload a file! There were some heuristics in place to get a time, maybe there is yet another place inside the file? I don't trust the file's timestamp, and a filename is also finicky (no consistent format...)

wills106 commented 5 months ago

3.77mi Walk.zip I have attached the TCX and Converted GPX in the zip

jovandeginste commented 5 months ago

The converter sets the time-of-conversion as the "main" time, but keeps the track time correct:

image

I'll change the code to reverse the order it gets the time...

wills106 commented 5 months ago

I have managed to convert all / most of my previous workouts a different way now, so

But I think the first track time will help others. As it makes the most logical sense that the first time recorded on the track is the start of the workout.

jovandeginste commented 5 months ago

@wills106 what was the converter you ended up using? I tried to implement a tcx2gpx converter for my Google Fit files, but those contained too little information to be useful. I may take it up again with your file...

wills106 commented 5 months ago

I ended up paying £10 to use RunGap.

Imported Garmin and MapMyRide to the iPad and exported all of them back out as FIT

I still need to rename loads of them. But was a saving trying to get data out of MapMyRide, they are a nightmare to get data back out of!

I had to import 564 files from Garmin / MapMyRide.

The FitoTrack gpx Import's was the easy part!

jovandeginste commented 5 months ago

See #99

wills106 commented 5 months ago

I'm not 100% happy with the conversion (Nothing to do with workout-tracker) I think I still have some issues with EGM84

But for historic data it can stay how it is. The main thing is that new data from FitoTrack is correct.

Edit: The logs are 10-12 years ago, so could be inaccurate GPS chip sets.

Edit 2: It probably is GPS issue. The recording soon drop by 18m to where they should be, also the ride ends at 211m which is very close. Probably a combination of 10-12 year old GPS hardware and starting a ride between two houses. I probably should always start after a few moments by the road in the clear.