On Jan 15, 4:50 am, [EMAIL PROTECTED] wrote:
> """
>
> time.clock() isn't high enough resolution for Ubuntu, and time.time()
> isn't
> high enough resolution on windows.
>
> Take a look at datetime. It is good to the micro-second on Linux and
> milli-second on Windows.
> """
On Windows, time.clo
[EMAIL PROTECTED] wrote:
> """
>
> time.clock() isn't high enough resolution for Ubuntu, and time.time()
> isn't > high enough resolution on windows.
>
> Take a look at datetime. It is good to the micro-second on Linux and
> milli-second on Windows.
datetime.datetime.now() does the same thing
"""
time.clock() isn't high enough resolution for Ubuntu, and time.time()
isn't
high enough resolution on windows.
Take a look at datetime. It is good to the micro-second on Linux and
milli-second on Windows.
"""
import datetime
begin_time=datetime.datetime.now()
for j in range(10):
x =
Fredrik Lundh wrote:
> John Machin wrote:
>
>> AFAICT that was enough indication for most people to use time.clock on
>> all platforms ...
>
> which was unfortunate, given that time.clock() isn't even a proper clock
> on most Unix systems; it's a low-resolution sample counter that can
> happi
John Machin wrote:
> On Jan 14, 7:05 am, Ron Adam <[EMAIL PROTECTED]> wrote:
>> I'm having some cross platform issues with timing loops. It seems
>> time.time is better for some computers/platforms and time.clock others, but
>
> Care to explain why it seems so?
>
>> it's not always clear which
John Machin wrote:
> AFAICT that was enough indication for most people to use time.clock on
> all platforms ...
which was unfortunate, given that time.clock() isn't even a proper clock
on most Unix systems; it's a low-resolution sample counter that can
happily assign all time to a process that
On Jan 14, 7:05 am, Ron Adam <[EMAIL PROTECTED]> wrote:
> I'm having some cross platform issues with timing loops. It seems
> time.time is better for some computers/platforms and time.clock others, but
Care to explain why it seems so?
> it's not always clear which, so I came up with the followin
I'm having some cross platform issues with timing loops. It seems
time.time is better for some computers/platforms and time.clock others, but
it's not always clear which, so I came up with the following to try to
determine which.
import time
# Determine if time.time is better than t