Skip to content

Commit ff9bed2

Browse files
authored
Merge pull request #1484 from IntelPython/merge_to_gold
Merge master to gold/2021
2 parents 8617f20 + 321c942 commit ff9bed2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+5132
-1822
lines changed

.github/workflows/build-sphinx.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ jobs:
2727

2828
- name: Free Disk Space (Ubuntu)
2929
uses: jlumbroso/free-disk-space@main
30+
with:
31+
docker-images: false
3032

3133
- name: Install Intel repository
3234
run: |
@@ -47,7 +49,7 @@ jobs:
4749
run: |
4850
sudo apt-get install intel-oneapi-mkl \
4951
intel-oneapi-mkl-devel \
50-
intel-oneapi-dpcpp-cpp-compiler
52+
intel-oneapi-compiler-dpcpp-cpp
5153
5254
# https://github.com/marketplace/actions/checkout
5355
- name: Install nvidia-cuda support drivers
@@ -78,7 +80,7 @@ jobs:
7880
- name: Install dpnp dependencies
7981
run: |
8082
conda install dpctl mkl-devel-dpcpp onedpl-devel tbb-devel dpcpp_linux-64 \
81-
cmake cython pytest ninja scikit-build sysroot_linux-64">=2.28" ${{ env.CHANNELS }}
83+
cmake cython"<3" pytest ninja scikit-build sysroot_linux-64">=2.28" ${{ env.CHANNELS }}
8284
8385
- name: Install cuPy dependencies
8486
run: conda install cupy cudatoolkit=10.0

.github/workflows/conda-package.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,12 @@ env:
2020
test_random_state.py
2121
test_sort.py
2222
test_special.py
23+
test_umath.py
2324
test_usm_type.py
25+
third_party/cupy/linalg_tests/test_product.py
26+
third_party/cupy/math_tests/test_explog.py
27+
third_party/cupy/math_tests/test_misc.py
28+
third_party/cupy/math_tests/test_trigonometric.py
2429
third_party/cupy/sorting_tests/test_sort.py
2530
VER_JSON_NAME: 'version.json'
2631
VER_SCRIPT1: "import json; f = open('version.json', 'r'); j = json.load(f); f.close(); "
@@ -350,7 +355,7 @@ jobs:
350355
run:
351356
shell: ${{ matrix.os == 'windows-latest' && 'cmd /C CALL {0}' || 'bash -l {0}' }}
352357

353-
continue-on-error: false
358+
continue-on-error: true
354359

355360
if: |
356361
(github.repository == 'IntelPython/dpnp') &&

.github/workflows/generate_coverage.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
sudo apt-get install lcov
4242
- name: Install dpnp dependencies
4343
run: |
44-
conda install cython llvm cmake">=3.21" scikit-build ninja pytest pytest-cov coverage[toml] \
44+
conda install cython"<3" llvm cmake">=3.21" scikit-build ninja pytest pytest-cov coverage[toml] \
4545
dpctl dpcpp_linux-64 sysroot_linux-64">=2.28" mkl-devel-dpcpp tbb-devel onedpl-devel ${{ env.CHANNELS }}
4646
- name: Conda info
4747
run: |

CHANGELOG.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,38 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [0.12.1] - 07/18/2023
8+
9+
### Added
10+
11+
* Added `classifiers metadata` to a description of dpnp package [#1460](https://github.com/IntelPython/dpnp/pull/1460)
12+
* Added `pygrep-hooks` to pre-commit config [#1454](https://github.com/IntelPython/dpnp/pull/1454)
13+
* Added `flake8` to pre-commit config [#1453](https://github.com/IntelPython/dpnp/pull/1453)
14+
* Added `isort` to pre-commit config [#1451](https://github.com/IntelPython/dpnp/pull/1451)
15+
* Added `clang` format to pre-commit config [#1450](https://github.com/IntelPython/dpnp/pull/1450)
16+
* Added `black` to pre-commit config [#1449](https://github.com/IntelPython/dpnp/pull/1449)
17+
* Added `pre-commit` hooks [#1448](https://github.com/IntelPython/dpnp/pull/1448)
18+
19+
### Changed
20+
21+
* Pinned to `dpctl>=0.14.5` as host and run dependencies [#1481](https://github.com/IntelPython/dpnp/pull/1481)
22+
* Pinned dependent `cython` package to a version less than `3.0.0` [#1480](https://github.com/IntelPython/dpnp/pull/1480)
23+
* Added a specialized kernel for `dpnp.sum` with `axis=0` as a pybind11 extension [#1479](https://github.com/IntelPython/dpnp/pull/1479)
24+
* Redesigned `dpnp.square` function through pybind11 extension of OneMKL call where possible or Leveraging on `dpctl.tensor` implementation [#1473](https://github.com/IntelPython/dpnp/pull/1473)
25+
* Redesigned `dpnp.cos` and `dpnp.sin` functions through pybind11 extension of OneMKL calls where possible or Leveraging on `dpctl.tensor` implementation [#1471](https://github.com/IntelPython/dpnp/pull/1471)
26+
* Redesigned `dpnp.sqrt` function through pybind11 extension of OneMKL call where possible or Leveraging on `dpctl.tensor` implementation [#1470](https://github.com/IntelPython/dpnp/pull/1470)
27+
* Redesigned `dpnp.log` function through pybind11 extension of OneMKL call where possible or Leveraging on `dpctl.tensor` implementation [#1469](https://github.com/IntelPython/dpnp/pull/1469)
28+
* Leveraged `dpctl.tensor` implementation for logical operations [#1464](https://github.com/IntelPython/dpnp/pull/1464)
29+
* Leveraged `dpctl.tensor` implementation for `dpnp.floor_divide` function [#1462](https://github.com/IntelPython/dpnp/pull/1462)
30+
* Leveraged `dpctl.tensor` implementation for comparison functions [#1458](https://github.com/IntelPython/dpnp/pull/1458)
31+
### Fixed
32+
33+
* Improved `dpnp.dot` function to support OneMKL calls for input and output arrays with strides [#1477](https://github.com/IntelPython/dpnp/pull/1477)
34+
* Resolved issues with running `dpnp.linalg` functions on a device without fp64 support [#1474](https://github.com/IntelPython/dpnp/pull/1474)
35+
* Added `dtype` check of fp64 support by the resulting array in `call_origin` function [#1457](https://github.com/IntelPython/dpnp/pull/1457)
36+
* Resolved a compilation warning with `std::getenv()` call on Windows [#1452](https://github.com/IntelPython/dpnp/pull/1452)
37+
* Corrected a link to OneAPI Toolkit in Installation Guide [#1445](https://github.com/IntelPython/dpnp/pull/1445)
38+
739
## [0.12.0] - 06/15/2023
840

941
### Added

conda-recipe/meta.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ requirements:
99
- python
1010
- setuptools
1111
- numpy 1.21
12-
- cython
12+
- cython <3
1313
- cmake >=3.21
1414
- ninja
1515
- git
16-
- dpctl >=0.14.3
16+
- dpctl >=0.14.5
1717
- mkl-devel-dpcpp {{ environ.get('MKL_VER', '>=2023.1.0') }}
1818
- onedpl-devel
1919
- tbb-devel
@@ -25,7 +25,7 @@ requirements:
2525
- sysroot_linux-64 >=2.28 # [linux]
2626
run:
2727
- python
28-
- dpctl >=0.14.3
28+
- dpctl >=0.14.5
2929
- {{ pin_compatible('dpcpp-cpp-rt', min_pin='x.x', max_pin='x') }}
3030
- {{ pin_compatible('mkl-dpcpp', min_pin='x.x', max_pin='x') }}
3131
- {{ pin_compatible('numpy', min_pin='x.x', max_pin='x') }}

doc/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
# The short X.Y version
3434
version = "0.12"
3535
# The full version, including alpha/beta/rc tags
36-
release = "0.12.1dev0"
36+
release = "0.12.1"
3737

3838

3939
# -- General configuration ---------------------------------------------------

dpnp/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ build_dpnp_cython_ext_with_backend(dparray ${CMAKE_CURRENT_SOURCE_DIR}/dparray.p
4949
add_subdirectory(backend)
5050
add_subdirectory(backend/extensions/lapack)
5151
add_subdirectory(backend/extensions/vm)
52+
add_subdirectory(backend/extensions/sycl_ext)
5253

5354
add_subdirectory(dpnp_algo)
5455
add_subdirectory(dpnp_utils)

dpnp/backend/doc/Doxyfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ PROJECT_NAME = "DPNP C++ backend kernel library"
3838
# could be handy for archiving the generated documentation or if some version
3939
# control system is used.
4040

41-
PROJECT_NUMBER = 0.12.1dev0
41+
PROJECT_NUMBER = 0.12.1
4242

4343
# Using the PROJECT_BRIEF tag one can provide an optional one line description
4444
# for a project that appears at the top of each page and should give viewer a
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# *****************************************************************************
2+
# Copyright (c) 2016-2023, Intel Corporation
3+
# All rights reserved.
4+
#
5+
# Redistribution and use in source and binary forms, with or without
6+
# modification, are permitted provided that the following conditions are met:
7+
# - Redistributions of source code must retain the above copyright notice,
8+
# this list of conditions and the following disclaimer.
9+
# - Redistributions in binary form must reproduce the above copyright notice,
10+
# this list of conditions and the following disclaimer in the documentation
11+
# and/or other materials provided with the distribution.
12+
#
13+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
14+
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15+
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
17+
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
18+
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
19+
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
20+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
21+
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
22+
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
23+
# THE POSSIBILITY OF SUCH DAMAGE.
24+
# *****************************************************************************
25+
26+
27+
set(python_module_name _sycl_ext_impl)
28+
pybind11_add_module(${python_module_name} MODULE
29+
sum_mean.cpp
30+
)
31+
32+
if (WIN32)
33+
if (${CMAKE_VERSION} VERSION_LESS "3.27")
34+
# this is a work-around for target_link_options inserting option after -link option, cause
35+
# linker to ignore it.
36+
set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -fsycl-device-code-split=per_kernel")
37+
endif()
38+
endif()
39+
40+
set_target_properties(${python_module_name} PROPERTIES CMAKE_POSITION_INDEPENDENT_CODE ON)
41+
42+
target_include_directories(${python_module_name} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/../../include)
43+
target_include_directories(${python_module_name} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/../../src)
44+
45+
target_include_directories(${python_module_name} PUBLIC ${Dpctl_INCLUDE_DIRS})
46+
target_include_directories(${python_module_name} PUBLIC ${Dpctl_TENSOR_INCLUDE_DIR})
47+
48+
if (WIN32)
49+
target_compile_options(${python_module_name} PRIVATE
50+
/clang:-fno-approx-func
51+
/clang:-fno-finite-math-only
52+
)
53+
else()
54+
target_compile_options(${python_module_name} PRIVATE
55+
-fno-approx-func
56+
-fno-finite-math-only
57+
)
58+
endif()
59+
60+
target_link_options(${python_module_name} PUBLIC -fsycl-device-code-split=per_kernel)
61+
if (UNIX)
62+
# this option is support on Linux only
63+
target_link_options(${python_module_name} PUBLIC -fsycl-link-huge-device-code)
64+
endif()
65+
66+
if (DPNP_GENERATE_COVERAGE)
67+
target_link_options(${python_module_name} PRIVATE -fprofile-instr-generate -fcoverage-mapping)
68+
endif()
69+
70+
install(TARGETS ${python_module_name}
71+
DESTINATION "dpnp/backend/extensions/sycl_ext"
72+
)

0 commit comments

Comments
 (0)