blob: 2d55153ee71424eae78ca577e30edf75ee1080f7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
|
Time execution of blocks of code.
Tested against python 3.6+, but should work with other versions.
The easiest way to time something is with tic and toc:
import time
from ttictoc import tic,toc
tic()
time.sleep(1)
elapsed = toc()
print('Elapsed time:',elapsed)
|