Re: Fast pythonic way to process a huge integer list

2016-01-07 Thread KP
On Wednesday, 6 January 2016 18:37:22 UTC-8, high5s...@gmail.com wrote: > I have a list of 163.840 integers. What is a fast & pythonic way to process > this list in 1,280 chunks of 128 integers? Thanks all for your valuable input - much appreciated! -- https://mail.python.org/mailman/listinfo/p

Re: Fast pythonic way to process a huge integer list

2016-01-07 Thread Peter Otten
high5stor...@gmail.com wrote: > I have a list of 163.840 integers. What is a fast & pythonic way to > process this list in 1,280 chunks of 128 integers? What kind of processing do you have in mind? If it is about numbercrunching use a numpy.array. This can also easily change its shape: >>> imp

Re: Fast pythonic way to process a huge integer list

2016-01-06 Thread Cameron Simpson
On 06Jan2016 18:36, high5stor...@gmail.com wrote: I have a list of 163.840 integers. What is a fast & pythonic way to process this list in 1,280 chunks of 128 integers? The depends. When you say "list", is it already a _python_ list? Or do you just mean that the intergers are in a file or som

Re: Fast pythonic way to process a huge integer list

2016-01-06 Thread Tim Chase
On 2016-01-06 18:36, high5stor...@gmail.com wrote: > I have a list of 163.840 integers. What is a fast & pythonic way to > process this list in 1,280 chunks of 128 integers? That's a modest list, far from huge. You have lots of options, but the following seems the most pythonic to me: # I don'

Re: Fast pythonic way to process a huge integer list

2016-01-06 Thread Terry Reedy
On 1/6/2016 9:36 PM, high5stor...@gmail.com wrote: I have a list of 163.840 integers. What is a fast & pythonic way to process this list in 1,280 chunks of 128 integers? What have you tried that did not work? This is really pretty simple, but the detail depend on the meaning of 'process a c