Re: OT: Meaning of monkey

2010-03-29 Thread Gib Bogle
I prefer to think of myself as a code-ape - I look down on code-monkeys. -- http://mail.python.org/mailman/listinfo/python-list

Re: python to exe

2010-03-13 Thread Gib Bogle
Steven D'Aprano wrote: As the old proverb goes: give a man a fish, and you feed him for a day. Teach him how to fish, and he has food forever. I like this version: Light a man a fire, and you keep him warm for hours. Set a man on fire, and you keep him warm for the rest of his life. ;-)

Re: python to exe

2010-03-13 Thread Gib Bogle
Mark Lawrence wrote: I'm certain that members of the Guinea Pig Club might have something to say on that one, see :- http://en.wikipedia.org/wiki/Guinea_Pig_Club You mean, something like: That's not funny? -- http://mail.python.org/mailman/listinfo/python-list

Re: running a program on many processors

2010-03-07 Thread Gib Bogle
Paweł Banyś wrote: ... How can it be achieved? Very carefully. -- http://mail.python.org/mailman/listinfo/python-list

Re: PyQt4.7 and PyQwt5.2.0

2010-03-01 Thread Gib Bogle
Gib Bogle wrote: I installed the latest PyQt (4.7-1), then PyQwt 5.2.0, which was built with PyQt4.5.4. This line import PyQt4.Qwt5 as Qwt fails to load the DLL. Could this be the result of not using PyQt4 4.5.4? I guess I can answer my own question. As far as I can determine, PyQwt

PyQt4.7 and PyQwt5.2.0

2010-02-28 Thread Gib Bogle
I installed the latest PyQt (4.7-1), then PyQwt 5.2.0, which was built with PyQt4.5.4. This line import PyQt4.Qwt5 as Qwt fails to load the DLL. Could this be the result of not using PyQt4 4.5.4? -- http://mail.python.org/mailman/listinfo/python-list

PyQt 4.7 installation on Windows

2010-02-26 Thread Gib Bogle
I've just installed Python 2.6.4 and PyQt 4.7 on my Windows machine, on which I was using Python 2.5 and PyQt 4.5. Now 'from PyQt4 import QtGui' fails to find the DLL. Some googling shows that others have encountered the same problem, and a workaround is to copy QtGui4.dll (for example) from

A more specific query ...

2010-02-26 Thread Gib Bogle
How can I interrogate Python to find out where it is looking to find the PyQt4 DLLs in a Windows installation? Secondarily, how is this search path set? -- http://mail.python.org/mailman/listinfo/python-list

Re: A more specific query ...

2010-02-26 Thread Gib Bogle
Chris Rebert wrote: On Fri, Feb 26, 2010 at 12:45 PM, Gib Bogle g.bo...@auckland.no.spam.ac.nz wrote: How can I interrogate Python to find out where it is looking to find the PyQt4 DLLs in a Windows installation? import sys print(sys.path) Note this thread: http://www.mail-archive.com/p

Re: A more specific query ...

2010-02-26 Thread Gib Bogle
at 12:45 PM, Gib Bogle g.bo...@auckland.no.spam.ac.nz wrote: How can I interrogate Python to find out where it is looking to find the PyQt4 DLLs in a Windows installation? import sys print(sys.path) Cheers, Chris -- http://blog.rebertia.com -- http://mail.python.org/mailman/listinfo/python-list

Re: A more specific query ...

2010-02-26 Thread Gib Bogle
The PyQt4 problem results from having copies of the Qt DLLs in directories that are in the PATH, as Doug Bell discovered. In my case I have two programs that use Qt, AMD CodeAnalyst and Matlab. If I rename BOTH these directories I can import the PyQt4 modules. Since this behaviour did not

Re: A more specific query ...

2010-02-26 Thread Gib Bogle
The PyQt4 problem results from having copies of the Qt DLLs in directories that are in the PATH, as Doug Bell discovered. In my case I have two programs that use Qt, AMD CodeAnalyst and Matlab. If I rename BOTH these directories I can import the PyQt4 modules. Since this behaviour did not

Re: A more specific query ...

2010-02-26 Thread Gib Bogle
Dennis Lee Bieber wrote: On Sat, 27 Feb 2010 13:00:32 +1300, Gib Bogle g.bo...@auckland.no.spam.ac.nz declaimed the following in gmane.comp.python.general: The PyQt4 problem results from having copies of the Qt DLLs in directories that are in the PATH, as Doug Bell discovered. In my case I

Re: Executable problem - socket?

2010-02-25 Thread Gib Bogle
MRAB wrote: You could try Dependency Walker: http://dependencywalker.com/ I have (belatedly) read the py2exe tutorial: http://www.py2exe.org/index.cgi/Tutorial#Step522 and learned about the msvcr90.dll issue. I haven't finished sorting this out yet, but I did find that running

Re: Problem creating executable, with PyQwt

2010-02-24 Thread Gib Bogle
David Boddie wrote: On Tuesday 23 February 2010 05:32, Gib Bogle wrote: David Boddie wrote: I have previously referred people with py2exe/PyQt issues to this page on the PyQt Wiki: http://www.py2exe.org/index.cgi/Py2exeAndPyQt If you can somehow convince py2exe to include the QtSvg

Re: Files required for porting python

2010-02-24 Thread Gib Bogle
KIRAN wrote: I see lot of code with several files. I had to laugh at this. -- http://mail.python.org/mailman/listinfo/python-list

Executable problem - socket?

2010-02-24 Thread Gib Bogle
Hi, My student has been developing a GUI (using PyQt and PyQwt) that runs a model written in Fortran and built as a DLL. She has to present on this work tomorrow. She makes an executable version of the Python code with py2exe, and the executable runs fine on her Vista laptop and my XP

Re: Executable problem - socket?

2010-02-24 Thread Gib Bogle
MRAB wrote: Gib Bogle wrote: Hi, My student has been developing a GUI (using PyQt and PyQwt) that runs a model written in Fortran and built as a DLL. She has to present on this work tomorrow. She makes an executable version of the Python code with py2exe, and the executable runs fine

Re: Executable problem - correction

2010-02-24 Thread Gib Bogle
The program doesn't fail with the write error on the other XP machine, it actually fails to execute at all, complaining about the configuration information. Therefore I'm seeing different behaviour on three XP machines: Box 1 (SP2): runs OK Box 2 (SP3): fails to start Box 3 (SP3): starts up,

Re: Executable problem - correction

2010-02-24 Thread Gib Bogle
Sean DiZazzo wrote: On Feb 24, 9:22 pm, Gib Bogle g.bo...@auckland.no.spam.ac.nz wrote: The program doesn't fail with the write error on the other XP machine, it actually fails to execute at all, complaining about the configuration information. Therefore I'm seeing different behaviour on three

Re: What's Going on between Python and win7?

2010-02-23 Thread Gib Bogle
chris grebeldinger wrote: Have you tried opening file explorer in administrative mode before performing the copy? I think if there isn't sufficient permissions, it does something weird like that. No -- http://mail.python.org/mailman/listinfo/python-list

Re: Verifying My Troublesome Linkage Claim between Python and Win7

2010-02-23 Thread Gib Bogle
Rick Dooling wrote: No telling what Windows will do. :) It isn't useful to respond to a serious question with OS bigotry. -- http://mail.python.org/mailman/listinfo/python-list

Re: Verifying My Troublesome Linkage Claim between Python and Win7

2010-02-23 Thread Gib Bogle
W. eWatson wrote: On 2/23/2010 8:26 AM, Rick Dooling wrote: No telling what Windows will do. :) I am a mere hobbyist programmer, but I think real programmers will tell you that it is a bad habit to use relative paths. Use absolute paths instead and remove all doubt.

Re: Verifying My Troublesome Linkage Claim between Python and Win7

2010-02-23 Thread Gib Bogle
W. eWatson wrote: On 2/23/2010 11:14 AM, Gib Bogle wrote: W. eWatson wrote: On 2/23/2010 8:26 AM, Rick Dooling wrote: No telling what Windows will do. :) I am a mere hobbyist programmer, but I think real programmers will tell you that it is a bad habit to use relative paths. Use absolute

Re: What's Going on between Python and win7?

2010-02-22 Thread Gib Bogle
MRAB wrote: W. eWatson wrote: Last night I copied a program from folder A to folder B. It inspects the contents of files in a folder. When I ran it in B, it gave the results for A! Out of frustration I changed the name in A, and fired up the program in B. Win7 went into search mode for the

Re: What's Going on between Python and win7?

2010-02-22 Thread Gib Bogle
John Bokma wrote: Gib Bogle g.bo...@auckland.no.spam.ac.nz writes: MRAB wrote: W. eWatson wrote: Last night I copied a program from folder A to folder B. It inspects the contents of files in a folder. When I ran it in B, it gave the results for A! Out of frustration I changed the name

Re: Problem creating executable, with PyQwt

2010-02-22 Thread Gib Bogle
David Boddie wrote: I have previously referred people with py2exe/PyQt issues to this page on the PyQt Wiki: http://www.py2exe.org/index.cgi/Py2exeAndPyQt If you can somehow convince py2exe to include the QtSvg module (and presumably the libQtSvg library as well) then perhaps that will

Problem creating executable, with PyQwt

2010-02-21 Thread Gib Bogle
My student is trying to build an executable version of a program that uses PyQt and PyQwt, on Windows XP. She has installed: Python 2.6.1, Qt 4.5.0, PyQt 4.5, and PyQwt 5.2.0. There is a module error on running the executable produced by py2exe. Here is the info I got from my student:

Re: Problem creating executable, with PyQwt

2010-02-21 Thread Gib Bogle
Thanks David. Someone asked this question on the PyQt mailing list, too: http://www.riverbankcomputing.com/pipermail/pyqt/2010-February/025827.html That's my student, Helvin. I believe it was also asked on the #pyqt IRC channel on freenode. I think I have previously referred people with

Re: Shipping Executables

2010-02-20 Thread Gib Bogle
Steven D'Aprano wrote: On Wed, 17 Feb 2010 02:00:59 -0500, geremy condra quoted Banibrata Dutta banibrata.du...@gmail.com: BTW for people who are non-believers in something being worth stealing needing protection, need to read about the Skype client. Pardon me for breaking threading, but the

Re: Please help with MemoryError

2010-02-12 Thread Gib Bogle
Steven D'Aprano wrote: def swap(a, b): a, b = b, a x = 1 y = 2 swap(x, y) assert (x == 2) and (y==1) Can't the same point be more simply made with this example: def setval(a): a = 12345 x = 1 setval(x) print x ? -- http://mail.python.org/mailman/listinfo/python-list

Re: Python 3 minor irritation

2010-02-04 Thread Gib Bogle
Gabriel Genellina wrote: But the associated program might change the current directory - that's not the case with the default associations created by the Python installer, but one should verify this. To the OP: please create this small test script import os print(curdir=, os.getcwd())

Re: Python 3 minor irritation

2010-02-04 Thread Gib Bogle
Gabriel Genellina wrote: Sorry, I should have removed that line. This is just my setup; a normal Python install doesn't create that registry entry. It allows Desktop Search (or Windows Search, or whatever it is called nowadays; the F3 key) to search inside .py files (default behavior is to

Re: Python's Reference And Internal Model Of Computing Languages

2010-02-02 Thread Gib Bogle
Paul Rubin wrote: Ryan Kelly r...@rfk.id.au writes: I know, I know, do not feed the trolls. But this is just so *wrong* that I can't help myself. See: http://xkcd.com/386/ :-) -- http://mail.python.org/mailman/listinfo/python-list

Re: python 3's adoption

2010-01-28 Thread Gib Bogle
Luis M. González wrote: Please don't post more noise and ad hominem attacks to the group, Steve. Ad hominem? Please, operor non utor lingua non notus per vulgaris populus. Gratias ago vos... ad hominem is lingua notus per vulgaris populus, the vulgar pop of these parts, anyway. --

Re: myths about python 3

2010-01-28 Thread Gib Bogle
Ethan Furman wrote: Steven D'Aprano wrote: 4. Python 3 will make you irresistible to women. FALSE What?!? Drat!!! Guess I'll have to learn Lisp... ;) ~Ethan~ Learn to say this fast, you'll impress the hell out of them: Chaps with chapped lips lisp. --

Re: python 3's adoption

2010-01-27 Thread Gib Bogle
Steven D'Aprano wrote: On Wed, 27 Jan 2010 02:28:00 +0100, Alf P. Steinbach wrote: * Print is now a function. Great, much improvement. Actually not, IMHO. All it does is is to provide incompatibility. They forgot Ronald Reagan's old maxim: if it don't need fixin', don't fix it. The

Re: py2exe and pydocs. Downloads?

2010-01-21 Thread Gib Bogle
Gabriel Genellina wrote: You found a bug. Looks like it depends on the environment, or what packages are installed, or something like that, because it worked on my other PC but not here. Please report it at http://bugs.python.org so it doesn't get forgotten. Done --

Re: py2exe and pydocs. Downloads?

2010-01-21 Thread Gib Bogle
Gabriel Genellina wrote: En Wed, 20 Jan 2010 21:22:19 -0300, Gib Bogle g.bo...@auckland.no.spam.ac.nz escribió: Gabriel Genellina wrote: c:\temppython -m pydoc sys Help on built-in module sys: [...same info...] When I do this I get: No module named tempfile You found a bug. Looks like

[issue7749] pydoc error

2010-01-21 Thread Gib Bogle
New submission from Gib Bogle g.bo...@auckland.ac.nz: python -m pydoc sys gives No module named tempfile -- messages: 98111 nosy: gib severity: normal status: open title: pydoc error type: behavior versions: Python 2.5 ___ Python tracker rep

[issue7749] pydoc error

2010-01-21 Thread Gib Bogle
Gib Bogle g.bo...@auckland.ac.nz added the comment: Hi Eric, I'm using Python 2.5.4 on Windows XP. I installed pythonxy, which installed 2.5.4. I also have PyQt4.4 installed. I haven't touched anything in the lib directory, as far as I know. A poster on comp.lang.python finds the command

[issue7749] pydoc error - No module named tempfile

2010-01-21 Thread Gib Bogle
Gib Bogle g.bo...@auckland.ac.nz added the comment: R. David Murray wrote: R. David Murray rdmur...@bitdance.com added the comment: Under 2.5 this could be due to various weird issues with your python path and the modules on it. Try running python from a clean directory and specifying

[issue7749] pydoc error - No module named tempfile

2010-01-21 Thread Gib Bogle
Gib Bogle g.bo...@auckland.ac.nz added the comment: Importing tempfile from within python does not produce an error. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7749

Re: py2exe and pydocs. Downloads?

2010-01-20 Thread Gib Bogle
Gabriel Genellina wrote: c:\temppython -m pydoc sys Help on built-in module sys: [...same info...] When I do this I get: No module named tempfile -- http://mail.python.org/mailman/listinfo/python-list

Re: syntax

2010-01-19 Thread Gib Bogle
Looks like homework. -- http://mail.python.org/mailman/listinfo/python-list

PyQwt installation

2010-01-18 Thread Gib Bogle
Should there be a problem installing PyQwt5.2.0 with PyQt4.4.4 and Python2.6 on Windows? My student is saying she can't get the Windows installer to work, and she points out that the download site says Binary installation of PyQwt-5.2.0 on Windows for Python-2.6.x, PyQt-4.5.4 --

Re: What is a list compression in Python?

2010-01-18 Thread Gib Bogle
Kit wrote: Thank you so much guys. Just out of curiosity: can I do something like this to square all even numbers in the range 1-10? print [x^2 for x in range (1,11) if x % 2 == 0] Why not try it? -- http://mail.python.org/mailman/listinfo/python-list

Re: ctypes error

2010-01-15 Thread Gib Bogle
Gib Bogle wrote: It has occurred to me that the error may have nothing to do with ctypes. The DLL was built on one machine and copied to the other (which doesn't have the compiler installed). Although both machines are running Windows XP, there might be some subtle differences. I see

ctypes error

2010-01-14 Thread Gib Bogle
I have a simple demo program (on Windows XP) that uses the ctypes module to load a DLL. This program works as expected with Python 2.5.4, but fails with Python 2.6.4 (on a different machine, each machine has only one Python version installed), with these messages: File demo.py, line 37, in

Re: ctypes error

2010-01-14 Thread Gib Bogle
It has occurred to me that the error may have nothing to do with ctypes. The DLL was built on one machine and copied to the other (which doesn't have the compiler installed). Although both machines are running Windows XP, there might be some subtle differences. I see that the build machine

Re: A question about Python versions

2010-01-13 Thread Gib Bogle
Sridhar Ratnakumar wrote: On 1/12/2010 10:09 PM, Gib Bogle wrote: I am learning Python, and using PyQt to develop a GUI that will be used to run a Fortran program on Windows, Linux and Mac OS X (I think Python is great, btw). Without thinking about it I downloaded and started working

Re: A question about Python versions

2010-01-13 Thread Gib Bogle
Terry Reedy wrote: On 1/13/2010 1:09 AM, Gib Bogle wrote: I am learning Python, and using PyQt to develop a GUI that will be used to run a Fortran program on Windows, Linux and Mac OS X (I think Python is great, btw). Without thinking about it I downloaded and started working with a fairly

A question about Python versions

2010-01-12 Thread Gib Bogle
I am learning Python, and using PyQt to develop a GUI that will be used to run a Fortran program on Windows, Linux and Mac OS X (I think Python is great, btw). Without thinking about it I downloaded and started working with a fairly recent Python version, 2.5.4. I've now become aware of the

Threading change, 2.5.4 - 2.6.1

2010-01-07 Thread Gib Bogle
The code below runs with Python 2.5.4, but gives the following error messages with Python 2.6.1. What needs to be done to make it work? Thanks. C:\Summer09\Tutorialspython url_queue.pyw Traceback (most recent call last): File url_queue.pyw, line 3, in module import threading File

Re: Threading change, 2.5.4 - 2.6.1

2010-01-07 Thread Gib Bogle
MRAB wrote: Gib Bogle wrote: The code below runs with Python 2.5.4, but gives the following error messages with Python 2.6.1. What needs to be done to make it work? Thanks. C:\Summer09\Tutorialspython url_queue.pyw Traceback (most recent call last): File url_queue.pyw, line 3, in module

A null program - what is it doing?

2010-01-05 Thread Gib Bogle
No doubt a dumb question from a noob: The following program (a cut down version of some test code) uses no CPU, and does not terminate: import sys from PyQt4.QtCore import * if __name__==__main__: app = QCoreApplication(sys.argv) sys.exit(app.exec_()) What is the program doing?

Re: A null program - what is it doing?

2010-01-05 Thread Gib Bogle
r0g wrote: Gib Bogle wrote: No doubt a dumb question from a noob: The following program (a cut down version of some test code) uses no CPU, and does not terminate: import sys from PyQt4.QtCore import * if __name__==__main__: app = QCoreApplication(sys.argv) sys.exit(app.exec_

Re: Threading with queues

2009-12-23 Thread Gib Bogle
Lie Ryan wrote: On 12/22/2009 10:47 AM, Gib Bogle wrote: This is indented over one indentation level too much. You want it to be at the same level as the for above. Here, its at the same level with t -- meaning this entire loop gets repeated five times. I sorta really recommend a tab width

Threading with queues

2009-12-21 Thread Gib Bogle
Hi, I'm learning Python, jumping in the deep end with a threading application. I came across an authoritative-looking site that recommends using queues for threading in Python. http://www.ibm.com/developerworks/aix/library/au-threadingpython/index.html The author provides example code that

Re: numpy performance and random numbers

2009-12-21 Thread Gib Bogle
sturlamolden wrote: On 19 Des, 14:06, Carl Johan Rehn car...@gmail.com wrote: Matlab and numpy have (by chance?) the exact names for the same functionality, Common ancenstry, NumPy and Matlab borrowed the name from IDL. LabView, Octave and SciLab uses the name randn as well. So the

Re: numpy performance and random numbers

2009-12-21 Thread Gib Bogle
sturlamolden wrote: On 19 Des, 16:20, Carl Johan Rehn car...@gmail.com wrote: How about mulit-core or (perhaps more exciting) GPU and CUDA? I must admit that I am extremely interested in trying the CUDA-alternative. Obviously, cuBLAS is not an option here, so what is the safest route for a

Re: numpy performance and random numbers

2009-12-21 Thread Gib Bogle
sturlamolden wrote: On 19 Des, 22:58, sturlamolden sturlamol...@yahoo.no wrote: If you pick two random states (using any PRNG), you need error- checking that states are always unique, i.e. that each PRNG never reaches the starting state of the other(s). Another note on this: Ideally, we

Re: Using Python to Execute a C or FORTRAN Program (Windows)

2009-12-21 Thread Gib Bogle
W. eWatson wrote: Mensanator wrote: On Dec 14, 8:14�pm, W. eWatson wolftra...@invalid.com wrote: I think Python is capable of executing a compiled C or FORTRAN program, Sure, if it was compiled to an .exe file. and maybe even getting some parameters passed back. Sure, if the program

Re: Threading with queues

2009-12-21 Thread Gib Bogle
Stephen Hansen wrote: On Mon, Dec 21, 2009 at 3:12 PM, Gib Bogle g.bo...@auckland.no.spam.ac.nz wrote: #spawn a pool of threads, and pass them queue instance for i in range(5): t = ThreadUrl(queue,i) t.setDaemon(True) t.start() #populate queue with data for host in hosts

Re: Threading with queues

2009-12-21 Thread Gib Bogle
Stephen Hansen wrote: On Mon, Dec 21, 2009 at 3:12 PM, Gib Bogle g.bo...@auckland.no.spam.ac.nz wrote: #spawn a pool of threads, and pass them queue instance for i in range(5): t = ThreadUrl(queue,i) t.setDaemon(True) t.start() #populate queue with data for host in hosts

Re: numpy performance and random numbers

2009-12-21 Thread Gib Bogle
David Cournapeau wrote: On Sun, Dec 20, 2009 at 6:47 PM, Lie Ryan lie.1...@gmail.com wrote: On 12/20/2009 2:53 PM, sturlamolden wrote: On 20 Des, 01:46, Lie Ryanlie.1...@gmail.com wrote: Not necessarily, you only need to be certain that the two streams don't overlap in any reasonable amount

Re: BUSTED!!! 100% VIDEO EVIDENCE that WTC7 was controlled demolition!! NEW FOOTAGE!!! Ask yourself WHY havn't I seen this footage before?

2007-05-03 Thread Gib Bogle
Ah, so the firefighters were in on the conspiracy! -- http://mail.python.org/mailman/listinfo/python-list

Re: Video: Professor of Physics Phd at Cal Tech says: 911 Inside Job

2007-04-24 Thread Gib Bogle
[EMAIL PROTECTED] wrote: Cal Tech is the ELITE of ELITE in physics. If Feynman were alive, he would point his finger straight at the 911 criminal operators, the yank bastards themselves ... http://www.911blogger.com/node/8101 No self-respecting scientist should keep his mouth shut.