Giter Site home page Giter Site logo

time_delta's Introduction

time_delta

Requerments:

  • Python2.7 or newer.

  • Pandas library installed with version >= 0.23.0.

Pandas installation manual: https://pandas.pydata.org/pandas-docs/stable/install.html


Hi!

Say you need to calculate performance and obtain time delta of two durations and do this instantly without complex manual calculations.

If so, this wonderful script is for you!

All you need to do is prepare two files with time durations in them (for instance like timestamp_file1 and timestamp_file2 in this repo) and use them as arguments:

./time_delta.py timestamp_file1 timestamp_file2

And the output will be like this:

    timestamp_file1  timestamp_file2   TimeDelta
0   00:01:09.881968  00:00:28.754326  -0:00:41.127642
1   00:28:09.376129  00:28:37.043199   0:00:27.667070
2   02:31:09.080779  02:33:59.673946   0:02:50.593167

The math is simple:

current run (timestamp_file2) - past run (timestamp_file1) = TimeDelta.

And if the result is negative - you have an improvement, if not - degradation.

Please note that you can use any naming for the input files:

./time_delta.py first second

It will just change headers names of the table:

    first            second            TimeDelta
0   00:01:09.881968  00:00:28.754326  -0:00:41.127642
1   00:28:09.376129  00:28:37.043199   0:00:27.667070
2   02:31:09.080779  02:33:59.673946   0:02:50.593167

And all your outputs are conveniently stored in CSV files to use it in your further work:

20191024_11_05_49_first_vs_second.csv

Any feedback or notes will be welcomed!

time_delta's People

Contributors

forest-man avatar

Watchers

 avatar

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.