[issue24015] timeit should start with 1 loop, not 10

2016-11-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: That was implemented in issue28240. $ time ./python -m timeit "import time; time.sleep(1.0)" 1 loop, best of 5: 1 sec per loop real0m6.176s user0m0.160s sys 0m0.004s -- resolution: -> duplicate stage: -> resolved status: open -> closed

[issue24015] timeit should start with 1 loop, not 10

2016-02-10 Thread Tamás Bence Gedai
Tamás Bence Gedai added the comment: Then maybe the docs should be clarified. "If -n is not given, a suitable number of loops is calculated by trying successive powers of 10 (starting from 10) until the total time is at least 0.2 seconds." -- ___

[issue24015] timeit should start with 1 loop, not 10

2016-02-10 Thread Tamás Bence Gedai
Tamás Bence Gedai added the comment: I don't know what happened to this issue, but it looks good to me. So here is a patch for it as Joachim suggested. $ time ./python -m timeit "import time; time.sleep(1.0)" 1 loops, best of 3: 1 sec per loop real0m4.134s user0m0.116s sys

[issue24015] timeit should start with 1 loop, not 10

2016-02-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think that only one loop is not enough to get reliable result. The first loop often has an overhead. -- nosy: +serhiy.storchaka ___ Python tracker

[issue24015] timeit should start with 1 loop, not 10

2015-04-20 Thread Joachim Breitner
New submission from Joachim Breitner: The docs for the timeit command line interface specify If -n is not given, a suitable number of loops is calculated by trying successive powers of 10 until the total time is at least 0.2 seconds. This sounds as if it it first tries 1, then 10, then 100

[issue24015] timeit should start with 1 loop, not 10

2015-04-20 Thread Martin Panter
Changes by Martin Panter vadmium...@gmail.com: -- nosy: +vadmium ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24015 ___ ___ Python-bugs-list

[issue24015] timeit should start with 1 loop, not 10

2015-04-20 Thread Mark Dickinson
Mark Dickinson added the comment: Huh. I assumed that timeit was doing this already. +1 from me. Affects Python 3.4 and 3.5, too. taniyama:~ mdickinson$ time python -m timeit import time; time.sleep(1.0) 10 loops, best of 3: 1 sec per loop real0m40.165s user0m0.040s sys 0m0.024s