Merge master into include-dpctl-tensor#2843
Merge master into include-dpctl-tensor#2843vlad-perevezentsev wants to merge 43 commits intoinclude-dpctl-tensorfrom
Conversation
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.3 to 4.32.4.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 7.0.0 to 8.0.0.
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 6.0.0 to 7.0.0.
The PR updates marks observing `RuntimeWarning` as expected to suppress them. Also the PR update DLPack tests to avoid raising the warning in SYCL queue relating tests.
This PR adds `dpnp.scipy.linalg.lu()` with support for all three output modes: default `(P, L, U)`, `permute_l=True (PL, U)`, and `p_indices=True` `(p, L, U)`, including batched inputs. Fixes: #2786
This PR updates the code to consistently use the `dpnp.exceptions` module as the single source of the exceptions where it's applicable.
This PR implements few improvements for LU function in
`dpnp.scipy.linalg` namespace:
* resolved issue with `Returns` section formatting in `lu` function
* changed to proper `func:` role for the functions cross-references in
`See also` section
* used `Warnings` section name instead of `Warning`
* changed `{None, bool}` to `bool` for overwrite_a, check_finite, and
overwrite_b parameters
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
This PR follows up #2792 and marks one more `RuntimeWarning` warning as expected due to possible overflow.
Bumps [styfle/cancel-workflow-action](https://github.com/styfle/cancel-workflow-action) from 0.13.0 to 0.13.1.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 8.0.0 to 8.0.1.
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.4 to 4.32.6.
Bumps [mshick/add-pr-comment](https://github.com/mshick/add-pr-comment) from 2.8.2 to 3.9.0.
…ration (#2813) ## Summary - Migrate clang-format from `pocc/pre-commit-hooks` to `pre-commit/mirrors-clang-format` v22.1.0 - Update `.clang-format` config to maintain consistent code style across versions - Configure pylint to properly handle C extension modules (numpy, dpctl) - Remove manual clang-format-12 installation from GitHub workflow - Reformat all C++ files with clang-format v22 - Add reformatting commit to `.git-blame-ignore-revs` ## Changes ### Pre-commit configuration - Switch to `pre-commit/mirrors-clang-format` (v22.1.0) for better version pinning and consistency across environments - Add `--disable=c-extension-no-member` to pylint to avoid false positives on C extension objects ### Code style - Update `.clang-format`: Set `AfterControlStatement: Never` to preserve existing brace placement style - Reformat all C++ source files with clang-format v22 (net -159 lines due to template parameter formatting improvements) ### Pylint configuration - Add `extension-pkg-allow-list = ["numpy"]` to help pylint understand numpy better - Add `generated-members` patterns to handle dynamically created attributes on numpy types ### CI/CD - Remove obsolete `apt-get install clang-format-12` step from pre-commit workflow
…2812) The `create_data()` function had an early return when `usm_data` was already a dpnp memory class instance, which skipped setting the `ptr` attribute. This caused all array views to report the same base pointer, making `arr[0].data.ptr == arr[1].data.ptr` even though they point to different memory locations. The PR proposes a fix ensuring `ptr` is always set to `x._pointer`, which points to the start of the array's data (including any offset for views), rather than `usm_data._pointer` which points to the base buffer. Additionally, always create a new memory wrapper instance to avoid shared state when the same `usm_data` is used for multiple views. This PR closes #2781. - [x] Have you provided a meaningful PR description? - [x] Have you added a test, reproducer or referred to an issue with a reproducer? - [x] Have you tested your changes locally for CPU and GPU devices? - [x] Have you made sure that new changes do not introduce compiler warnings? - [ ] Have you checked performance impact of proposed changes? - [ ] Have you added documentation for your changes, if necessary? - [x] Have you added your changes to the changelog?
Previously `dpnp.diagonal()` returned incorrect strides when the diagonal was empty (e.g., when offset >= array width). The stride was set to itemsize instead of the correct `st_n + st_m`. This PR: * fixes stride calculation to consistently use (st_n + st_m) * simplifies implementation using unified formula to calculate resulting shape, strides, and offset * extends tests coverage including scenarios with empty diagonals, views, and non-contiguous arrays The PR closes #2761.
This PR proposes updating QR tests to avoid direct element-wise comparisons which became unstable with oneMKL 2026.0 due to sign and phase differences in otherwise valid QR results Since QR factorization is not unique, different MKL and NumPy versions may return results that differ by sign or complex phase while still representing a correct decomposition To make the tests more stable this PR proposes using invariant-based validation for `mode="raw"` and `mode="r"` based on the unitarity of the Q factor (Q^H Q = I) and the resulting QR identity R^H @ R = A^H @ A
This PR moves all SYCL kernel functors from extensions/ to kernels/ directory, improving the project structure. Moved kernels: - statistics: histogram, sliding_window1d functors - indexing: choose functor - window: bartlett, blackman, hamming, hanning, kaiser functors The PR also improves the code coverage report, since the SYCL kernels can be easy excluded from the report now.
The PR adds ndarray subclassing support via `ndarray.view()` method. It implements the `type` parameter in `dpnp.ndarray.view()` to enable custom subclasses, matching NumPy/CuPy behavior. Also includes proper `__array_finalize__` hook invocation for metadata propagation. The implementation is done through `_view_impl()` helper using 'array_class' parameter to avoid shadowing builtin 'type'. The tests scope is extended with new 7 tests for verifying subclassing support and enabling `TestSubclassArrayView` class from third party tests. This PR closes #2764.
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.6 to 4.34.1.
Bumps [nick-fields/retry](https://github.com/nick-fields/retry) from 3.0.2 to 4.0.0.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
This PR fixes test failures when testing with `DPNP_TEST_ALL_INT_TYPES=1` against conda-forge's NumPy, where float16 precision is used in various scenarios requiring relaxed tolerances.
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.34.1 to 4.35.1.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
The PR updates CMakeLists.txt to bump pybind11 `3.0.3` up from `3.0.2` version.
This PR ensures that default dtype selection respects device-specific capabilities across multiple functions. The PR includes changes: - `dpnp.identity`: Remove redundant default dtype handling. The function now delegates dtype resolution to dpnp.eye(), which already handles device-aware default types correctly. - `dpnp.gradient`: Pass sycl_queue parameter to default_float_type() calls to ensure the selected float type is compatible with the device where the array resides. This prevents issues when converting integer arrays on devices with different dtype support. The PR also updates SYCL queue tests to fix the parametrization to generate device-dtype pairs using a new get_all_dev_dtypes() helper. Each device is now tested only with dtypes it actually supports (e.g., devices without fp64 support won't test fp64), preventing false failures and unnecessary test combinations.
Bumps [mshick/add-pr-comment](https://github.com/mshick/add-pr-comment) from 3.9.0 to 3.10.0.
This PR updates the `.pre-commit-config.yaml` using `pre-commit autoupdate`.
|
View rendered docs @ https://intelpython.github.io/dpnp/pull/2843/index.html |
|
Array API standard conformance tests for dpnp=0.20.0dev6=py313h509198e_43 ran successfully. |
| target_include_directories( | ||
| ${python_module_name} | ||
| PRIVATE | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/../../ |
There was a problem hiding this comment.
is that correct? master has:
target_include_directories(
${python_module_name}
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/../../ ${CMAKE_CURRENT_SOURCE_DIR}/../common
)
There was a problem hiding this comment.
If pre-commit is successful,then this is the correct style for it
Maybe the two lines could be combined into one but we now have four
There was a problem hiding this comment.
My question wan mainly, why do we have 4 includes now here? what is changed that affected legacy list of includes?
There was a problem hiding this comment.
To be more specific: why do we need ${CMAKE_SOURCE_DIR}/dpnp/backend/include ?
There was a problem hiding this comment.
Previously this header came from dpctl and was found via ${Dpctl_INCLUDE_DIRS}
After the migration the explicit path is required because without it I get
fatal error: 'dpnp4pybind11.hpp' file not found during the build
Also you added these changes yourself when you introduced dpnp4pybind11.hpp
https://github.com/IntelPython/dpnp/pull/2734/changes#diff-184866ecda4860667a4d6bf8df98717810e828d440988865ee60b113e02fea6bR67
| target_include_directories( | ||
| ${python_module_name} | ||
| PRIVATE | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/../../ |
There was a problem hiding this comment.
the same comments/questions here as for indexing CMake file
There was a w/a implemented in scope of [dpctl#2275](IntelPython/dpctl#2275). Thus the PR enables the previously muted tests for `dpnp.cumlogsumexp`.
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 7.0.0 to 7.0.1.
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 8.1.0 to 8.1.1.
bdf6d9e to
3a1db6f
Compare
There was a problem hiding this comment.
| # Copyright (c) 2026, Intel Corporation |
This PR synchronizes the
include-dpctl-tensorbranch with the currentmasterbranch