Skip to content
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

[REVIEW] Adding SLHC prims. #140

Merged
merged 72 commits into from
Mar 16, 2021
Merged

[REVIEW] Adding SLHC prims. #140

merged 72 commits into from
Mar 16, 2021

Conversation

cjnolet
Copy link
Member

@cjnolet cjnolet commented Feb 8, 2021

The dense pairwise distances API in cuML currently relies on CUTLASS and will soon be re-written to remove that dependency. Until then, the SLHC implementation in RAFT cannot depend on that API. In the meantime, I've abstracted that piece out to make it pluggable on the cuML side.

This PR depends on the changes in #139.

@cjnolet cjnolet added improvement Improvement / enhancement to an existing function non-breaking Non-breaking change 2 - In Progress Currenty a work in progress labels Feb 8, 2021
@cjnolet cjnolet changed the base branch from branch-0.18 to branch-0.19 February 11, 2021 15:49
@cjnolet
Copy link
Member Author

cjnolet commented Feb 22, 2021

Depends on #119

@cjnolet cjnolet added 3 - Ready for Review and removed 2 - In Progress Currenty a work in progress CMake labels Mar 9, 2021
@github-actions github-actions bot added the CMake label Mar 11, 2021
Copy link
Member

@divyegala divyegala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is my first pass review, where I have not looked over the logic at all yet. What are your thoughts on removing the usage of raft::mr::device::buffer to favor rmm::device_uvector so we can start having new PRs not have that and eventually move towards removing our allocator completely?

std::vector<value_idx> children_h(n_edges * 2);
std::vector<value_idx> out_size_h(n_edges);

uint32_t start = curTimeMillis();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding a note for later removal

cpp/include/raft/sparse/hierarchy/detail/agglomerative.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/hierarchy/detail/agglomerative.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/hierarchy/detail/agglomerative.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/hierarchy/detail/agglomerative.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/linalg/symmetrize.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/selection/connect_components.cuh Outdated Show resolved Hide resolved
cpp/include/raft/sparse/selection/connect_components.cuh Outdated Show resolved Hide resolved
@cjnolet
Copy link
Member Author

cjnolet commented Mar 11, 2021

@divyegala, thanks for taking the time to review this! I've pushed the changes based on your review. All of the changes that were using raft device buffer objects should now be using rmm device uvector.

As discussed in the review, I tried to update all the thrust functions per your request but some of them don't seem to like using the thrust policy. I don't believe any of those should be using scratch space, though, so I think we should be okay. If the remaining device pointer casts are still a concern and we can't find a quick way around them, we can always make a Github issue for it and fix it when we figure out the cause. What do you think?

Copy link
Member

@divyegala divyegala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just the one timer left to remove

@dantegd
Copy link
Member

dantegd commented Mar 16, 2021

@gpucibot merge

@rapids-bot rapids-bot bot merged commit fc46618 into branch-0.19 Mar 16, 2021
rapids-bot bot pushed a commit to rapidsai/cuml that referenced this pull request Mar 18, 2021
Closes #3518 

I've closed the original PR (#3308) which included both SLHC & HDBSCAN and opened this PR to only include the SLHC changes. 

This PR contains an implementation of SLHC which is currently broken across RAFT & cuML. Once we move the dense pairwise distance primitive over to RAFT the entire SLHC algorithm can live in RAFT so it can be shared w/ cugraph, and will just be exposed through cuml.

If reviewing this PR, please also review the corresponding RAFT PR: rapidsai/raft#140

Authors:
  - Corey J. Nolet (@cjnolet)

Approvers:
  - Divye Gala (@divyegala)
  - Dante Gama Dessavre (@dantegd)
  - Mike Wendt (@mike-wendt)

URL: #3545
dantegd pushed a commit to dantegd/raft that referenced this pull request Jul 23, 2024
Forward-merge branch-24.06 into branch-24.08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 - Ready for Review CMake cpp improvement Improvement / enhancement to an existing function non-breaking Non-breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants