Measures program speed
Project description
Optimization Library
The optimization library measures the general speed of a program based on the last run.
This library can be used by developers to speed up their programs.
Example Usage:
First, import the library:
from optimization import optimization
Next, the library needs to be initialized:
opt = optimization.OptimizationLibrary()
Finally, we can start and stop the timer:
opt.start_timer()
'''
implement function/program to meausure
'''
opt.end_timer()
Example File
from optimization import optimization
def function_to_optiimize()
pass
def test():
opt = optimization.OptimizationLibrary()
opt.start_timer()
function_to_optiimize()
opt.end_timer()
if __name__ == '__main__':
test()
Additional Notes:
This is a developer tool.
The library has a small performance window (to account for natural program variance).
This is an optional parameter that can be changed with the 'variance' optional parameter.
The library can also be initialized with an optional parameter to show performance increases/decreases visually. This can be changed with the 'color' parameter:
opt = optimization.OptimizationLibrary(variance=2.5, color=True)
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file optimization-lib-2.0.0.tar.gz.
File metadata
- Download URL: optimization-lib-2.0.0.tar.gz
- Upload date:
- Size: 2.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25dac3f44d24edfae05698900b009e7f12cc427f2b084c44eadcba7959ca7fc9
|
|
| MD5 |
b716788382f3888c74c49e9a8b132baa
|
|
| BLAKE2b-256 |
31dcd2f91a6fdbaf8b88139020c7ebda8e7d43314ffd3733707a5f69709b42a2
|
File details
Details for the file optimization_lib-2.0.0-py3-none-any.whl.
File metadata
- Download URL: optimization_lib-2.0.0-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f843226007b8d09aac24ab466642d157139485f66c7af6eb1fe34f4ae08cb058
|
|
| MD5 |
515a536f913b16ff1403efe7dfb933b8
|
|
| BLAKE2b-256 |
7665d1f60476c8208f6f8a28b8098c374aa0a38fc4e65cd01a6f6547b42ff8c7
|