time.time() strangeness

2008-02-27 Thread Nitro
Ok, my final solution is to add the D3DCREATE_FPU_PRESERVE flag. It didn't harm performance in a noticeable way at all. I was under the impression SSE would be affected by this, too. Additionally I was under the impression that float precision would suffice for time.time(). Obviously I was

time.time() strangeness

2008-02-26 Thread Nitro
Hello, today I encountered a very odd situation. I am on Windows Vista and using Python 2.5.2. Here's a code snippet to illustrate my problem: # uncomment the next line to trigger the problem # myExtensionModule.CreateDirect3D9Device() import time for i in range(0,100): print time.time()

time.time() strangeness

2008-02-26 Thread Nitro
The granularity of time.time can be quite large, maybe as much as 1 second in some systems. Also, if the user can set the time, the output might not be monotone. They might set the clock backwards if it has drifted ahead, or something like that. Better to use an explicit counter if you

time.time() strangeness

2008-02-26 Thread Nitro
Nevertheless time.time() shouldn't fail here unless DirectX is really badly tinkering with my system. I can tell you more now. If I pass D3DCREATE_FPU_PRESERVE while creating the DirectX device the bug does not appear. This flag means Direct3D defaults to single-precision round-to-nearest

Scope question

2007-08-06 Thread Nitro
Hello, today I wrote this piece of code and I am wondering why it does not work the way I expect it to work. Here's the code: y = 0 def func(): y += 3 func() This gives an UnboundLocalError: local variable 'y' referenced before assignment If I change the function like this: y = 0 def

Re: Scope question

2007-08-06 Thread Nitro
Thanks a lot for clearing this up, Diez! -Matthias -- http://mail.python.org/mailman/listinfo/python-list

cx_Oracle and NCLOBs

2006-11-09 Thread [12]Nitro
, this may possibly not be an error, but instead a misusage (not many examples available, anyways). Any help/suggestion you can provide? Best regards, Nitro -- http://mail.python.org/mailman/listinfo/python-list

cannot install scipy

2006-02-03 Thread nitro
[EMAIL PROTECTED]:~/scipy/scipy-0.4.4$ === nitro -- http://mail.python.org/mailman/listinfo/python-list

Re: cannot install scipy

2006-02-03 Thread nitro
LOL! Thanks- ashamed :-) nitro -- http://mail.python.org/mailman/listinfo/python-list

Re: cannot install scipy

2006-02-03 Thread nitro
I just ran and had one test fail - any ideas? scipy.test(level=1, verbosity=2) == FAIL: check_cdf (scipy.stats.distributions.test_distributions.test_fatiguelife)

Re: cannot install scipy

2006-02-03 Thread nitro
I should add the following informtion that it also printed out: === Ran 972 tests in 2.471s FAILED (failures=1) unittest.TextTestRunner object at 0x40fc4dcc === -- http://mail.python.org/mailman/listinfo/python-list