ipython-books / cookbook-2nd

IPython Cookbook, Second Edition, by Cyrille Rossant, Packt Publishing 2018

Home Page:http://ipython-books.github.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rolling average with stride tricks, possible erroneous timings

boffi opened this issue · comments

commented

Hi Cyrille,
in https://ipython-books.github.io/47-implementing-an-efficient-rolling-average-algorithm-with-stride-tricks/ the bullet point no.8, benchmark of copying method, has 15 μs for copying only and 10 μs for copying and taking the mean.
Regards ፨ gb

commented

I realized that the code in the first line in %%timeit is initialization and does not contrinbute to the timing... sorry for the noise