Skip to content

Commit 13de40d

Browse files
dpctl 0.3.3 integration, package build with tests (#118)
* dpctl 0.3.3 integration, package build with tests * dpctl =0.3.3 * add setuptools in test requirements
1 parent d8e4d24 commit 13de40d

File tree

7 files changed

+49
-13
lines changed

7 files changed

+49
-13
lines changed

conda-recipe/activate_env.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
if [ ! -z "${ONEAPI_ROOT}" ]; then
44
. ${ONEAPI_ROOT}/mkl/latest/env/vars.sh
5-
. ${ONEAPI_ROOT}/compiler/latest/env/vars.sh
5+
. ${ONEAPI_ROOT}/compiler/2021.1-beta09/env/vars.sh
66
. ${ONEAPI_ROOT}/tbb/latest/env/vars.sh
77
fi

conda-recipe/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
if [ ! -z "${ONEAPI_ROOT}" ]; then
66
. ${ONEAPI_ROOT}/mkl/latest/env/vars.sh
7-
. ${ONEAPI_ROOT}/compiler/latest/env/vars.sh
7+
. ${ONEAPI_ROOT}/compiler/2021.1-beta09/env/vars.sh
88
. ${ONEAPI_ROOT}/tbb/latest/env/vars.sh
99
fi
1010

conda-recipe/meta.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ requirements:
1414
- setuptools
1515
- numpy-devel >=1.18
1616
- cython
17+
- dpctl =0.3.3
1718
run:
1819
- python
1920

@@ -26,8 +27,14 @@ build:
2627
test:
2728
requires:
2829
- pytest
30+
- setuptools
31+
- dpctl =0.3.3
32+
source_files:
33+
- examples
34+
- tests
2935
commands:
30-
- source ${ONEAPI_ROOT}/compiler/latest/env/vars.sh && python -c "import dpnp"
36+
- python -c "import dpnp"
37+
- pytest
3138

3239
about:
3340
license: ISSL

conda-recipe/run_test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
if [ ! -z "${ONEAPI_ROOT}" ]; then
66
. ${ONEAPI_ROOT}/mkl/latest/env/vars.sh
7-
. ${ONEAPI_ROOT}/compiler/latest/env/vars.sh
7+
. ${ONEAPI_ROOT}/compiler/2021.1-beta09/env/vars.sh
88
. ${ONEAPI_ROOT}/tbb/latest/env/vars.sh
99
fi
1010

dpnp/backend/queue_sycl.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
#include <CL/sycl.hpp>
3131

3232
#if !defined(DPNP_LOCAL_QUEUE)
33-
#include <dppl_sycl_queue_interface.h>
33+
#include <dppl_sycl_queue_manager.h>
3434
#endif
3535

3636
#define DPNP_QUEUE backend_sycl::get_queue()
@@ -92,7 +92,7 @@ class backend_sycl
9292
return *queue;
9393
#else
9494
// temporal solution. Started from Sept-2020
95-
DPPLSyclQueueRef DPCtrl_queue = DPPLGetCurrentQueue();
95+
DPPLSyclQueueRef DPCtrl_queue = DPPLQueueMgr_GetCurrentQueue();
9696
return *(reinterpret_cast<cl::sycl::queue*>(DPCtrl_queue));
9797
#endif
9898
}

setup.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -134,13 +134,12 @@
134134
"""
135135
Detect external SYCL queue handling library
136136
"""
137-
import dpctrl
137+
import dpctl
138138

139-
# TODO this will not work with no Conda environment
140-
_conda_root = os.environ.get('CONDA_PREFIX', "conda_include_error")
141-
_dpctrl_include += [os.path.join(_conda_root, 'include')]
142-
_dpctrl_libpath += [os.path.join(_conda_root, 'lib')]
143-
_dpctrl_lib += ["dpctrlsyclinterface"]
139+
_dpctrl_include += [dpctl.get_include()]
140+
# _dpctrl_libpath = for package build + for local build
141+
_dpctrl_libpath += ["$ORIGIN/../dpctl"] + [os.path.join(dpctl.get_include(), '..')]
142+
_dpctrl_lib += ["DPPLSyclInterface"]
144143
except ImportError:
145144
"""
146145
Set local SYCL queue handler

tests/skipped_tests.tbl

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,35 @@
1+
tests/test_dot.py::test_dot_arange[float32]
2+
tests/test_linalg.py::test_eig_arange[2-float64]
3+
tests/test_linalg.py::test_eig_arange[2-float32]
4+
tests/test_linalg.py::test_eig_arange[2-int64]
5+
tests/test_linalg.py::test_eig_arange[2-int32]
6+
tests/test_linalg.py::test_eig_arange[4-float64]
7+
tests/test_linalg.py::test_eig_arange[4-float32]
8+
tests/test_linalg.py::test_eig_arange[4-int64]
9+
tests/test_linalg.py::test_eig_arange[4-int32]
10+
tests/test_linalg.py::test_eig_arange[8-float64]
11+
tests/test_linalg.py::test_eig_arange[8-float32]
12+
tests/test_linalg.py::test_eig_arange[8-int64]
13+
tests/test_linalg.py::test_eig_arange[8-int32]
14+
tests/test_linalg.py::test_eig_arange[16-float64]
115
tests/test_linalg.py::test_eig_arange[16-float32]
16+
tests/test_linalg.py::test_eig_arange[16-int64]
17+
tests/test_linalg.py::test_eig_arange[16-int32]
18+
tests/test_linalg.py::test_eig_arange[300-float64]
219
tests/test_linalg.py::test_eig_arange[300-float32]
3-
tests/test_linalg.py::test_eig_arange[8-float32]
20+
tests/test_linalg.py::test_eig_arange[300-int64]
21+
tests/test_linalg.py::test_eig_arange[300-int32]
22+
tests/test_random.py::test_random_input_size[rand]
23+
tests/test_random.py::test_random_input_size[randn]
24+
tests/test_random.py::test_random_input_shape[random]
25+
tests/test_random.py::test_random_input_shape[random_sample]
26+
tests/test_random.py::test_random_input_shape[randf]
27+
tests/test_random.py::test_random_input_shape[sample]
28+
tests/test_random.py::test_random_check_otput[random]
29+
tests/test_random.py::test_random_check_otput[random_sample]
30+
tests/test_random.py::test_random_check_otput[randf]
31+
tests/test_random.py::test_random_check_otput[sample]
32+
tests/test_random.py::test_random_check_otput[rand]
433
tests/third_party/cupy/binary_tests/test_elementwise.py::TestElementwise::test_bitwise_and
534
tests/third_party/cupy/binary_tests/test_elementwise.py::TestElementwise::test_bitwise_or
635
tests/third_party/cupy/binary_tests/test_elementwise.py::TestElementwise::test_bitwise_xor
@@ -492,6 +521,7 @@ tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_clip_min_max_none
492521
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_clip_min_none
493522
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_external_clip1
494523
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_external_clip2
524+
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_fmin_nan
495525
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_maximum_nan
496526
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_minimum_nan
497527
tests/third_party/cupy/math_tests/test_misc.py::TestMisc::test_nan_to_num

0 commit comments

Comments
 (0)