[EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> I am following this python example trying to time how long does an
> operation takes, like this:
>
> My question is why the content of the file (dataFile) is just '0.0'?
> I have tried "print >>dataFile, timeTaken" or "print >>dataFile,str(
> tim
On Mon, 22 Jan 2007 15:32:58 -0800, samuel.y.l.cheung wrote:
> File "/usr/lib/python2.4/timeit.py", line 188, in repeat
> t = self.timeit(number)
> File "/usr/lib/python2.4/timeit.py", line 161, in timeit
> timing = self.inner(it, self.timer)
> File "", line 6, in inner
> NameError:
Thanks.
I have a fuction called 'func1'.
def func1:
# logic of the function
When my script just call 'func1()' it works.
func1()
But when put it under timerit.Timer, like this:
t = timeit.Timer("func1()","")
t.repeat(1, 10)
# want to time how long it takes to run 'func1' 10 times, I get a
On Mon, 22 Jan 2007 14:05:16 -0800, [EMAIL PROTECTED] wrote:
> Hi,
>
> I am following this python example trying to time how long does an
> operation takes, like this:
>
> My question is why the content of the file (dataFile) is just '0.0'?
> I have tried "print >>dataFile, timeTaken" or "print
At Monday 22/1/2007 19:05, [EMAIL PROTECTED] wrote:
I am following this python example trying to time how long does an
operation takes, like this:
My question is why the content of the file (dataFile) is just '0.0'?
I have tried "print >>dataFile, timeTaken" or "print >>dataFile,str(
timeTaken)