On Sun, Jul 1, 2012 at 3:01 PM, Stefan Behnel <stefan...@behnel.de> wrote:
>
> To address the main problem of users not finding what they need, what about
> simply extending the docstring of the grouper() function with a sentence
> like this:
>
> "This functionality is also called 'chunking' or 'blocking' and can be used
> for load distribution and sharding."
>
> That would make it easy for users to find what they are looking for when
> they search the page for "chunk". I find that a much more common and less
> ambiguous name than "grouping", which reminds me more of "group by".

In appeared that "chunking" and "grouping" are different kind of
tasks. You can chunk a sequence (sting) by slicing it into smaller
sequences, but you can not chunk in iterable - you can only group it.

There is an data loss about the structure that occurs when a sequence
(string) becomes an iterator:
 chunks ABCDE -> AB CD E
 group ABCDE -> A B C D E -> (A B) (C D) (D E)
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to