A decorator/wrapper package to time a given function.
Project description
functimer
A decorator/wrapper package to time a given function.
Installation
PYPI:
pip install functimer
Manual:
poetry build
pip install dist/*.whl
How to install Poetry.
Quick Example
Comprehensive Examples in examples
@timed(unit=Unit.second, number=1)
def timed_sleep(seconds):
sleep(seconds)
runtime = timed_sleep(1)
"1.00 s"
Tests
Run pytest
in the root directory of the repo.
License
MIT
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
functimer-1.0.6.tar.gz
(4.7 kB
view hashes)
Built Distribution
Close
Hashes for functimer-1.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e132ad625cb88c92874bb7f4aa957b112973ced4245263fc268e7f44f8ee9148 |
|
MD5 | 34ead4f157eebeed817397b62d26a3cb |
|
BLAKE2b-256 | 2c743d3d05d7ef41934c4e5355e762151c33666c5d929939b82c548f6a119834 |