Skip to content

Commit

Permalink
Updates test to ensure a query string is created using integer vertex…
Browse files Browse the repository at this point in the history
… IDs (as required).
  • Loading branch information
rlratzel committed Aug 28, 2024
1 parent 37d2ca0 commit 21b689b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions python/cugraph/cugraph/tests/data_store/test_property_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -2576,9 +2576,12 @@ def bench_extract_subgraph_for_rmat(gpubenchmark, rmat_PropertyGraph):
scn = PropertyGraph.src_col_name
dcn = PropertyGraph.dst_col_name

# Build a query string to extract a graph with only specific edges based on
# the integer vertex IDs. Other edge and/or vertex properties can be
# included in the query as well.
verts = []
for i in range(0, 10000, 10):
verts.append(generated_df["src"].iloc[i])
verts.append(int(generated_df["src"].iloc[i]))

selected_edges = pG.select_edges(f"{scn}.isin({verts}) | {dcn}.isin({verts})")
gpubenchmark(
Expand Down Expand Up @@ -2618,9 +2621,12 @@ def bench_extract_subgraph_for_rmat_detect_duplicate_edges(
scn = PropertyGraph.src_col_name
dcn = PropertyGraph.dst_col_name

# Build a query string to extract a graph with only specific edges based on
# the integer vertex IDs. Other edge and/or vertex properties can be
# included in the query as well.
verts = []
for i in range(0, 10000, 10):
verts.append(generated_df["src"].iloc[i])
verts.append(int(generated_df["src"].iloc[i]))

selected_edges = pG.select_edges(f"{scn}.isin({verts}) | {dcn}.isin({verts})")

Expand Down

0 comments on commit 21b689b

Please sign in to comment.