A very simple decorator that tracks running time
Project description
Code time tracker
=================
simply tracks ellapsed time of decorated code and print it when script is finished.
In order to use it, just do:
from code_time_tracker import code_time_tracked
and later decorate your code like this:
@code_time_tracked
def my_func():
do_stuff()
And with that, if you run a script with such decoration you'll get something like this output:
]$ python sample.py
... (script output if any)
<Code time tracker __main__.my_func: 0:00:00.001063 timedelta, 2 calls>
=================
simply tracks ellapsed time of decorated code and print it when script is finished.
In order to use it, just do:
from code_time_tracker import code_time_tracked
and later decorate your code like this:
@code_time_tracked
def my_func():
do_stuff()
And with that, if you run a script with such decoration you'll get something like this output:
]$ python sample.py
... (script output if any)
<Code time tracker __main__.my_func: 0:00:00.001063 timedelta, 2 calls>
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
code_time_tracker-0.1.tar.gz
(2.3 kB
view details)
File details
Details for the file code_time_tracker-0.1.tar.gz.
File metadata
- Download URL: code_time_tracker-0.1.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8b4028d8c959d7ffd66342b3f438663543002c0c09ad0e9f717245671246bd8c
|
|
| MD5 |
7f5bd057a0a4a0c22b2a8809ac620fae
|
|
| BLAKE2b-256 |
8356a80e982d76f1a2d72cfccb88d6d81f92bed2ac0050a6284267c7d870d7d5
|