-
Notifications
You must be signed in to change notification settings - Fork 203
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
Adding base header-only conda package without cuda math libs #1386
Adding base header-only conda package without cuda math libs #1386
Conversation
@cjnolet A few questions/notes. I think the raft/conda/recipes/libraft/meta.yaml Lines 94 to 101 in 16e53f9
Should the |
We shouldn't remove the entire cudatoolkit, but maybe separate it out into 1) just bare essential cudatoolkit dependency itself and 2) an additional section for the additional math libraries. RAFT expects rmm and cudatoolkit at a bare minimum (though rmm will end up being downloaded automatically w/ cpm if they haven't been installed already), so, maybe we could remove rmm at least? The reality is that anyone building w/ the libraft headers should be using cmake, which is going to make sure these dependencies are there (everything other than cudatoolkit anyways), else it'll download them automatically. What are your thoughts here? Please guide... |
cc @robertmaynard to make sure I did this properly. The idea is to make linking against the cuda math libraries optional for individual libraries after the |
…let/raft into build-2304-header_only_no_math_libs
…' into build-2304-header_only_no_math_libs
…header_only_no_math_libs
…let/raft into build-2304-header_only_no_math_libs
…header_only_no_math_libs
@cjnolet looks good from my side, thank you ! |
@MatthiasKohl this PR should actually fix the dependencies for you. We are splitting the headers into a base "libraft-headers-impl" (which we might rename to be more concise) and "libraft-headers" has a dependency on the impl. The impl package removes the runtime dependency on the cuda math libraries and you can do the same in your get_raft in cmake. The explicit run dependency on the headers is only to stop cugraph-ops from trying to download them when building its own conda package so this should fix that whilst also fixing the math lib dependency. Cugraph will have a host time dependency on library-headers but a runtime dependency on libraft-headers-impl. Does that make sense? |
@cjnolet so IIUC, we will be able to make the |
…let/raft into build-2304-header_only_no_math_libs
You might be able to use |
You're right, we do have public APIs with raft structures, so we'd need at least the impl package as a run dependency. |
@MatthiasKohl we have also deprecated our pointer-based APIs, which I notice you are using for rng. I'm going to prioritize changing over the rng APIs first so that they all accept raft::resources objects instead of raft::device_resources. raft::resources is a completely agnostic key/value store for resources (like cublas handles) and doesn't require any of the math libs to use. This way we can update cugraph-ops to use the new rng apis without polluting them with unecessary dependencies. |
Making a note here that until all the APIs that are being compiled into |
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.
It sounds like the request is to have a header package that supplies none of its dependencies if those can be acquired via CPM and/or via the system.
This doesn't quite align with my understanding, so could use some clarification. It's not so much that we want to avoid providing anything that can be acquired via CPM, it's that that we don't want to enforce any dependency requirements that are only needed if certain raft features are used since another package could leverage a limited subset of raft that doesn't have those requirements. Is that right?
RAFT expects rmm and cudatoolkit at a bare minimum (though rmm will end up being downloaded automatically w/ cpm if they haven't been installed already), so, maybe we could remove rmm at least? The reality is that anyone building w/ the libraft headers should be using cmake, which is going to make sure these dependencies are there (everything other than cudatoolkit anyways), else it'll download them automatically. What are your thoughts here? Please guide...
Is there any way to use raft without rmm? If not, I would include rmm as a hard dependency. AIUI there is no benefit to removing a conda package dependency only to have it always be downloaded. The benefit is not including math libraries as a hard dependency if a user of raft might not actually need them.
Thanks, that makes sense, we should be able to do this during 23.06 without issues. |
The whole discussion here and the requirements people are bringing up make me think we should offer |
@robertmaynard I think what you suggest here is a good state for us to get to (with the exception of rmm and cudatoolkit). I'm trying to minimize potential breakage downstream in the meantime with these changes so I've opted to keep the |
/merge |
…i#1386) cc @MatthiasKohl @bdice Making sure CI agrees w/ this change. @MatthiasKohl, if CI succeeds here let's try to plug the resulting conda packages into a cugraph-ops PR to make sure cugraph-ops CI is happy as well. Authors: - Corey J. Nolet (https://github.com/cjnolet) - Robert Maynard (https://github.com/robertmaynard) Approvers: - AJ Schmidt (https://github.com/ajschmidt8) - Divye Gala (https://github.com/divyegala) URL: rapidsai#1386
cc @MatthiasKohl @bdice
Making sure CI agrees w/ this change. @MatthiasKohl, if CI succeeds here let's try to plug the resulting conda packages into a cugraph-ops PR to make sure cugraph-ops CI is happy as well.