Re: [NUMPY] "ValueError: total size of new array must be unchanged" just on Windows

2011-10-09 Thread Nobody
On Sun, 09 Oct 2011 13:59:11 -0700, Paolo Zaffino wrote: > I wrote a function that works on a numpy matrix and it works fine on > Mac OS and GNU/Linux (I didn't test it on python 3) > Now I have a problem with numpy: the same python file doesn't work on > Windows (Windows xp, python 2.7 and numpy

Re: A tuple in order to pass returned values ?

2011-10-09 Thread Roy Smith
In article , alex23 wrote: > For anything else I'd use [...] bunch. Particularly useful for handing over lupins. -- http://mail.python.org/mailman/listinfo/python-list

Re: A tuple in order to pass returned values ?

2011-10-09 Thread alex23
Jean-Michel Pichavant wrote: > However, I'm not sure it fixes the main issue: unpacking. Unpacking > prevents you from adding any additional fields to your 'tuple' without > breaking any line of code that was unpacking the tuple (to oppose to > accessing an object attribute). Generally, if it's a

Re: [NUMPY] "ValueError: total size of new array must be unchanged" just on Windows

2011-10-09 Thread Steven D'Aprano
Paolo Zaffino wrote: > Hello, > I wrote a function that works on a numpy matrix and it works fine on > Mac OS and GNU/Linux (I didn't test it on python 3) > Now I have a problem with numpy: the same python file doesn't work on > Windows (Windows xp, python 2.7 and numpy 2.6.1). > I get this error:

Re: [NUMPY] "ValueError: total size of new array must be unchanged" just on Windows

2011-10-09 Thread Yaşar Arabacı
I don't know about your problem, but did you compare numpy versions in windows and other platforms? You may have newer/older version in Windows. Otherwise, it looks like a platform spesific bug to me. 2011/10/9 Paolo Zaffino > Hello, > I wrote a function that works on a numpy matrix and it works

[NUMPY] "ValueError: total size of new array must be unchanged" just on Windows

2011-10-09 Thread Paolo Zaffino
Hello, I wrote a function that works on a numpy matrix and it works fine on Mac OS and GNU/Linux (I didn't test it on python 3) Now I have a problem with numpy: the same python file doesn't work on Windows (Windows xp, python 2.7 and numpy 2.6.1). I get this error: matrix=matrix.reshape(a, b, c) V

Re: Is it possible to create C-style "main" function in Python? (for teaching purposes)

2011-10-09 Thread 88888 dihedral
I do not think C is not good for functional programming, but C is hard to debug if one has to write programs to reload functional pointers and data structures that will grow in the run time for the possible cases. Thus, I love Python! -- http://mail.python.org/mailman/listinfo/python-list

Re: Usefulness of the "not in" operator

2011-10-09 Thread Westley Martínez
On Sat, Oct 08, 2011 at 12:34:42PM -0400, Roy Smith wrote: > In article <4e906108$0$27980$426a3...@news.free.fr>, > candide wrote: > > > After browsing source code, I realize that parenthesis are not necessary > > ("not" has higher precedence than "in"). > > Here's my take on parenthesis: If

Amber riley - Mercedes

2011-10-09 Thread cry angel
New page for the singer Amber riley - Mercedes I wish to enter and enjoy and leave comments http://sunforsun.blogspot.com/p/amber-riley-mercedes.html -- http://mail.python.org/mailman/listinfo/python-list

Re: Thread handling issue

2011-10-09 Thread 88888 dihedral
TRY to get BOA with wxpython! Please check the example for the UI part in BOA. -- http://mail.python.org/mailman/listinfo/python-list

Re: DRY functions with named attributes used as default arguments

2011-10-09 Thread Tim Chase
On 10/09/11 10:37, Steven D'Aprano wrote: My intent is to have a function object something like def foo(arg1, arg2=foo.DEFAULT): return int(do_stuff(arg1, arg2)) foo.SPECIAL = 42 foo.MONKEY = 31415 foo.DEFAULT = foo.SPECIAL What's the purpose of having both foo.SPECIAL an

Re: Using Python xmlrpclib to build XMLRPC clients for a server with variable RPC names

2011-10-09 Thread JPC
That was the information I was missing many thanks. For the reference sake, a look through the source code indicates this solution; prior to your message I just didn't understand it that well. -- /jpc On Sun, 2011-10-09 at 11:00 -0700, Chris Rebert wrote: > On Sun, Oct 9, 2011 at 6:30 AM, John

Re: Using Python xmlrpclib to build XMLRPC clients for a server with variable RPC names

2011-10-09 Thread Chris Rebert
On Sun, Oct 9, 2011 at 6:30 AM, John P. Crackett wrote: > I need to write prototype XMLRPC clients using xmlrpclib for a server > that has variable RPC names and I'd like to use Python as the > prototyping tool.  I've searched but can't find any relevant advice > online.  Any pointers would be gra

Re: Usefulness of the "not in" operator

2011-10-09 Thread Albert van der Horst
In article , Jussi Piitulainen wrote: >Mel writes: > >> Steven D'Aprano wrote: >> >> > candide wrote: >> > >> >> So what is the usefulness of the "not in" operator ? Recall what Zen of >> >> Python tells >> >> >> >> There should be one-- and preferably only one --obvious way to do it. >> > >> > A

Re: "IX" as shorthand for "Interface"

2011-10-09 Thread D'Arcy J.M. Cain
On Sat, 8 Oct 2011 22:21:02 -0600 Eric Snow wrote: > I'm writing a bunch of classes that have "Interface" in the name and > find that the length of the subsequent names is starting to get in the > way of readability (I don't really care about saving keystrokes). Is > "IX" conventional enough to u

SciPy/NumPy: read, write images using Python3

2011-10-09 Thread thegripper
In SciPy / NumPy, the primary way to read and write images is PIL. But PIL does not yet support Python3. Is there some good way to read, write, and resize images in a NumPy and Python3 environment? -- http://mail.python.org/mailman/listinfo/python-list

SciPy/NumPy: read, write images using Python3

2011-10-09 Thread thegripper
In SciPy / NumPy, the primary way to read and write images is PIL. But PIL does not yet support Python3. Is there some good way to read, write, and resize images in a NumPy and Python3 environment? -- http://mail.python.org/mailman/listinfo/python-list

Re: Benefit and belief

2011-10-09 Thread Albert van der Horst
In article , DevPlayer wrote: >I still assert that contradiction is caused by narrow perspective. > >By that I mean: just because an objects scope may not see a certain >condition, doesn't mean that condition is non-existant. > >I also propose that just because something seems to contradict doesn

Re: DRY functions with named attributes used as default arguments

2011-10-09 Thread Steven D'Aprano
Tim Chase wrote: > My intent is to have a function object something like > >def foo(arg1, arg2=foo.DEFAULT): > return int(do_stuff(arg1, arg2)) >foo.SPECIAL = 42 >foo.MONKEY = 31415 >foo.DEFAULT = foo.SPECIAL What's the purpose of having both foo.SPECIAL and foo.DEFAULT? Yo

Re: "IX" as shorthand for "Interface"

2011-10-09 Thread Peter Otten
Roy Smith wrote: > In article , > Eric Snow wrote: > >> I saw what you did right there!Be that as it may, is "IX" a >> common enough abbreviation? What Roy really wanted to say: I w3d n1t r7e it at f3t g4e. If a6g, I t3k of X as s6g f1r e8e (UI -- U2r I7e, UX -- U2r E8e). B1t, if it's a

Re: "IX" as shorthand for "Interface"

2011-10-09 Thread Roy Smith
In article , Eric Snow wrote: > I saw what you did right there!Be that as it may, is "IX" a > common enough abbreviation? I would not recognize it at first glance. If anything, I think of X as standing for experience (UI -- User Interface, UX -- User Experience). But, if it's a big pack

Using Python xmlrpclib to build XMLRPC clients for a server with variable RPC names

2011-10-09 Thread John P. Crackett
I need to write prototype XMLRPC clients using xmlrpclib for a server that has variable RPC names and I'd like to use Python as the prototyping tool. I've searched but can't find any relevant advice online. Any pointers would be gratefully received; details follow. The server in question constru

Re: DRY functions with named attributes used as default arguments

2011-10-09 Thread Arnaud Delobelle
On 9 October 2011 13:20, Tim Chase wrote: > My intent is to have a function object something like > >  def foo(arg1, arg2=foo.DEFAULT): >    return int(do_stuff(arg1, arg2)) >  foo.SPECIAL = 42 >  foo.MONKEY = 31415 >  foo.DEFAULT = foo.SPECIAL > > so I can call it with either > >  result = foo(my

DRY functions with named attributes used as default arguments

2011-10-09 Thread Tim Chase
My intent is to have a function object something like def foo(arg1, arg2=foo.DEFAULT): return int(do_stuff(arg1, arg2)) foo.SPECIAL = 42 foo.MONKEY = 31415 foo.DEFAULT = foo.SPECIAL so I can call it with either result = foo(myarg) or result = foo(myarg, foo.SPECIAL) However I

Re: "IX" as shorthand for "Interface"

2011-10-09 Thread Nobody
On Sat, 08 Oct 2011 22:21:02 -0600, Eric Snow wrote: > I'm writing a bunch of classes that have "Interface" in the name and > find that the length of the subsequent names is starting to get in the > way of readability (I don't really care about saving keystrokes). Is > "IX" conventional enough to

vdfgdfg

2011-10-09 Thread vishwa nathan
http://123maza.com/65/white725/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Thread handling issue

2011-10-09 Thread Tim Golden
On 08/10/2011 11:51, Paul wrote: I think I'll wait for the user to actually make a change after cancelling the output selection, in case they go straight back without making changes. If they make a change I think I'll try what you suggested and send off a new thread, and send an event to the prev

Re: Working with spreadsheet files

2011-10-09 Thread Tim Golden
On 09/10/2011 07:30, Yaşar Arabacı wrote: Does anyone know a good tutorial about working with Spreadsheet files (e.g. excel files) with Python. I have found xlutils, but there doesn't seem to be any documentation or tutorial about it that I could find. So, any suggestions? http://www.python-exc

Re: "IX" as shorthand for "Interface"

2011-10-09 Thread Steven D'Aprano
Eric Snow wrote: > I'm writing a bunch of classes that have "Interface" in the name and > find that the length of the subsequent names is starting to get in the > way of readability (I don't really care about saving keystrokes). Is > "IX" conventional enough to use in place of "Interface" in a cl