GPXParser#

GPX#

class GPX#

Represents a GPX document

doc#

The parsed GPX document

Type

str

waypoints#

A list of waypoints from the document

Type

list[Waypoint]

tracks#

A list of tracks from the document

Type

list[Track]

routes#

A list of routes from the document

Type

list[Route]

to_csv(include_waypoints, include_tracks, include_routes)#
Parameters
  • include_waypoints (bool) – A bool determining if waypoints should be included in the resulting CSV file. Defaults to True.

  • include_tracks (bool) – A bool determining if tracks should be included in the resulting CSV file. Defaults to True.

  • include_routes (bool) – A bool determining if routes should be included in the resulting CSV file. Defaults to True.

Returns

The parsed GPX object

Return type

GPX

Convert the parsed GPX document into a CSV file


GPXParser#

class GPXParser#

Provides safe parsing and basic utilities for GPX files

gpx#

An object containing the parsed GPX file

Type

GPX

parse(doc)#

Parse a GPX document

Parameters

doc (file) – The GPX file

Returns

The parsed GPX object

Return type

GPX

to_waypoints()#

Convert the parsed GPX document into a list of waypoints

Returns

A list of waypoints

Return type

list[Waypoint]

to_tracks()#

Convert the parsed GPX document into a list of tracks

Returns

A list of tracks

Return type

list[Track]

to_routes()#

Convert the parsed GPX document into a list of routes

Returns

A list of routes

Return type

list[Route]