-
Notifications
You must be signed in to change notification settings - Fork 527
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
Fixing compatibility issue with CUDA array interface #3594
Fixing compatibility issue with CUDA array interface #3594
Conversation
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 a comment about the comment, otherwise looks great, thanks @lowener !
python/cuml/common/memory_utils.py
Outdated
# __cuda_array_interface__ v2 requires the strides to be omitted | ||
# (either not set or set to None) for C-contiguous arrays. |
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.
I would just change the wording of the comment, since the spec doesn't require strides to be omitted for C contiguous arrays, but if the strides are not given or none, then the array is C-contiguous. So, a C-contiguous array can also have its strides set (correctly, implying its contiguity of course)
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.
True, I fixed it
Codecov Report
@@ Coverage Diff @@
## branch-0.19 #3594 +/- ##
===============================================
+ Coverage 80.70% 80.82% +0.11%
===============================================
Files 227 227
Lines 17615 17739 +124
===============================================
+ Hits 14217 14338 +121
- Misses 3398 3401 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
@gpucibot merge |
Closes #3576.
This PR is a fix for CUDA arrays that don't have the
strides
property or that set this property toNone
.Since it seems to be compliant with CUDA array interface v2 we should be able to support it.