Home
last modified time | relevance | path

Searched refs:groupby (Results 1 – 25 of 35) sorted by relevance

12

/external/python/cpython2/Lib/test/
Dtest_itertools.py207 … noruns = [k for k,v in groupby(c)] # combo without consecutive repeats
453 self.assertEqual([], list(groupby([])))
454 self.assertEqual([], list(groupby([], key=id)))
455 self.assertRaises(TypeError, list, groupby('abc', []))
456 self.assertRaises(TypeError, groupby, None)
457 self.assertRaises(TypeError, groupby, 'abc', lambda x:x, 10)
463 for k, g in groupby(s, lambda r:r[0]):
471 for k, g in groupby(s, lambda r:r[0]):
472 for ik, ig in groupby(g, lambda r:r[2]):
480 keys = [k for k, g in groupby(s, lambda r:r[0])]
[all …]
/external/python/cpython3/Lib/test/
Dtest_itertools.py354 … noruns = [k for k,v in groupby(c)] # combo without consecutive repeats
701 self.assertEqual([], list(groupby([])))
702 self.assertEqual([], list(groupby([], key=id)))
703 self.assertRaises(TypeError, list, groupby('abc', []))
704 self.assertRaises(TypeError, groupby, None)
705 self.assertRaises(TypeError, groupby, 'abc', lambda x:x, 10)
711 for k, g in groupby(s, lambda r:r[0]):
720 for k, g in pickle.loads(pickle.dumps(groupby(s, testR), proto)):
728 for k, g in groupby(s, testR):
729 for ik, ig in groupby(g, testR2):
[all …]
/external/Reactive-Extensions/RxCpp/Ix/CPP/samples/SampleCppLinq/
DSampleCppLinq.cpp51 .groupby([](const item& i) { return i.args; }); in run()
62 .groupby([](const item& i) { return i.concurrency; }); in run()
/external/libchrome/mojo/public/tools/bindings/generators/cpp_templates/
Denum_macros.tmpl26 {%- for _, values in enum.fields|groupby('numeric_value') %}
63 {%- for enum_field in enum.fields|groupby('numeric_value') %}
/external/toolchain-utils/automation/clients/report/dejagnu/
Dsummary.py9 from itertools import groupby
202 for name, res_iter in groupby(results_by_name, key=name_key):
/external/libxkbcommon/xkbcommon/
Dmakekeys.py50 print_entries(next(g[1]) for g in itertools.groupby(sorted(entries, key=lambda e: e[1]), key=lambda…
/external/python/cpython2/Doc/library/
Ditertools.rst54 :func:`groupby` iterable[, keyfunc] sub-iterators grouped by value of keyfunc(v)
290 .. function:: groupby(iterable[, key])
298 The operation of :func:`groupby` is similar to the ``uniq`` filter in Unix. It
305 with :func:`groupby`. Because the source is shared, when the :func:`groupby`
312 for k, g in groupby(data, keyfunc):
316 :func:`groupby` is roughly equivalent to::
318 class groupby(object):
319 # [k for k, g in groupby('AAAABBBCCDAABBB')] --> A B C D A B
320 # [list(g) for k, g in groupby('AAAABBBCCD')] --> AAAA BBB CC D
712 g = groupby(iterable)
[all …]
Dfunctools.rst28 :func:`itertools.groupby`). This function is primarily used as a transition
/external/python/cpython3/Doc/library/
Ditertools.rst56 :func:`groupby` iterable[, key] sub-iterators grouped by value of k…
364 .. function:: groupby(iterable, key=None)
372 The operation of :func:`groupby` is similar to the ``uniq`` filter in Unix. It
379 with :func:`groupby`. Because the source is shared, when the :func:`groupby`
386 for k, g in groupby(data, keyfunc):
390 :func:`groupby` is roughly equivalent to::
392 class groupby:
393 # [k for k, g in groupby('AAAABBBCCDAABBB')] --> A B C D A B
394 # [list(g) for k, g in groupby('AAAABBBCCD')] --> AAAA BBB CC D
721 g = groupby(iterable)
[all …]
/external/libchrome/mojo/public/tools/bindings/generators/js_templates/
Denum_definition.tmpl17 {%- for enum_field in enum.fields|groupby('numeric_value') %}
/external/libchrome/mojo/public/tools/bindings/generators/java_templates/
Denum_definition.tmpl23 {%- for enum_field in enum.fields|groupby('numeric_value') %}
/external/python/cpython3/Lib/
Dstatistics.py91 from itertools import groupby
145 for typ, values in groupby(data, type):
/external/libchrome/third_party/jinja2/
Dasyncfilters.py73 for key, values in filters.groupby(sorted(
Dfilters.py16 from itertools import groupby, chain
852 in groupby(sorted(value, key=expr), expr)]
/external/python/cpython3/Misc/NEWS.d/
D3.7.0a2.rst418 Stop crashes when concurrently iterate over itertools.groupby() iterators.
427 An iterator produced by itertools.groupby() iterator now becomes exhausted
428 after advancing the groupby iterator.
/external/python/cpython2/Doc/whatsnew/
D2.4.rst1093 * The :mod:`itertools` module gained a ``groupby(iterable[, *func*])``
1097 itself. :func:`groupby` then groups the elements into subsequences which have
1102 whether a number is even or odd, so the result of :func:`groupby` is to return
1107 >>> for key_val, it in itertools.groupby(L, lambda x: x % 2):
1117 :func:`groupby` is typically used with sorted input. The logic for
1118 :func:`groupby` is similar to the Unix ``uniq`` filter which makes it handy for
1125 >>> for k, g in itertools.groupby(letters):
1134 >>> [k for k, g in groupby(letters)]
1137 >>> [(k, len(list(g))) for k, g in groupby(letters)]
/external/python/cpython3/Doc/whatsnew/
D2.4.rst1093 * The :mod:`itertools` module gained a ``groupby(iterable[, *func*])``
1097 itself. :func:`groupby` then groups the elements into subsequences which have
1102 whether a number is even or odd, so the result of :func:`groupby` is to return
1107 >>> for key_val, it in itertools.groupby(L, lambda x: x % 2):
1117 :func:`groupby` is typically used with sorted input. The logic for
1118 :func:`groupby` is similar to the Unix ``uniq`` filter which makes it handy for
1125 >>> for k, g in itertools.groupby(letters):
1134 >>> [k for k, g in groupby(letters)]
1137 >>> [(k, len(list(g))) for k, g in groupby(letters)]
/external/Reactive-Extensions/RxCpp/Ix/CPP/src/cpplinq/
Dlinq.hpp234 linq_driver< linq_groupby<Collection, KeyFn> > groupby(KeyFn fn) in groupby() function in cpplinq::linq_driver
/external/webrtc/webrtc/video/
Dfull_stack_plot.py388 args = itertools.groupby(args, lambda x: x in ["-n", "--next"])
/external/autotest/frontend/tko/
Drpc_interface.py161 for key, group in itertools.groupby(attribute_list, iter_keyfunc):
/external/Reactive-Extensions/RxCpp/Ix/CPP/unittest/
Dtestbench.cpp242 .groupby([](int i){return i % 10; }); in TEST()
/external/harfbuzz_ng/test/shaping/
Dhb_test_tools.py347 return groupby (f, key=identifier)
/external/python/cpython3/Doc/howto/
Dfunctional.rst949 The last function I'll discuss, :func:`itertools.groupby(iter, key_func=None)
950 <itertools.groupby>`, is the most complicated. ``key_func(elem)`` is a function
954 :func:`~itertools.groupby` collects all the consecutive elements from the
969 itertools.groupby(city_list, get_state) =>
982 :func:`~itertools.groupby` assumes that the underlying iterable's contents will
/external/harfbuzz_ng/src/
Dgen-tag-table.py958 for initial, group in itertools.groupby ((lt_tags for lt_tags in [
/external/python/cpython2/Doc/howto/
Dfunctional.rst1028 The last function I'll discuss, ``itertools.groupby(iter, key_func=None)``, is
1033 ``groupby()`` collects all the consecutive elements from the underlying iterable
1048 itertools.groupby(city_list, get_state) =>
1061 ``groupby()`` assumes that the underlying iterable's contents will already be

12