• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

IntelPython / dpnp / 12895869998

21 Jan 2025 09:07PM UTC coverage: 71.211% (+0.4%) from 70.856%
12895869998

Pull #2201

github

web-flow
Merge cf50357ca into 356184a29
Pull Request #2201: Implement extension for `dpnp.choose`

4568 of 9390 branches covered (48.65%)

Branch coverage included in aggregate %.

282 of 333 new or added lines in 5 files covered. (84.68%)

4 existing lines in 3 files now uncovered.

16935 of 20806 relevant lines covered (81.39%)

20542.24 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

77.78
/dpnp/dpnp_algo/dpnp_algo_indexing.pxi
1
# cython: language_level=3
2
# cython: linetrace=True
3
# -*- coding: utf-8 -*-
4
# *****************************************************************************
5
# Copyright (c) 2016-2025, Intel Corporation
6
# All rights reserved.
7
#
8
# Redistribution and use in source and binary forms, with or without
9
# modification, are permitted provided that the following conditions are met:
10
# - Redistributions of source code must retain the above copyright notice,
11
#   this list of conditions and the following disclaimer.
12
# - Redistributions in binary form must reproduce the above copyright notice,
13
#   this list of conditions and the following disclaimer in the documentation
14
#   and/or other materials provided with the distribution.
15
#
16
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
17
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
20
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26
# THE POSSIBILITY OF SUCH DAMAGE.
27
# *****************************************************************************
28

29
"""Module Backend (Indexing part)
30

31
This module contains interface functions between C backend layer
32
and the rest of the library
33

34
"""
35

36
# NO IMPORTs here. All imports must be placed into main "dpnp_algo.pyx" file
37

38
__all__ += [
×
39
    "dpnp_putmask",
40
]
41

UNCOV
42
cpdef dpnp_putmask(utils.dpnp_descriptor arr, utils.dpnp_descriptor mask, utils.dpnp_descriptor values):
×
43
    cdef int values_size = values.size
1✔
44

45
    mask_flatiter = mask.get_pyobj().flat
1✔
46
    arr_flatiter = arr.get_pyobj().flat
1✔
47
    values_flatiter = values.get_pyobj().flat
1✔
48

49
    for i in range(arr.size):
1✔
50
        if mask_flatiter[i]:
1✔
51
            arr_flatiter[i] = values_flatiter[i % values_size]
1✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc