Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Mark Lawrence
On 16/05/2015 05:28, Terry Reedy wrote: On 5/16/2015 12:12 AM, Mark Lawrence wrote: The whole point is that setup.py never works because it can't find VS despite the fact that I know I've got the correct version installed. If I download a whl file, pip installs that version perfectly. If I try

How to deploy a custom common module?

2015-05-15 Thread zljubisicmob
While working on one python script (test.py), I developed some functions that I will probably need in my future projects, so I decided to put such functions in another python file (cmn_funcs.py). So in my test.py there is import cmn_funcs in order to use common functions and everything works we

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Terry Reedy
On 5/16/2015 12:12 AM, Mark Lawrence wrote: The whole point is that setup.py never works because it can't find VS despite the fact that I know I've got the correct version installed. If I download a whl file, pip installs that version perfectly. If I try to get pip to download and install the v

Re: Instead of deciding between Python or Lisp for a programming intro course...What about an intro course that uses *BOTH*? Good idea?

2015-05-15 Thread zipher
On Friday, May 15, 2015 at 10:36:45 PM UTC-5, Rustom Mody wrote: > On Saturday, May 16, 2015 at 8:56:00 AM UTC+5:30, zipher wrote: > > On Wednesday, May 13, 2015 at 9:36:27 PM UTC-5, Mark Lawrence wrote: > > > On 14/05/2015 02:40, Steven D'Aprano wrote: > > > > On Thu, 14 May 2015 04:07 am, zipher

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Mark Lawrence
On 16/05/2015 03:17, Chris Angelico wrote: On Sat, May 16, 2015 at 11:58 AM, Mark Lawrence wrote: The way I see it, pip is great for handling the most common case where you just want to name a package and say "go fetch", but if you want to override its decisions, you should use the lower-level

Re: Minimising stack trace

2015-05-15 Thread Mark Lawrence
On 16/05/2015 03:51, Rustom Mody wrote: On Saturday, May 16, 2015 at 6:54:23 AM UTC+5:30, Ned Batchelder wrote: On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: Cecil Westerhof wrote: While playing with recurs

Re: Instead of deciding between Python or Lisp for a programming intro course...What about an intro course that uses *BOTH*? Good idea?

2015-05-15 Thread Rustom Mody
On Saturday, May 16, 2015 at 8:56:00 AM UTC+5:30, zipher wrote: > On Wednesday, May 13, 2015 at 9:36:27 PM UTC-5, Mark Lawrence wrote: > > On 14/05/2015 02:40, Steven D'Aprano wrote: > > > On Thu, 14 May 2015 04:07 am, zipher wrote: > > > > > >> > > >> No, you haven't understood, padawan. Lambda *

Re: Instead of deciding between Python or Lisp for a programming intro course...What about an intro course that uses *BOTH*? Good idea?

2015-05-15 Thread zipher
On Wednesday, May 13, 2015 at 9:36:27 PM UTC-5, Mark Lawrence wrote: > On 14/05/2015 02:40, Steven D'Aprano wrote: > > On Thu, 14 May 2015 04:07 am, zipher wrote: > > > >> > >> No, you haven't understood, padawan. Lambda *is* the function, not it's > >> definition. Perhaps you will understand wha

Re: Minimising stack trace

2015-05-15 Thread Rustom Mody
On Saturday, May 16, 2015 at 8:22:05 AM UTC+5:30, Rustom Mody wrote: > On Saturday, May 16, 2015 at 6:54:23 AM UTC+5:30, Ned Batchelder wrote: > > On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: > > > On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: > > > > > > >

Re: Minimising stack trace

2015-05-15 Thread Rustom Mody
On Saturday, May 16, 2015 at 6:54:23 AM UTC+5:30, Ned Batchelder wrote: > On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: > > On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: > > > > > Cecil Westerhof wrote: > > > > > >> While playing with recursion I get: > > >>

Re: Building CPython

2015-05-15 Thread Mark Lawrence
On 16/05/2015 02:55, Steven D'Aprano wrote: On Sat, 16 May 2015 09:27 am, Mark Lawrence wrote: On 15/05/2015 23:44, Marko Rauhamaa wrote: BartC : What /is/ a method lookup? Is it when you have this: A.B() and need to find whether the expression A (or its class or type) has a name B asso

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 11:58 AM, Mark Lawrence wrote: >> The way I see it, pip is great for handling the most common case where >> you just want to name a package and say "go fetch", but if you want to >> override its decisions, you should use the lower-level facilities eg >> manual downloading a

Re: Building CPython

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 11:55 AM, Steven D'Aprano wrote: > but in Python's case it has to be resolved at run-time, so if you care about > speed, you should try to avoid long chains of dots in performance critical > loops. E.g. instead of: > > for x in sequence: > foo.bar.baz.foobar.spa

Re: Building CPython

2015-05-15 Thread Steven D'Aprano
On Sat, 16 May 2015 09:27 am, Mark Lawrence wrote: > On 15/05/2015 23:44, Marko Rauhamaa wrote: >> BartC : >> >>> What /is/ a method lookup? Is it when you have this: >>> >>> A.B() >>> >>> and need to find whether the expression A (or its class or type) has a >>> name B associated with it? (And

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Mark Lawrence
On 16/05/2015 02:26, Chris Angelico wrote: On Sat, May 16, 2015 at 7:00 AM, Mark Lawrence wrote: The same file installed perfectly when downloaded and installed in two steps. Whether this is simply a known bug with zipfile handling, pip itself, a combination of both or what I've no idea. I fi

Re: Minimising stack trace

2015-05-15 Thread Ned Batchelder
On Friday, May 15, 2015 at 9:33:54 PM UTC-4, Chris Angelico wrote: > On Sat, May 16, 2015 at 11:24 AM, Ned Batchelder > wrote: > > On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: > >> On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: > >> > >> > Cecil Westerhof wr

Re: Minimising stack trace

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 11:24 AM, Ned Batchelder wrote: > On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: >> On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: >> >> > Cecil Westerhof wrote: >> > >> >> While playing with recursion I get: >> >> RuntimeError: maxi

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 7:00 AM, Mark Lawrence wrote: > The same file installed perfectly when downloaded and installed in two > steps. Whether this is simply a known bug with zipfile handling, pip > itself, a combination of both or what I've no idea. > > I find it slightly irritating that a tool

Re: Minimising stack trace

2015-05-15 Thread Ned Batchelder
On Friday, May 15, 2015 at 8:57:53 PM UTC-4, Steven D'Aprano wrote: > On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: > > > Cecil Westerhof wrote: > > > >> While playing with recursion I get: > >> RuntimeError: maximum recursion depth exceeded in comparison > >> > >> But then

Re: Building CPython

2015-05-15 Thread MRAB
On 2015-05-16 01:43, BartC wrote: On 15/05/2015 23:44, Marko Rauhamaa wrote: BartC : What /is/ a method lookup? Is it when you have this: A.B() and need to find whether the expression A (or its class or type) has a name B associated with it? (And it then needs to check whether B is somethi

Re: Minimising stack trace

2015-05-15 Thread Steven D'Aprano
On Sat, 16 May 2015 05:41 am, Thomas 'PointedEars' Lahn wrote: > Cecil Westerhof wrote: > >> While playing with recursion I get: >> RuntimeError: maximum recursion depth exceeded in comparison >> >> But then I get a very long stack trace. Is there a way to make this a >> lot shorter. Now I ‘

Re: Building CPython

2015-05-15 Thread Gregory Ewing
BartC wrote: For example, there is a /specific/ byte-code called BINARY_ADD, which then proceeds to call a /generic/ binary-op handler! This throws away the advantage of knowing at byte-code generation time exactly which operation is needed. While inlining the binary-op handling might give yo

Re: Building CPython

2015-05-15 Thread BartC
On 15/05/2015 23:44, Marko Rauhamaa wrote: BartC : What /is/ a method lookup? Is it when you have this: A.B() and need to find whether the expression A (or its class or type) has a name B associated with it? (And it then needs to check whether B is something that can be called.) If so, doe

Re: Python: How to find out values of all feasible x under constraints.

2015-05-15 Thread Mark Lawrence
On 15/05/2015 13:35, Mark Lawrence wrote: On 15/05/2015 04:58, Xiang Zhang wrote: Dear all, I am writing a code using Python now. I want to know how to find out values of all feasible x under constraints. x = [x_1, x_2, x_3,..., x_10] constraints: x_i = 0,1,2,3 or 4, where i=1,2,..

Re: Survey -- Move To Trash function in Python?

2015-05-15 Thread sohcahtoa82
On Friday, May 15, 2015 at 11:27:18 AM UTC-7, rand...@fastmail.us wrote: > On Fri, May 15, 2015, at 00:25, Chris Angelico wrote: > > The main thing is that trashing invites the system to delete the file > > at its leisure, > > I've never seen a system whose trash can emptied itself without user >

Re: Building CPython

2015-05-15 Thread Terry Reedy
On 5/15/2015 5:54 PM, BartC wrote: What /is/ a method lookup? Is it when you have this: A.B() This is parsed as (A.B)() and need to find whether the expression A (or its class or type) has a name B associated with it? Yes. Dotted names imply an attribute lookup. (And it then needs to

Re: Building CPython

2015-05-15 Thread Mark Lawrence
On 15/05/2015 23:44, Marko Rauhamaa wrote: BartC : What /is/ a method lookup? Is it when you have this: A.B() and need to find whether the expression A (or its class or type) has a name B associated with it? (And it then needs to check whether B is something that can be called.) If so, doe

Re: Building CPython

2015-05-15 Thread Marko Rauhamaa
BartC : > What /is/ a method lookup? Is it when you have this: > > A.B() > > and need to find whether the expression A (or its class or type) has a > name B associated with it? (And it then needs to check whether B is > something that can be called.) > > If so, does that have to be done using Pyt

نتيجة الشهادة الابتدائية 2015 الترم الثانى

2015-05-15 Thread شيسبس
نتيجة الشهادة الابتدائية 2015 الترم الثانى https://plus.google.com/u/0/106736449589858805776 https://www.facebook.com/pages/%D9%86%D8%AA%D8%A7%D8%A6%D8%AC-%D8%A7%D9%84%D8%A7%D9%85%D8%AA%D8%AD%D8%A7%D9%86%D8%A7%D8%AA-%D9%88%D8%A7%D9%84%D8%AC%D8%A7%D9%85%D8%B9%D8%A7%D8%AA-%D9%88%D8%A7%D8%AC%D8%AA%

Re: Building CPython

2015-05-15 Thread BartC
On 15/05/2015 09:59, Marko Rauhamaa wrote: The path from decoding a bytecode to the C code that implements it can be rather convoluted, but there are reasons for each of the complications -- mainly to do with supporting the ability to override operators with C and/or Python code. If you removed

Re: Building CPython

2015-05-15 Thread Terry Reedy
On 5/15/2015 6:51 AM, Christian Gollwitzer wrote: Am 14.05.15 um 20:50 schrieb Terry Reedy: On 5/14/2015 1:11 PM, Chris Angelico wrote: 2) make test - run the entire test suite. Takes just as long every time, but most of it won't have changed. The test runner has an option, -jn, to run tests

Re: Building CPython

2015-05-15 Thread Terry Reedy
On 5/15/2015 4:59 AM, Marko Rauhamaa wrote: Must a method lookup necessarily involve object creation? Where is matters, inside loops, method lookup can be avoided after doing it once. for i in range(100): ob.meth(i) versus meth = ob.meth for i in range(100): meth(i) For working wi

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Mark Lawrence
On 15/05/2015 19:55, Chris Angelico wrote: On Sat, May 16, 2015 at 4:45 AM, Ethan Furman wrote: On 05/15/2015 06:04 AM, Mark Lawrence wrote: C:\Users\Mark\Documents\MyPython>pip install --no-cache-dir --trusted-host http://www.lfd.uci.edu/ -U -f http://www.lfd.uci.edu/~gohlke/pythonlibs/ numb

Re: Minimising stack trace

2015-05-15 Thread Thomas 'PointedEars' Lahn
Cecil Westerhof wrote: > While playing with recursion I get: > RuntimeError: maximum recursion depth exceeded in comparison > > But then I get a very long stack trace. Is there a way to make this a > lot shorter. Now I ‘lose’ interesting information because of the length of > the stack trace

Re: Minimising stack trace

2015-05-15 Thread Skip Montanaro
A third alternative is to take a look at asyncore.compact_traceback. That will only help modestly in Cecil's example, but I found it helpful. Skip On Fri, May 15, 2015 at 2:04 PM, Ned Batchelder wrote: > On Friday, May 15, 2015 at 2:50:12 PM UTC-4, Cecil Westerhof wrote: >> While playing with re

Re: Minimising stack trace

2015-05-15 Thread Ned Batchelder
On Friday, May 15, 2015 at 2:50:12 PM UTC-4, Cecil Westerhof wrote: > While playing with recursion I get: > RuntimeError: maximum recursion depth exceeded in comparison > > But then I get a very long stack trace. Is there a way to make this a > lot shorter. Now I 'lose' interesting information

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 4:45 AM, Ethan Furman wrote: > On 05/15/2015 06:04 AM, Mark Lawrence wrote: > >> C:\Users\Mark\Documents\MyPython>pip install --no-cache-dir >> --trusted-host http://www.lfd.uci.edu/ -U -f >> http://www.lfd.uci.edu/~gohlke/pythonlibs/ numba > >> >> >> Collecting numba >>

Minimising stack trace

2015-05-15 Thread Cecil Westerhof
While playing with recursion I get: RuntimeError: maximum recursion depth exceeded in comparison But then I get a very long stack trace. Is there a way to make this a lot shorter. Now I ‘lose’ interesting information because of the length of the stack trace. -- Cecil Westerhof Senior Softwar

Re: pip grabs tar.gz file instead of whl?

2015-05-15 Thread Ethan Furman
On 05/15/2015 06:04 AM, Mark Lawrence wrote: C:\Users\Mark\Documents\MyPython>pip install --no-cache-dir --trusted-host http://www.lfd.uci.edu/ -U -f http://www.lfd.uci.edu/~gohlke/pythonlibs/ numba > Collecting numba This repository located at www.lfd.uci.edu is not a trusted host, if this

Re: Survey -- Move To Trash function in Python?

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 4:27 AM, wrote: > On Fri, May 15, 2015, at 00:25, Chris Angelico wrote: >> The main thing is that trashing invites the system to delete the file >> at its leisure, > > I've never seen a system whose trash can emptied itself without user > intervention. They always grow to

Re: Survey -- Move To Trash function in Python?

2015-05-15 Thread random832
On Fri, May 15, 2015, at 00:25, Chris Angelico wrote: > The main thing is that trashing invites the system to delete the file > at its leisure, I've never seen a system whose trash can emptied itself without user intervention. -- https://mail.python.org/mailman/listinfo/python-list

Re: Trying to build Python

2015-05-15 Thread Ned Batchelder
On Friday, May 15, 2015 at 10:40:14 AM UTC-4, Cecil Westerhof wrote: > Op Friday 15 May 2015 13:16 CEST schreef Chris Angelico: > > > On Fri, May 15, 2015 at 9:02 PM, Rustom Mody wrote: > >> On Friday, May 15, 2015 at 4:28:13 PM UTC+5:30, Cecil Westerhof wrote: > >>> I am trying to build Python 3

Re: Building CPython

2015-05-15 Thread Chris Angelico
On Sat, May 16, 2015 at 1:00 AM, Ian Kelly wrote: > On Fri, May 15, 2015 at 6:43 AM, Steven D'Aprano > wrote: >> How much time would it save? Probably very little. After all, unless the >> method call itself did bugger-all work, the time to create the method >> object is probably insignificant. B

Re: Building CPython

2015-05-15 Thread Ian Kelly
On Fri, May 15, 2015 at 9:00 AM, Ian Kelly wrote: > On Fri, May 15, 2015 at 6:43 AM, Steven D'Aprano > wrote: >> How much time would it save? Probably very little. After all, unless the >> method call itself did bugger-all work, the time to create the method >> object is probably insignificant. B

Re: Building CPython

2015-05-15 Thread Ian Kelly
On Fri, May 15, 2015 at 6:43 AM, Steven D'Aprano wrote: > How much time would it save? Probably very little. After all, unless the > method call itself did bugger-all work, the time to create the method > object is probably insignificant. But it's a possible optimization. An interesting alternati

Re: Trying to build Python

2015-05-15 Thread Cecil Westerhof
Op Friday 15 May 2015 13:16 CEST schreef Chris Angelico: > On Fri, May 15, 2015 at 9:02 PM, Rustom Mody wrote: >> On Friday, May 15, 2015 at 4:28:13 PM UTC+5:30, Cecil Westerhof wrote: >>> I am trying to build Python 3 on a Debian system. It is >>> successful, but a few things where missing. Part

pip grabs tar.gz file instead of whl?

2015-05-15 Thread Mark Lawrence
I was fed up with trying to install from pypi to Windows. Setup.py more often than not wouldn't be able to find the VS compiler. So I thought I'd try the direct route to the excellent Christoph Gohlke site at http://www.lfd.uci.edu/~gohlke/pythonlibs/ which is all whl files these days. Howeve

Re: Building CPython

2015-05-15 Thread Mark Lawrence
On 15/05/2015 11:52, Marko Rauhamaa wrote: wxjmfa...@gmail.com: Le vendredi 15 mai 2015 11:20:25 UTC+2, Marko Rauhamaa a écrit : wxjmfa...@gmail.com: Implement unicode correctly. Did they reject your patch? You can not patch something that is wrong by design. Are you saying the Python l

Re: Building CPython

2015-05-15 Thread Steven D'Aprano
On Fri, 15 May 2015 08:50 pm, Marko Rauhamaa wrote: > Chris Angelico : > >> On Fri, May 15, 2015 at 6:59 PM, Marko Rauhamaa wrote: >>> Must a method lookup necessarily involve object creation? >> >> Actually, no. >> [...] >> a particular Python implementation is most welcome to notice the >> ext

Re: Building CPython

2015-05-15 Thread Mark Lawrence
On 15/05/2015 10:20, Marko Rauhamaa wrote: wxjmfa...@gmail.com: Implement unicode correctly. Did they reject your patch? Marko Please don't feed him, it's been obvious for years that he hasn't the faintest idea what he's talking about. -- My fellow Pythonistas, ask not what our languag

Re: Python: How to find out values of all feasible x under constraints.

2015-05-15 Thread Mark Lawrence
On 15/05/2015 04:58, Xiang Zhang wrote: Dear all, I am writing a code using Python now. I want to know how to find out values of all feasible x under constraints. x = [x_1, x_2, x_3,..., x_10] constraints: x_i = 0,1,2,3 or 4, where i=1,2,10 x_1 + x_2 + x_3 +...+x_10 <= 15 How t

Re: Building CPython

2015-05-15 Thread Chris Angelico
On Fri, May 15, 2015 at 10:10 PM, Steven D'Aprano wrote: > The benefit of this is that most strings will use 1/2 or 1/4 of the memory > that they otherwise would need, which gives an impressive memory saving. > That leads to demonstrable speed-ups in real-world code, however it is > possible to fi

Re: Building CPython

2015-05-15 Thread Steven D'Aprano
On Fri, 15 May 2015 08:52 pm, Marko Rauhamaa wrote: > wxjmfa...@gmail.com: > >> Le vendredi 15 mai 2015 11:20:25 UTC+2, Marko Rauhamaa a écrit : >>> wxjmfa...@gmail.com: >>> >>> > Implement unicode correctly. >>> Did they reject your patch? >> >> You can not patch something that is wrong by desi

Re: Trying to build Python

2015-05-15 Thread Chris Angelico
On Fri, May 15, 2015 at 9:02 PM, Rustom Mody wrote: > On Friday, May 15, 2015 at 4:28:13 PM UTC+5:30, Cecil Westerhof wrote: >> I am trying to build Python 3 on a Debian system. It is successful, >> but a few things where missing. Partly I solved it, but a few things >> keep unresolved: >> _bz

Re: Trying to build Python

2015-05-15 Thread Rustom Mody
On Friday, May 15, 2015 at 4:28:13 PM UTC+5:30, Cecil Westerhof wrote: > I am trying to build Python 3 on a Debian system. It is successful, > but a few things where missing. Partly I solved it, but a few things > keep unresolved: > _bz2 > _sqlite3 > readline > _dbm > _ssl >

Trying to build Python

2015-05-15 Thread Cecil Westerhof
I am trying to build Python 3 on a Debian system. It is successful, but a few things where missing. Partly I solved it, but a few things keep unresolved: _bz2 _sqlite3 readline _dbm _ssl _gdbm What do I need to do to get those resolved also? -- Cecil Westerhof Senior Soft

Re: Building CPython

2015-05-15 Thread Marko Rauhamaa
wxjmfa...@gmail.com: > Le vendredi 15 mai 2015 11:20:25 UTC+2, Marko Rauhamaa a écrit : >> wxjmfa...@gmail.com: >> >> > Implement unicode correctly. >> Did they reject your patch? > > You can not patch something that is wrong by design. Are you saying the Python language spec is unfixable or tha

Re: Building CPython

2015-05-15 Thread Christian Gollwitzer
Am 14.05.15 um 20:50 schrieb Terry Reedy: On 5/14/2015 1:11 PM, Chris Angelico wrote: 2) make test - run the entire test suite. Takes just as long every time, but most of it won't have changed. The test runner has an option, -jn, to run tests in n processes instead of just 1. On my 6 core pe

Re: Building CPython

2015-05-15 Thread Marko Rauhamaa
Chris Angelico : > On Fri, May 15, 2015 at 6:59 PM, Marko Rauhamaa wrote: >> Must a method lookup necessarily involve object creation? > > Actually, no. > [...] > a particular Python implementation is most welcome to notice the > extremely common situation of method calls and optimize it. I'm no

Re: Building CPython

2015-05-15 Thread Chris Angelico
On Fri, May 15, 2015 at 8:14 PM, Steven D'Aprano wrote: > (If anything, using an implicit boolean test will be faster than an > explicit manual test, because it doesn't have to call the len() global.) Even more so: Some objects may be capable of determining their own lengths, but can ascertain th

Re: Building CPython

2015-05-15 Thread Steven D'Aprano
On Fri, 15 May 2015 06:59 pm, Marko Rauhamaa wrote: > However, in some respects, Python might be going overboard with its > dynamism; are all those dunder methods really needed? Must "false" be > defined so broadly? Must a method lookup necessarily involve object > creation? Yes, what do you mean

Re: Building CPython

2015-05-15 Thread Chris Angelico
On Fri, May 15, 2015 at 6:59 PM, Marko Rauhamaa wrote: > However, in some respects, Python might be going overboard with its > dynamism; are all those dunder methods really needed? Yes - at least, most of them. As regards operators, there are three options: either you have magic methods for all o

Re: Building CPython

2015-05-15 Thread BartC
On 15/05/2015 07:05, Gregory Ewing wrote: BartC wrote: It appears to be those "<=" and "+" operations in the code above where much of the time is spent. When I trace out the execution paths a bit more, I'll have a better picture of how many lines of C code are involved in each iteration. The p

Re: Building CPython

2015-05-15 Thread Marko Rauhamaa
wxjmfa...@gmail.com: > Implement unicode correctly. Did they reject your patch? Marko -- https://mail.python.org/mailman/listinfo/python-list

Re: Building CPython

2015-05-15 Thread Marko Rauhamaa
Gregory Ewing : > BartC wrote: >> It appears to be those "<=" and "+" operations in the code above >> where much of the time is spent. When I trace out the execution paths >> a bit more, I'll have a better picture of how many lines of C code >> are involved in each iteration. > > The path from dec

Re: Python: How to find out values of all feasible x under constraints.

2015-05-15 Thread Peter Otten
Xiang Zhang wrote: > I want to know how to find out values of all feasible x under constraints. > > x = [x_1, x_2, x_3,..., x_10] > > > constraints: > x_i = 0,1,2,3 or 4, where i=1,2,10 > x_1 + x_2 + x_3 +...+x_10 <= 15 That are 5**10 == 9765625 candidates. That's still feasible t

Re: Looking for direction

2015-05-15 Thread Ziqi Xiong
maybe we can change this list to dict, using item[0] and item[1] as keys, the whole item as value . then you can update by the same key i think Tim Chase 于2015年5月15日 周五01:17写道: > On 2015-05-14 09:57, 20/20 Lab wrote: > > On 05/13/2015 06:23 PM, Steven D'Aprano wrote: > >>> I have a LARGE csv file

Re: Looking for direction

2015-05-15 Thread 20/20 Lab
On 05/13/2015 06:12 PM, Dave Angel wrote: On 05/13/2015 08:45 PM, 20/20 Lab wrote:> You accidentally replied to me, rather than the mailing list. Please use reply-list, or if your mailer can't handle that, do a Reply-All, and remove the parts you don't want. > > On 05/13/2015 05:07 PM, Dav

Re: Looking for direction

2015-05-15 Thread 20/20 Lab
On 05/13/2015 06:12 PM, Dave Angel wrote: On 05/13/2015 08:45 PM, 20/20 Lab wrote:> You accidentally replied to me, rather than the mailing list. Please use reply-list, or if your mailer can't handle that, do a Reply-All, and remove the parts you don't want. ...and now that you mention it.

new python.org mailing list, elections-wg

2015-05-15 Thread Laura Creighton
It is for discussing voting software (currently Helios and Evote) with the end result that the new PSF election Commissioner Ian Cordasco will pick one and use it for the next PSF eÃlection. We're hoping to turn it into a real PSF workgroup. It looks like it is going to be a fairly nerdy place. A