-
Notifications
You must be signed in to change notification settings - Fork 933
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
[BUG] dd.from_map with cudf read_json not working when pool is enabled #13019
Comments
compute-sanitizer says:
Which makes me suspicious of rapidsai/kvikio#181, @madsbk does that look likely? Certainly that error message is coming from kvikio. |
Can confirm that setting |
A bit of debugging... If I check the state of the context before calling into libcudf from read_json: diff --git a/python/cudf/cudf/io/json.py b/python/cudf/cudf/io/json.py
index 4de9a92a06..38bd127647 100644
--- a/python/cudf/cudf/io/json.py
+++ b/python/cudf/cudf/io/json.py
@@ -108,6 +108,9 @@ def read_json(
else:
filepaths_or_buffers.append(tmp_source)
+ from cuda import cuda
+
+ print(cuda.cuCtxGetCurrent())
df = libjson.read_json(
filepaths_or_buffers,
dtype, I see something bad:
So there's no active context when dropping into libcudf. Later when kvikio is doing its checking it does: if (check_owning_devPtr != nullptr) {
CUdeviceptr current_ctx_devPtr{};
CUdeviceptr dev_ptr = convert_void2deviceptr(check_owning_devPtr);
CUresult const err = cudaAPI::instance().PointerGetAttribute(
¤t_ctx_devPtr, CU_POINTER_ATTRIBUTE_DEVICE_POINTER, dev_ptr);
if (err != CUDA_SUCCESS || current_ctx_devPtr != dev_ptr) {
throw CUfileException("The current CUDA context must own the given device memory");
}
} That attribute is documented as returning:
And indeed, this call returns In contrast, asking for the old
Something weird is going on though, since if I just do
Then I see
But the print from within So something is on a different process/thread? |
Yes, the old behavior that use |
Fixes rapidsai/cudf#13019 Authors: - Mads R. B. Kristensen (https://github.com/madsbk) Approvers: - Lawrence Mitchell (https://github.com/wence-) URL: #189
Describe the bug
When attempting to use
dd.from_map
withcudf.read_json
with rmm pool enabled, I'm running into an errorException: "RuntimeError('The current CUDA context must own the given device memory')"
.Steps/Code to reproduce bug
Expected behavior
Reads in the data as expected. Was working in the 23.02 stable release but doesn't in the 23.04 nightly.
Environment overview (please complete the following information)
Environment details
N/A
Additional context
File to reproduce jsonfile.tar.gz
The text was updated successfully, but these errors were encountered: