Git Product home page Git Product logo

Comments (4)

tkrajina avatar tkrajina commented on August 16, 2024

speed is an optional field in GPX 1.0, but it isn't in 1.1 (you can run make analyze-xsd to retrieve xsd files and pretty-print the xsd structure).

to_xml() will try to write the GPX with the original version. But you can force 1.0 with .to_xml(version='1.0'). Do you still have this bug with 1.0?

from gpxpy.

FlorianWilhelm avatar FlorianWilhelm commented on August 16, 2024

Okay, sorry, this is really strange that speed is no longer defined in version 1.1. What if you have a speed sensor coupled to your GPS sensor and want to save this more accurate data somehow? Is it possible to have speed somehow as a valid extension? There is an tag defined, right?

from gpxpy.

tkrajina avatar tkrajina commented on August 16, 2024

I know, and a lot of the complexity in gpxpy 1.0+ comes because of the gpx 1.0/1.1 inconsistencies.

Anyway, you can always use GPXTrackPoint.extensions. The current extensions API is not ideal, because extensions in gpxpy is a dictionary, but in GPX it can contain any XML (and maps aren't a perfect one-to-one representations to any XML chunk). But for simple values, like your speed, it will work.

from gpxpy.

FlorianWilhelm avatar FlorianWilhelm commented on August 16, 2024

okay, so I guess this issue can be closed now since gpx 1.1 lacks the attribute speed and the workaround is to save it as an extension. Still, I am quite unsatisfied and hopefully gpx 1.2 will reintroduce speed as optional attribute directly in the standard. I heard some people argue that speed is not really necessary since it is just the derivation of place by time but this is not so accurate actually for gps. Nowadays it is no problem to connect your bikecycle's tachometer and save the actual way more accurate speed to each gps measurement. With the help of the famous Kalman filter it is then even possible to get even more precise information about the current state using two different sensors that give readings for the current speed.

from gpxpy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.