import time
def performance_time(fn):
def wrapper_fn(*args, **kwargs):
start = time.time()
result = fn(*args, **kwargs)
end = time.time()
ms = end - start
print(f"실행 함수 : {fn.__name__} / ", "실행 시간 : ", "{:.5f} sec".format(ms))
return result
return wrapper_fn
@performance_time
def something(data):
...
..
.
print(something(data))