a simple tool to monitor execution times of functions.
Project description
chronox
Execution profiling engine or (Emre's profiling engine :D)
a simple tool to monitor execution times of functions.
import timeit
function and use as a decorator for the function you want to monitor
if you pass an empty dict to it as below, you can get the results and use it in code.
otherwise it will print duration.
usage:
from chronox import timeit
print("without stats dict provided")
@timeit()
def my_func_to_test():
for x in range(100000):
y = x ^ 2
my_func_to_test()
stats = {}
print("without stats dict provided")
@timeit(stats)
def my_func_to_test_with_stats():
for x in range(100000):
y = x ^ 2
my_func_to_test_with_stats()
print(stats)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
eprofiler-0.0.1.tar.gz
(2.0 kB
view hashes)
Built Distribution
Close
Hashes for eprofiler-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a6a48395c516b30b2cc39461850eb0b6757f7ee0d8ad871b7c23c8aa3130d8f |
|
MD5 | 3719fa365a9784fe94e9df1a070102d8 |
|
BLAKE2b-256 | b600d31d7f019e35f6adf95cc70fa6d42c66a0067645429786ef293851f9b361 |