Skip to content

Commit

Permalink
Clean up public api (rapidsai#2398)
Browse files Browse the repository at this point in the history
We are exposing some internal implementation details in our public header files.  This PR addresses exposing `cuco` in the public header files.  It is the start of the effort to clean up the public API for libcugraph.

Ultimately our plan is to migrate the graph primitives into a separate library.  This PR does move a bunch of the primitive headers out of the libcugraph public API.

Authors:
  - Chuck Hastings (https://github.com/ChuckHastings)

Approvers:
  - Seunghwa Kang (https://github.com/seunghwak)

URL: rapidsai#2398
  • Loading branch information
ChuckHastings authored Jul 12, 2022
1 parent eae4585 commit 7a660e6
Show file tree
Hide file tree
Showing 49 changed files with 164 additions and 128 deletions.
15 changes: 8 additions & 7 deletions cpp/src/centrality/eigenvector_centrality_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,17 @@
*/
#pragma once

#include <prims/count_if_e.cuh>
#include <prims/count_if_v.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <prims/reduce_v.cuh>
#include <prims/transform_reduce_v.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/detail/utility_wrappers.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/count_if_e.cuh>
#include <cugraph/prims/count_if_v.cuh>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <cugraph/prims/reduce_v.cuh>
#include <cugraph/prims/transform_reduce_v.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/error.hpp>

#include <raft/handle.hpp>
Expand Down
11 changes: 6 additions & 5 deletions cpp/src/centrality/katz_centrality_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@
*/
#pragma once

#include <prims/count_if_v.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <prims/transform_reduce_v.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/count_if_v.cuh>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <cugraph/prims/transform_reduce_v.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/error.hpp>

#include <raft/handle.hpp>
Expand Down
17 changes: 8 additions & 9 deletions cpp/src/community/louvain.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,18 @@
*/
#pragma once

#include <cugraph/dendrogram.hpp>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/per_v_transform_reduce_dst_key_aggregated_outgoing_e.cuh>
#include <prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <prims/transform_reduce_e.cuh>
#include <prims/transform_reduce_e_by_src_dst_key.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>
#include <utilities/collect_comm.cuh>

#include <cugraph/dendrogram.hpp>
#include <cugraph/graph.hpp>
#include <cugraph/graph_functions.hpp>

#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/per_v_transform_reduce_dst_key_aggregated_outgoing_e.cuh>
#include <cugraph/prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <cugraph/prims/transform_reduce_e.cuh>
#include <cugraph/prims/transform_reduce_e_by_src_dst_key.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/collect_comm.cuh>

#include <raft/handle.hpp>
#include <rmm/device_uvector.hpp>

Expand Down
7 changes: 4 additions & 3 deletions cpp/src/community/triangle_count_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@
*/
#pragma once

#include <prims/extract_if_e.cuh>
#include <prims/transform_reduce_dst_nbr_intersection_of_e_endpoints_by_v.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/detail/shuffle_wrappers.hpp>
#include <cugraph/graph_functions.hpp>
#include <cugraph/prims/extract_if_e.cuh>
#include <cugraph/prims/transform_reduce_dst_nbr_intersection_of_e_endpoints_by_v.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/host_scalar_comm.cuh>

Expand Down
13 changes: 7 additions & 6 deletions cpp/src/components/weakly_connected_components_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@
*/
#pragma once

#include <detail/graph_utils.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/transform_reduce_v_frontier_outgoing_e_by_dst.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>
#include <prims/update_v_frontier.cuh>
#include <prims/vertex_frontier.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/detail/graph_utils.cuh>
#include <cugraph/graph_functions.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/transform_reduce_v_frontier_outgoing_e_by_dst.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/prims/update_v_frontier.cuh>
#include <cugraph/prims/vertex_frontier.cuh>
#include <cugraph/utilities/device_comm.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/shuffle_comm.cuh>
Expand Down
13 changes: 7 additions & 6 deletions cpp/src/cores/core_number_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@
*/
#pragma once

#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/reduce_v.cuh>
#include <prims/transform_reduce_v_frontier_outgoing_e_by_dst.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>
#include <prims/update_v_frontier.cuh>
#include <prims/vertex_frontier.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/reduce_v.cuh>
#include <cugraph/prims/transform_reduce_v_frontier_outgoing_e_by_dst.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/prims/update_v_frontier.cuh>
#include <cugraph/prims/vertex_frontier.cuh>
#include <cugraph/utilities/error.hpp>

#include <raft/handle.hpp>
Expand Down
File renamed without changes.
3 changes: 2 additions & 1 deletion cpp/src/detail/shuffle_wrappers.cu
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <cugraph/detail/graph_utils.cuh>
#include <detail/graph_utils.cuh>

#include <cugraph/detail/shuffle_wrappers.hpp>
#include <cugraph/graph_functions.hpp>
#include <cugraph/partition_manager.hpp>
Expand Down
13 changes: 7 additions & 6 deletions cpp/src/link_analysis/hits_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@
*/
#pragma once

#include <prims/count_if_v.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <prims/reduce_v.cuh>
#include <prims/transform_reduce_v.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/count_if_v.cuh>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <cugraph/prims/reduce_v.cuh>
#include <cugraph/prims/transform_reduce_v.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>

#include <thrust/copy.h>
#include <thrust/fill.h>
Expand Down
15 changes: 8 additions & 7 deletions cpp/src/link_analysis/pagerank_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@
*/
#pragma once

#include <prims/count_if_e.cuh>
#include <prims/count_if_v.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <prims/reduce_v.cuh>
#include <prims/transform_reduce_v.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/algorithms.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/count_if_e.cuh>
#include <cugraph/prims/count_if_v.cuh>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/per_v_transform_reduce_incoming_outgoing_e.cuh>
#include <cugraph/prims/reduce_v.cuh>
#include <cugraph/prims/transform_reduce_v.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/error.hpp>

#include <raft/handle.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
*/
#pragma once

#include <prims/property_op_utils.cuh>
#include <prims/transform_reduce_e.cuh>

#include <cugraph/graph_view.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/prims/transform_reduce_e.cuh>

#include <raft/handle.hpp>

Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@
*/
#pragma once

#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/extract_if_e.cuh>
#include <prims/property_op_utils.cuh>

#include <cugraph/detail/decompress_edge_partition.cuh>
#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/extract_if_e.cuh>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/error.hpp>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@
*/
#pragma once

#include <detail/graph_utils.cuh>
#include <utilities/collect_comm.cuh>

#include <cugraph/detail/decompress_edge_partition.cuh>
#include <cugraph/detail/graph_utils.cuh>
#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/utilities/collect_comm.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/device_functors.cuh>
#include <cugraph/utilities/error.hpp>
Expand Down Expand Up @@ -206,7 +207,7 @@ struct reduce_with_init_t {
* (aggregated over the entire set of processes in multi-GPU).
* @param init Initial value to be reduced with the reduced value for each vertex.
* @param reduce_op Binary operator that takes two input arguments and reduce the two values to one.
* There are pre-defined reduction operators in include/cugraph/prims/reduce_op.cuh. It is
* There are pre-defined reduction operators in src/prims/reduce_op.cuh. It is
* recommended to use the pre-defined reduction operators whenever possible as the current (and
* future) implementations of graph primitives may check whether @p ReduceOp is a known type (or has
* known member variables) to take a more optimized code path. See the documentation in the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@
*/
#pragma once

#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/property_op_utils.cuh>
#include <prims/reduce_op.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/partition_manager.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/prims/reduce_op.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/device_comm.cuh>
#include <cugraph/utilities/error.hpp>
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

#pragma once

#include <cugraph/prims/property_op_utils.cuh>
#include <prims/property_op_utils.cuh>

#include <raft/comms/comms.hpp>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
*/
#pragma once

#include <prims/property_op_utils.cuh>
#include <prims/reduce_op.cuh>

#include <cugraph/graph_view.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/prims/reduce_op.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/host_scalar_comm.cuh>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@
*/
#pragma once

#include <cugraph/detail/graph_utils.cuh>
#include <detail/graph_utils.cuh>
#include <prims/detail/nbr_intersection.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/property_op_utils.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/detail/nbr_intersection.cuh>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/utilities/device_functors.cuh>
#include <cugraph/utilities/error.hpp>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@
*/
#pragma once

#include <prims/property_op_utils.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/edge_partition_view.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/host_scalar_comm.cuh>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@
*/
#pragma once

#include <cugraph/detail/graph_utils.cuh>
#include <detail/graph_utils.cuh>
#include <prims/property_op_utils.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/shuffle_comm.cuh>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
*/
#pragma once

#include <prims/property_op_utils.cuh>
#include <prims/reduce_v.cuh>

#include <cugraph/graph_view.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/prims/reduce_v.cuh>
#include <cugraph/utilities/error.hpp>
#include <cugraph/utilities/host_scalar_comm.cuh>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@
*/
#pragma once

#include <prims/property_op_utils.cuh>
#include <prims/reduce_op.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/partition_manager.hpp>
#include <cugraph/prims/property_op_utils.cuh>
#include <cugraph/prims/reduce_op.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/device_comm.cuh>
#include <cugraph/utilities/device_functors.cuh>
Expand Down Expand Up @@ -945,7 +946,7 @@ typename GraphViewType::edge_type compute_num_out_nbrs_from_frontier(
* ReduceOp::value_type is not void); or 5) a tuple of a tag and a value to be reduced (if vertices
* are tagged and ReduceOp::value_type is not void).
* @param reduce_op Binary operator that takes two input arguments and reduce the two values to one.
* There are pre-defined reduction operators in include/cugraph/prims/reduce_op.cuh. It is
* There are pre-defined reduction operators in prims/reduce_op.cuh. It is
* recommended to use the pre-defined reduction operators whenever possible as the current (and
* future) implementations of graph primitives may check whether @p ReduceOp is a known type (or has
* known member variables) to take a more optimized code path. See the documentation in the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@
*/
#pragma once

#include <prims/edge_partition_src_dst_property.cuh>

#include <cugraph/edge_partition_device_view.cuh>
#include <cugraph/graph_view.hpp>
#include <cugraph/partition_manager.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/dataframe_buffer.cuh>
#include <cugraph/utilities/device_comm.cuh>
#include <cugraph/utilities/error.hpp>
Expand Down
File renamed without changes.
File renamed without changes.
7 changes: 4 additions & 3 deletions cpp/src/structure/coarsen_graph_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@
*/
#pragma once

#include <detail/graph_utils.cuh>
#include <prims/edge_partition_src_dst_property.cuh>
#include <prims/update_edge_partition_src_dst_property.cuh>

#include <cugraph/detail/decompress_edge_partition.cuh>
#include <cugraph/detail/graph_utils.cuh>
#include <cugraph/detail/shuffle_wrappers.hpp>
#include <cugraph/graph.hpp>
#include <cugraph/graph_functions.hpp>
#include <cugraph/graph_view.hpp>
#include <cugraph/prims/edge_partition_src_dst_property.cuh>
#include <cugraph/prims/update_edge_partition_src_dst_property.cuh>
#include <cugraph/utilities/device_functors.cuh>
#include <cugraph/utilities/error.hpp>

Expand Down
Loading

0 comments on commit 7a660e6

Please sign in to comment.