GithubHelp home page GithubHelp logo

waddle's Introduction

Conn Warwicker / Software Developer

stats graph languages graph

I work with

php logo javascript logo python logo ubuntu logo moodle logo laravel logo mysql logo amazonwebservices logo

waddle's People

Contributors

afischoffsalesforce avatar briedis avatar ferranfg avatar jeripeier avatar kyoden avatar matteoquintiliani avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

waddle's Issues

Composer not cooperating with tags without "v"

When I tried updating the package with version ^1.0, composer shows this:

- The requested package duckfusion/waddle ^1.0 exists as duckfusion/waddle[dev-master] but these are rejected by your constraint.

Apparently, Composer wants version names as "v1.0" and not "1.0".

We should probably drop the tag and create a new one.

I just tried releasing a "v1.0" tag on my fork and composer could install it without a problem.

Deprecation in PHP 8.1

If you're using PHP 8.1 and you try to convert the duration into a human readable string, PHP 8.1 throws a

PHP Deprecated: Implicit conversion from float 52.233333333333334 to int loses precision in vendor/duckfusion/waddle/src/Converter.php on line 102

I found a function that does the seconds to human readable conversion quickly without throwing the Deprecated notice on Stackoverflow.. https://stackoverflow.com/questions/8273804/convert-seconds-into-days-hours-minutes-and-seconds#19680778

I modified it to return what your function returns though..

/**
 * This is based on the answer provided here
 * https://stackoverflow.com/questions/8273804/convert-seconds-into-days-hours-minutes-and-seconds#19680778
 * @param $seconds
 * @return string
 */
 public static function secondsToHuman($seconds) {
        $dtF = new \DateTime('@0');
        $dtT = new \DateTime("@$seconds");
        return $dtF->diff($dtT)->format('%H:%i:%s');
}

This works for my needs, as long as I call the new method
$totalDurationInHoursMinutesSeconds = \Waddle\Converter::secondsToHuman($totalDuration);

I don't know if you're still supporting/working on this code base.. but I thought I'd send this your way. iIf you're not supporting this code base please let me know, and then I'll just make this a little helper function for the little thing I'm writing.

Division by Zero, when there are no time entries present

If you try to parse a GPX file without any time information the parser will throw an exception because we have a division by zero.
This happens when we try to calculate the speed in GPXParser.php:120
The bug will probably effect the other parsers as well.

Get splits in seconds

Hi there. Im looking around for decent GPS parser.

Im very new to GPS data so im not sure i get everything. I would like to parse gpx files and get data relevand for windsurfing. This would be speed at 2sec max peak, average of five 10s runs, nautical mile, 1 hour.

So if I understand correctly with getSplits i would be able to split data for example in miles return it in array and get speed for this for each new point right ?

Any idea how to split data by seconds and then get the speed from that points ?

Regards, Jaka

Update composer package in packagist

It seems the v1.1 tag is not available in packagist, resulting in being unable to update using composer.

- The requested package duckfusion/waddle ^1.1 exists as duckfusion/waddle[dev-master, dev-pr/10, v1.0] but these are rejected by your constraint.

If I try to install dev-master I get an old commtit 02f1b2e
Could you update the package in packagist?

Feature Request

Hi,
thx for this great parsers.

I'm interested in "real activity time".

$activity->getTotalDuration() does not reflect any breaks in activity.

Maybe it is possible to grep breaks to reflect real activity time. This should also affect average speed and calories, and so on.

Just an idea:
maybe by calculating speed between two points is somewhat below 5kph for biking and 2kph for walking, we got a break.
Or by calculating time between two points that are x-metres in distance to each other.
(because some people track there activity with big intervals)

thx in advance

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.