-
Notifications
You must be signed in to change notification settings - Fork 91
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
Introduce incompatible-types and enables spilling of CuPy arrays #856
Conversation
Which replace ignore_types
Codecov Report
@@ Coverage Diff @@
## branch-22.04 #856 +/- ##
=================================================
+ Coverage 64.17% 88.47% +24.30%
=================================================
Files 22 16 -6
Lines 3076 2117 -959
=================================================
- Hits 1974 1873 -101
+ Misses 1102 244 -858
Continue to review full report at Codecov.
|
By maintaining key_containts_incompatible_type, we don't have to call unproxify_device_objects() unnecessary.
incompatibles = dask.config.get("jit-unspill-incompatible", "cupy.ndarray") | ||
incompatibles = incompatibles.split(",") |
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.
Thanks for working on this @madsbk .
I am curious, What about stuff like cupyx.scipy.sparse and CumlArray .
Will this work with those too ?
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.
Currently only cupy.ndarray
is on the incompatible list but if you encounter problems with those classes please let me know.
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.
Okay. So i guess if we set DASK_JIT_UNSPILL_INCOMPATIBLE
= cupy.ndarray, CumlArray, cupyx.scipy.sparse.csr_matrix
and just try that to see if that fixes the gpu-bdb stuff, ( which potenitally maybe failing with just cupy.ndarrays
and see ?.
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.
Yes, and also try with just cupy.ndarray
to see if CumlArray
and cupyx.scipy.sparse.csr_matrix
works with ProxyObject
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.
Thanks @madsbk , I've added a few minor suggestions, but otherwise LGTM.
dask_cuda/proxify_host_file.py
Outdated
del self.store[key] | ||
del self.key_contains_incompatible_type[key] |
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.
Wouldn't it be simpler to keep a single dict
storing a (obj, incompatible_type_found)
? Maybe I'm missing some context, but a single dict
would potentially make it less error prone on forgetting to update one of them.
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 added a comment explaining exactly what self.store
is. Please let me know if you think the comment is accurate.
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.
Thanks @shwina , I think the changes to combine dict
s look good, but I didn't see any comment, any chance you missed pushing the change?
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.
Done!
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'm confused, I still don't see any comments. 😅
Could you paste a link to that diff where the comment is contained?
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 kept pushing to my fork instead of Mads' :( Sorry for the confusion. Should be updated on this PR now.
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.
No worries Ashwin, I see your comment now and I think it's explaining correctly, thanks for adding that.
Co-authored-by: Peter Andreas Entschev <[email protected]>
Co-authored-by: Peter Andreas Entschev <[email protected]>
rerun tests |
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.
@gpucibot merge |
Thanks @shwina for finishing the PR and thanks @pentschev for the review :) |
This PR replaces
ignore_types
introduced in #568 withincompatible_types
, which is a list of types thatProxifyHostFile
will unproxify on retrieval. This makes it possible to spill types we previously ignored completely such ascupy.ndarray
.To mark a type incompatible, add it to the comma separated config value
"jit-unspill-incompatible"
or environment variableDASK_JIT_UNSPILL_INCOMPATIBLE
.The default value is:
DASK_JIT_UNSPILL_INCOMPATIBLE="cupy.ndarray"
Closes #855
Notice, I have marked the PR
breaking
because theDASK_JIT_UNSPILL_IGNORE
option has been removed.cc. @VibhuJawa