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.5.tar.gz
(4.7 kB
view hashes)
Built Distribution
Close
Hashes for functimer-1.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | becc8de0a84bf1813bf425661d039d7a66ab7f29f4a6d20ba06ddeec3e00f331 |
|
MD5 | c4a14c6a70b8cb02efa705fd8755eeba |
|
BLAKE2b-256 | b03505a1d704171e6e8ebabefb2d520801c601850482ec77a3e2eb22b531cf9e |