Home
last modified time | relevance | path

Searched full:sorted (Results 1 – 25 of 4935) sorted by relevance

12345678910>>...198

/external/rust/crates/serde_cbor/tests/
Dcanonical.rs29 let mut sorted = expected.clone(); in integer_canonical_sort_order() localVariable
30 sorted.sort(); in integer_canonical_sort_order()
32 assert_eq!(expected, sorted); in integer_canonical_sort_order()
42 let mut sorted = expected.clone(); in string_canonical_sort_order() localVariable
43 sorted.sort(); in string_canonical_sort_order()
45 assert_eq!(expected, sorted); in string_canonical_sort_order()
55 let mut sorted = expected.clone(); in bytes_canonical_sort_order() localVariable
56 sorted.sort(); in bytes_canonical_sort_order()
58 assert_eq!(expected, sorted); in bytes_canonical_sort_order()
65 let mut sorted = expected.clone(); in simple_data_canonical_sort_order() localVariable
[all …]
/external/python/cpython2/Doc/howto/
Dsorting.rst11 in-place. There is also a :func:`sorted` built-in function that builds a new
12 sorted list from an iterable.
20 A simple ascending sort is very easy: just call the :func:`sorted` function. It
21 returns a new sorted list::
23 >>> sorted([5, 2, 3, 1, 4])
28 than :func:`sorted` - but if you don't need the original list, it's slightly
37 lists. In contrast, the :func:`sorted` function accepts any iterable.
39 >>> sorted({1: 'D', 2: 'B', 3: 'B', 4: 'E', 5: 'A'})
45 Starting with Python 2.4, both :meth:`list.sort` and :func:`sorted` added a
51 >>> sorted("This is a test string from Andrew".split(), key=str.lower)
[all …]
/external/python/cpython3/Doc/howto/
Dsorting.rst11 in-place. There is also a :func:`sorted` built-in function that builds a new
12 sorted list from an iterable.
20 A simple ascending sort is very easy: just call the :func:`sorted` function. It
21 returns a new sorted list:
25 >>> sorted([5, 2, 3, 1, 4])
30 than :func:`sorted` - but if you don't need the original list, it's slightly
41 lists. In contrast, the :func:`sorted` function accepts any iterable.
45 >>> sorted({1: 'D', 2: 'B', 3: 'B', 4: 'E', 5: 'A'})
51 Both :meth:`list.sort` and :func:`sorted` have a *key* parameter to specify a
59 >>> sorted("This is a test string from Andrew".split(), key=str.lower)
[all …]
/external/webp/src/utils/
Dhuffman_utils.c78 // sorted[code_lengths_size] is a pre-allocated array for sorting symbols
82 uint16_t sorted[]) { in BuildHuffmanTable() argument
86 int symbol; // symbol index in original or sorted table in BuildHuffmanTable()
89 // offsets in sorted table for each length: in BuildHuffmanTable()
94 assert((root_table != NULL && sorted != NULL) || in BuildHuffmanTable()
95 (root_table == NULL && sorted == NULL)); in BuildHuffmanTable()
111 // Generate offsets into sorted symbol table by code length. in BuildHuffmanTable()
124 if (sorted != NULL) { in BuildHuffmanTable()
125 sorted[offset[symbol_code_length]++] = symbol; in BuildHuffmanTable()
134 if (sorted != NULL) { in BuildHuffmanTable()
[all …]
/external/guava/guava/src/com/google/common/collect/
DImmutableSortedMultiset.java41 * <p><b>Warning:</b> as with any sorted collection, you are strongly advised not to use a {@link
61 * ImmutableMultiset}. Elements are sorted by the specified comparator.
104 * Returns the empty immutable sorted multiset.
113 /** Returns an immutable sorted multiset containing a single element. */
122 * Returns an immutable sorted multiset containing the given elements sorted by their natural
132 * Returns an immutable sorted multiset containing the given elements sorted by their natural
142 * Returns an immutable sorted multiset containing the given elements sorted by their natural
153 * Returns an immutable sorted multiset containing the given elements sorted by their natural
164 * Returns an immutable sorted multiset containing the given elements sorted by their natural
179 * Returns an immutable sorted multiset containing the given elements sorted by their natural
[all …]
DImmutableSortedSet.java49 * <p><b>Warning:</b> as with any sorted collection, you are strongly advised not to use a {@link
69 ImmutableSet.SPLITERATOR_CHARACTERISTICS | Spliterator.SORTED;
94 * Returns the empty immutable sorted set.
102 /** Returns an immutable sorted set containing a single element. */
108 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
120 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
132 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
144 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
157 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
181 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
[all …]
/external/rust/crates/remain/tests/
Dorder.rs4 #[remain::sorted]
11 #[remain::sorted]
18 #[remain::sorted]
24 #[remain::sorted]
31 #[remain::sorted]
38 #[remain::sorted]
54 #[remain::sorted]
/external/armnn/samples/ObjectDetection/test/
DNMSTests.cpp55 auto sorted = od::NonMaxSuppression(expectedResults, 0.49); variable
58 REQUIRE(sorted.size() == 4);
61 REQUIRE(sorted[0] == 1);
62 REQUIRE(sorted[1] == 3);
63 REQUIRE(sorted[2] == 4);
64 REQUIRE(sorted[3] == 5);
83 auto sorted = od::NonMaxSuppression(expectedResults, 0.5); variable
86 REQUIRE(sorted.size() == 1);
89 REQUIRE(sorted[0] == 0);
/external/skia/infra/bots/task_drivers/perf_puppeteer_canvas/
Dperf_puppeteer_canvas.go273 sorted := make([]float32, len(input))
274 copy(sorted, input)
275 sort.Slice(sorted, func(i, j int) bool {
276 return sorted[i] < sorted[j]
279 avg := computeAverage(sorted)
281 for i := 0; i < len(sorted); i++ {
282 variance += (sorted[i] - avg) * (sorted[i] - avg)
284 stddev := float32(math.Sqrt(float64(variance / float32(len(sorted)))))
286 medIdx := (len(sorted) * 50) / 100
287 percentile90Idx := (len(sorted) * 90) / 100
[all …]
/external/skia/docs/examples/
DRect_joinNonEmptyArg.cpp8 SkRect sorted = rect.makeSorted(); in draw() local
12 sorted.joinNonEmptyArg(toJoin); in draw()
13 SkDebugf("sorted: %g, %g, %g, %g\n", sorted.fLeft, sorted.fTop, sorted.fRight, sorted.fBottom); in draw()
DRect_joinPossiblyEmptyRect.cpp8 SkRect sorted = rect.makeSorted(); in draw() local
12 sorted.joinPossiblyEmptyRect(toJoin); in draw()
13 SkDebugf("sorted: %g, %g, %g, %g\n", sorted.fLeft, sorted.fTop, sorted.fRight, sorted.fBottom); in draw()
/external/guava/android/guava/src/com/google/common/collect/
DImmutableSortedSet.java45 * <p><b>Warning:</b> as with any sorted collection, you are strongly advised not to use a {@link
73 * Returns the empty immutable sorted set.
81 /** Returns an immutable sorted set containing a single element. */
87 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
99 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
111 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
123 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
136 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
160 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
172 * Returns an immutable sorted set containing the given elements sorted by their natural ordering.
[all …]
DImmutableSortedMultiset.java39 * <p><b>Warning:</b> as with any sorted collection, you are strongly advised not to use a {@link
58 * Returns the empty immutable sorted multiset.
67 /** Returns an immutable sorted multiset containing a single element. */
76 * Returns an immutable sorted multiset containing the given elements sorted by their natural
86 * Returns an immutable sorted multiset containing the given elements sorted by their natural
96 * Returns an immutable sorted multiset containing the given elements sorted by their natural
107 * Returns an immutable sorted multiset containing the given elements sorted by their natural
118 * Returns an immutable sorted multiset containing the given elements sorted by their natural
133 * Returns an immutable sorted multiset containing the given elements sorted by their natural
143 * Returns an immutable sorted multiset containing the given elements sorted by their natural
[all …]
/external/lzma/CPP/7zip/Common/
DUniqBlocks.cpp11 unsigned left = 0, right = Sorted.Size(); in AddUniq()
15 unsigned index = Sorted[mid]; in AddUniq()
36 Sorted.Insert(left, index); in AddUniq()
51 unsigned num = Sorted.Size(); in GetReverseMap()
54 const unsigned *sorted = &Sorted[0]; in GetReverseMap() local
56 p[sorted[i]] = i; in GetReverseMap()
/external/selinux/libsepol/cil/src/
Dcil_binary.h334 * The function is given a structure containing the sorted ibpkeycons and
338 * @param[in] node The cil_sort structure that contains the sorted ibpkeycons.
346 * The function is given a structure containing the sorted ibendportcons and
350 * @param[in] node The cil_sort structure that contains the sorted ibendportcons.
358 * The function is given a structure containing the sorted portcons and
362 * @param[in] node The cil_sort structure that contains the sorted portcons.
370 * The function is given a structure containing the sorted netifcons and
374 * @param[in] node The cil_sort structure that contains the sorted netifcons.
382 * The function is given a structure containing the sorted nodecons and
386 * @param[in] node The cil_sort structure that contains the sorted nodecons.
[all …]
/external/angle/src/libANGLE/renderer/metal/
Dgen_mtl_format_table.py441 for angle_format in sorted(angle_to_mtl.keys()):
443 for angle_format in sorted(angle_override.keys()):
448 for angle_format in sorted(mac_specific_map.keys()):
451 for angle_format in sorted(mac_override.keys()):
454 for angle_format in sorted(mac_override_bc1.keys()):
463 for angle_format in sorted(mac_override_es3.keys()):
470 for angle_format in sorted(sim_specific_map.keys()):
473 for angle_format in sorted(sim_override.keys()):
477 for angle_format in sorted(astc_tpl_map.keys()):
482 for angle_format in sorted(astc_tpl_map.keys()):
[all …]
/external/rust/crates/remain/
DREADME.md1 Remain sorted
10 variants of an enum or the arms of a match expression are written in sorted
20 Place a `#[remain::sorted]` attribute on enums, structs, match-expressions, or
23 Alternatively, import as `use remain::sorted;` and use `#[sorted]` as the
27 #[remain::sorted]
41 #[remain::sorted]
55 #[remain::sorted]
105 `#[sorted]` to make them work on a stable compiler.
113 #[sorted]
/external/pigweed/pw_presubmit/py/pw_presubmit/
Dkeep_sorted.py14 """Keep specified lists sorted."""
45 _START = re.compile(r'keep-sorted: (begin|start)', re.IGNORECASE)
46 _END = re.compile(r'keep-sorted: (stop|end)', re.IGNORECASE)
58 keep-sorted: start
59 keep-sorted: end
156 # non-comments. The keep-sorted check keeps this comment with the
158 # https://pigweed.dev/pw_presubmit/#sorted-blocks.
213 sorted_lines = sorted(lines, key=sort_key)
241 f'found {line.strip()!r} inside keep-sorted block',
300 f'unrecognized directive on keep-sorted line: '
[all …]
/external/autotest/server/
Dsite_utils_unittest.py89 self.assertEqual(sorted(test_views.keys()),
90 sorted(expected_test_views.keys()),
92 (sorted(test_views.keys()),
93 sorted(expected_test_views.keys())))
96 self.assertEqual(sorted(test_status_list),
97 sorted(expected_test_views[test_name]),
101 sorted(test_status_list),
102 sorted(expected_test_views[test_name])))
/external/tensorflow/tensorflow/python/ops/
Dsort_ops.py75 sorted along the given `axis`.
89 """Returns the indices of a tensor that give its sorted order along an axis.
98 >>> sorted = tf.gather(values, sort_order)
99 >>> assert tf.reduce_all(sorted == tf.sort(values))
102 `values`, but along the given axis, values represent the index of the sorted
163 Either the sorted values, or the indices of the sorted values in the
170 valid_directions = ', '.join(sorted(_SORT_IMPL.keys()))
191 axis: Index of the axis which values should be sorted along.
192 return_argsort: If False, return the sorted values. If True, return the
196 The sorted values.
[all …]
/external/python/cpython3/Lib/lib2to3/fixes/
Dfix_idioms.py25 v = sorted(EXPR)
47 sorted=any<
65 sorted=any<
81 # If we've matched one of the sort/sorted subpatterns above, we
84 if r and "sorted" in r:
95 elif "sorted" in results:
123 list_call.replace(Name("sorted", prefix=list_call.prefix))
127 simple_expr.replace(Call(Name("sorted"), [new],
135 # shove them right after the sorted() call.
/external/python/cpython2/Lib/lib2to3/fixes/
Dfix_idioms.py25 v = sorted(EXPR)
47 sorted=any<
65 sorted=any<
81 # If we've matched one of the sort/sorted subpatterns above, we
84 if r and "sorted" in r:
95 elif "sorted" in results:
123 list_call.replace(Name(u"sorted", prefix=list_call.prefix))
127 simple_expr.replace(Call(Name(u"sorted"), [new],
135 # shove them right after the sorted() call.
/external/cronet/buildtools/third_party/libc++/trunk/test/std/algorithms/alg.sorting/alg.sort/sort/
Dranges.sort.pass.cpp64 auto sorted = input; in test_one() local
65 auto b = Iter(sorted.data()); in test_one()
66 auto e = Sent(Iter(sorted.data() + sorted.size())); in test_one()
69 assert(sorted == expected); in test_one()
70 assert(base(last) == sorted.data() + sorted.size()); in test_one()
74 auto sorted = input; in test_one() local
75 auto b = Iter(sorted.data()); in test_one()
76 auto e = Sent(Iter(sorted.data() + sorted.size())); in test_one()
80 assert(sorted == expected); in test_one()
81 assert(base(last) == sorted.data() + sorted.size()); in test_one()
[all …]
/external/cronet/buildtools/third_party/libc++/trunk/test/std/algorithms/alg.sorting/alg.heap.operations/sort.heap/
Dranges_sort_heap.pass.cpp63 constexpr void verify_sorted(const std::array<T, N>& sorted, Iter last, std::array<T, N> expected) { in verify_sorted() argument
64 assert(sorted == expected); in verify_sorted()
65 assert(base(last) == sorted.data() + sorted.size()); in verify_sorted()
66 assert(std::is_sorted(sorted.begin(), sorted.end())); in verify_sorted()
74 auto sorted = input; in test_one() local
75 auto b = Iter(sorted.data()); in test_one()
76 auto e = Sent(Iter(sorted.data() + sorted.size())); in test_one()
79 verify_sorted(sorted, last, expected); in test_one()
83 auto sorted = input; in test_one() local
84 auto b = Iter(sorted.data()); in test_one()
[all …]
/external/starlark-go/starlark/testdata/
Dbuiltins.star39 # sorted
40 assert.eq(sorted([42, 123, 3]), [3, 42, 123])
41 assert.eq(sorted([42, 123, 3], reverse=True), [123, 42, 3])
42 assert.eq(sorted(["wiz", "foo", "bar"]), ["bar", "foo", "wiz"])
43 assert.eq(sorted(["wiz", "foo", "bar"], reverse=True), ["wiz", "foo", "bar"])
44 assert.fails(lambda: sorted([1, 2, None, 3]), "int < NoneType not implemented")
45 assert.fails(lambda: sorted([1, "one"]), "string < int not implemented")
47 assert.eq(sorted(["two", "three", "four"], key=len),
49 assert.eq(sorted(["two", "three", "four"], key=len, reverse=True),
51 assert.fails(lambda: sorted([1, 2, 3], key=None), "got NoneType, want callable")
[all …]

12345678910>>...198