Created
September 1, 2021 20:00
-
-
Save mGalarnyk/8c491fbdfe6ce3e498a7f62f03fa9ca4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import math | |
import numpy as np | |
from timebudget import timebudget | |
iterations_count = round(1e7) | |
def complex_operation(input_index): | |
print("Complex operation. Input index: {:2d}".format(input_index)) | |
[math.exp(i) * math.sinh(i) for i in [1] * iterations_count] | |
@timebudget | |
def run_complex_operations(operation, input): | |
for i in input: | |
operation(i) | |
input = range(10) | |
run_complex_operations(complex_operation, input) |
Yea , I will try and see if I get time :(
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Oh dont worry about it then! It is not always easy to find that out unfortunately :(
Just suggesting you write. Every benchmark isn't perfect so I was suggesting you try your own :)