How to deal with multiple track GPX files
When a GPX file is uploaded to MTBGuru, the file is examined and probed for GPS tracks. GPX files may contain single or multiple tracks.
When you look at the file in a text (or xml) editor you can identify the tracks as content delimited by <trk> and </trk> tags. And tracks themselves may consist of a number of ‘track segments’; segments are identified by the <trkseg> and </trkseg> tags.
So how does MTBGuru interpret these files? Our goal was to make it as easy as possible to fetch the data for your trip, and hence we needed to be quite flexible, as different GPS units will store their data differently. Even using a single device there are many different ways or tools to download the data, each potentially resulting in differently structured GPX files.
In the simplest case, the GPX file contains only a single track – nothing special is going on then, the trip is created using the data in this single track. Track segments are concatenated and displayed as a single trace on the map.
But what happens when multiple tracks are present? When data is downloaded from the GPS, often times it will come as a single file containing all the tracklogs stored in the memory of the device, converted into a single GPX file. This GPX file will typically contain a number of different tracks representing the various tracklogs you’ve recorded over time.
As you may have found out, there are two ways to create a trip from GPS data in MTBGuru:- By Upload GPS data: after you upload a GPX file, you are presented a screen displaying all tracks in the file (see screenshot 1 below), as well as information such as the number of points and date and time. You can then select an individual track and base a trip on it by clicking
Create trip. - By Add a trip: here you start by creating the trip first, and then attach a GPX file to it using
Upload GPX file. If your GPX file has multiple tracks, you’ll be shown a slightly different screen now, that allows you to select and combine multiple tracks (using checkboxes) for this one trip (see screenshot 2 below).
The first option is preferable if your GPX file contains data from various trips or rides, from which you’d like to select and create individual trips.
P.S. GPX files may also contain other data types such as waypoints and we do anticipate support for the latter – currently all waypoints in GPX uploads are stored in our database, such that they can be accessed and used in the future.


