-
Notifications
You must be signed in to change notification settings - Fork 22
[WIP] Implement DLPack #454
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: development
Are you sure you want to change the base?
Conversation
I performed some testing of the new functionality on Perlmutter. After the latest commit, the following appears to work as intended:
It executes without failure and prints the modified value |
Awesome, then we are nearly there. Try the dpnp logic for SYCL next? |
I tested the
|
I compiled WarpX on Aurora using this pyamrex branch. With it I was able to successfully run a multi-GPU simulation that uses |
src/Base/Array4.H
Outdated
/* TODO: Handle keyword arguments | ||
[[maybe_unused]] py::handle stream, | ||
[[maybe_unused]] std::tuple<int, int> max_version, | ||
[[maybe_unused]] std::tuple<DLDeviceType, int32_t> dl_device, | ||
[[maybe_unused]] bool copy | ||
*/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just want to flag this since copy=True
doesn't yet work in the .to_dpnp()
function.
We need to rebase against |
DLPack 1.1, e.g., in NumPy 2.1+ Tests do not yet pass.
…ltensor_versioned" Signed-off-by: Roelof Groenewald <[email protected]>
…e check Signed-off-by: Roelof Groenewald <[email protected]>
…PU backends Signed-off-by: Roelof Groenewald <[email protected]>
for more information, see https://pre-commit.ci
Signed-off-by: Roelof Groenewald <[email protected]>
for more information, see https://pre-commit.ci
… `mf_to_dpnp` Signed-off-by: Roelof Groenewald <[email protected]>
Signed-off-by: Roelof Groenewald <[email protected]>
Signed-off-by: Roelof Groenewald <[email protected]>
7b35ac4
to
9b942d2
Compare
Signed-off-by: Axel Huebl <[email protected]>
Signed-off-by: Axel Huebl <[email protected]>
Add first-class support for zero-copy data exchange with ROCm and SYCL GPUs via DLPack interfaces.
Specs:
Note: we might want to implement a slightly older DLPack version if we do not want to bump up NumPy/CuPy/PyTorch/... to very recent versions. Do we have access to the 2025 Intel Python tools release on Aurora?
Close #9
Action Items
.to_dpnp
/.to_dpctl
helper functions.to_xp
functions to use.to_dpnp
or.to_dpctl
for SYCL GPUs