-
Notifications
You must be signed in to change notification settings - Fork 309
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
Update edge triangle count to call a non detail primitive #4630
Update edge triangle count to call a non detail primitive #4630
Conversation
…0_non-detail-prim-nbr_intersection
|
||
namespace cugraph { | ||
|
||
namespace detail { |
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.
Don't need to define an empty detail namespace.
|
||
#include <rmm/exec_policy.hpp> | ||
|
||
#include <thrust/binary_search.h> |
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 don't think any of these thrust includes are necessary.
You might want to review all of your includes to reduce them just to what's directly used in this file.
@@ -0,0 +1,105 @@ | |||
/* | |||
* Copyright (c) 2022-2024, NVIDIA CORPORATION. |
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.
This should probably just be 2024.
{ | ||
static_assert(!GraphViewType::is_storage_transposed); | ||
|
||
if (do_expensive_check) { |
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.
Is there a reason to duplicate this error check? Couldn't you just pass do_expensive_check
directly to the detail::nbr_intersection
and let it do this check (it already does).
"Invalid input arguments: there are invalid input vertex pairs."); | ||
} | ||
|
||
auto [intersection_offsets, intersection_indices] = |
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.
You should be able to just return the results directly...
return detail::nbr_intersection(handle,
...
instead of capturing and then immediately returning the result.
* @param graph_view Non-owning graph object. | ||
* @param vertex_pair_first Iterator pointing to the first (inclusive) input vertex pair. | ||
* @param vertex_pair_last Iterator pointing to the last (exclusive) input vertex pair. | ||
* @param A flag to run expensive checks for input arguments (if set to `true`). |
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.
Documentation for return values is missing (@return)
…0_non-detail-prim-nbr_intersection
/merge |
Create a non detail primitive that iterates over each input vertex pair and returns the common destination neighbor list
pair in a CSR-like format.
closes #3475